Skip to content Skip to sidebar Skip to footer

Send Images/videos From Android/ios To Google Cloud Endpoints

I'm really needing your help/suggestion/clue/etc. I'm developing an application for Android and iOS which will allow the user to upload pictures and videos. What I'm trying to do:

Solution 1:

As Saiyr suggested, you should upload directly to the Cloud Storage from the Android application (without going through Endpoints). See Uploading image from Android to GCS and upload image to google cloud storage with an application android.

Since you know the bucket and file name, the URL of the uploaded file is easily deductible, see the following documentation to decide which URL to use (depending on whether the user shall be authenticated or not, see Section "A user is granted read access to an object") https://cloud.google.com/storage/docs/cloud-console#_accessing

Solution 2:

If you're using the Endpoints frameworks, this is pretty hard to do. For single images, you can base64 encode them, but that's not very efficient. It probably works better for your client to interact directly with GCS and use a signed URL for upload.

Post a Comment for "Send Images/videos From Android/ios To Google Cloud Endpoints"