0

Send Files from Device to External Service

I'm trying to learn to send data from a device storage with an app to an external service. I created a project in Supabase and created a storage bucket there(toggled Public Bucket on for it) and copied the API key. I also copied the project ID. Now I have created an app to upload medias from the device storage path: /storage/emulated/0/Test Images/ but after I grant storage permission on app launch, a toast message pops up saying "Uploading imagename.jpg", then a second toast message pops up saying "❌ Failed: imagename.jpg" and then the last toast message pops up saying "✅ Upload Finished". So the process is failing for some reason(I checked the Supabase storage bucket just to make sure, and nothing was uploaded there). My bucket name in the code is correct exactly as it is, with matching case. The Java and Manifest code is here: https://sololearn.com/compiler-playground/cEl81bJH6m5P/?ref=app

13th Nov 2025, 11:03 AM
Ace
Ace - avatar
0 Answers