65
Views
2
Comments
Solved
Send clicked photos through API
Application Type
Mobile
Service Studio Version
11.53.41 (Build 62020)

I created an app where every 2 sec the photo is captured and saved to the OutSystems database and now I want to send that photos to the API in the Xano database. The images stored in the database are in binary form so how I can send them to the Xano database and in Xano to store the image which type of attribute I need to create as I see there is no attribute name binary data. I am new to this please share your thoughts and help me out with this.

I am also attaching my .oml file.

Camera.oml
2024-01-18 12-42-28
Bogdan Boglea
Solution

Hey,

Hope I got the correct link, but you should check Xano's documentation regarding file/images uploads and how that can be done via an API: https://docs.xano.com/working-with-data/functions/content-upload

There is an API for metadata, which will only store information related to that image like names/descriptions etc, but for the actual binary file I think you'll have to call another API.

Briefly checking the endpoints from your URL I saw the following API in the swagger documentation: https://x8ki-letl-twmt.n7.xano.io/apidoc:VxRSWaSJ:v1/#/upload/post_upload_images

If you take a look you'll see this one allows a binary input in the body, I'm guessing this is how you upload images to Xano.

Hope this helps,

Bogdan

UserImage.jpg
Chetna Upadhyay

I have created an image API that takes images in binary data in the swagger hub and downloads it in the python flask server and then its API run in my localhost. So now I want to consume the Rest API post operation in my Outsystems and the POST URL it was using in OutSystems is the same localhost API POST URL that is running in my localhost. So how can I consume this URL and use it to send the images to the POST API?

Also, the images which were sent by the app will be stored in the POST API inside the directory.

Please provide me with some solutions on how can I do this POST operation.

SimpleCamera.oml
image_api_directory - Copy.zip
Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.