I have a mobile application which needs to display images which will be sent to it via REST API. How do I tranfser images ove the API? I am developing a ASP.net Web API using C#.
I tried converting image to base64 then send it though API to the mobile device, but this seems to take a lot of time as I have to send large number of images to my mobile device in one run.
I need to send image file along with some other data through the API to mobile device and a Phonegap android will then save it in local db for further use. Any help would be appreciated.
If you want to sent the images alongside other data in one request using base64 is the best way.
You could think of using gzip to compress the image data to reduce the size. An other way would be to send the images in a reduced size to your android client alonside with a URL to a fully sized image. This enables you to show you results quickly to the user and then load the large images in a background task from the server and replace the small ones in the database.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With