Hmm, yeah, I see what you are saying here.
Maybe try this. Maybe you can try to use Raw or JSON instead of Form-data. Then you can format your JSON any way you want. Let me know if that helps get you going in the right direction.
Someone can correct me if I’m wrong, but I believe that this is sending the data the same way. It still uses JSON, but it just allows you to format it the way you want to in the API Connector. I rarely use form-data for any of my API Calls. Mostly because of limitations like this.
I can try to give an example but I would need more details. Like the documentation and which API you are using.
I have not, but I don’t know how to pass a file. When using form-data as a body type, you can check the “file” option, and select a file. Here there is no way to do so.
Maybe there is a way to pass a file anyway, if so does anyone know how to ?
You could try to set body type to “raw” and try to create your own payload to send it as multipart form (with correct Content-type header). But this is a lot more complex todo (and to debug)
If you have done this in the past already, do you have an example of how you configured a bubble API Connector call ? I don’t know what the raw body should look like for this.
I’ve done something similar to use with gmail. However, this is a little bit different and this is complex to do.
You may also need another plugin to first get the list of file. Best is if the API accept base64 data.
You will need to send the payload like
--boundary
Content-Type:image/jpeg
Content-Disposition: form-data; filename="frog.jpg"
Content-Transfer-Encoding: base64
base64 data here
--boundary
Content-Type:image/jpeg
Content-Disposition: form-data; filename="frog2.jpg"
Content-Transfer-Encoding: base64
base64 data here
--boundary--
So i tried this using the Bubble API instead to test this on a common app, I managed to make it work on Postman directly using your method, but I get a 404 error when using the API connector.
The example is just a test Datatype which has a field text-value.
Do you see an error in what I made ? Or do you have an idea as to what could be going wrong in the behind the scenes ?