i did change the headers above the url.
Still gettting the same error.
If there is no multipart/form-data in app inventor, how do we do to post a file?
thanks
You are somewhere between a rock and a hard place unfortunately. The normal content description for your task would actually be "image/png" (or whatever file types you use). App Inventor is compatible with that content type, as are all the major browsers, but the site you are sending to apparently only supports the multipart type - I was hoping we could fudge it - no luck so far.
This is the code that works for App Inventor but apparently not the site concerned (insecure site) . Note that the Request Header should simply be "content" and when sending only one image we probably do not want to keep the connection alive.
Edit: Updated image and Project File. I was wrong about the header parameter, it should be "Content-Type".
Note that, if we use multipart/ in the header, what is actually expected is something like an email file. In such files, a boundary is inserted between the types of content. When we just post an image file (obviously not mixed) we get an error about the boundary missing.
Given this, I do understand how PostMan is working - it's making a genuine form file, not just sending an image, though the image and a boundary are the only contents.
You could try to do this with App Inventor:
Assemble a file with .eml as it's type and with a bespoke boundary (as described by Geeks for Geeks) and the image concerned.
Possibly the best approach would be to send an email to yourself, with test content, so that you can see how to assemble the file.