I'm trying to connect my desktop app to my Bubble.is app. They have a way
to build APIs.

https://bubble.is/reference#API.sending_data

I've got text uploading working. As in, I can upload text from the desktop
and work with it in the web app.

I've also got image URLs working. As in, I can include the URL of an image
that's already hosted somewhere online and the image will be pulled into
Bubble so I can work with it.

What's not working is uploading image data from the desktop app to the web
app.

I've formatted the body of the POST like this, which as far as I can tell
is what they want:
first=some thing&second=another
thing&third={"private":false,"filename":"some_filename.jpg","content":"a
string of base64 encoded image data"}

Since Bubble isn't returning any errors, but also isn't putting the
uploaded image data into the database as an image, I wondered if maybe I'm
doing something wrong on the Livecode side. I used this to process the
image data:

start using stack "easyJSON"
   put "C:\Users\some-image.jpg" into tFile
   put URL ("binfile:" & tFile) into tImage
   put base64encode(tImage) into tImage64
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to