I've searched a bunch and can't find the answer the answer to this.
I'm trying to pass a binary file as a JSON parameter using multipart/form-data using curl for a POST request. I tried this, but it doesn't work for obvious reasons:
curl -X POST http://api.example.com \
-H "Content-Type:multipart/form-data" \
-F "data={\"key\": \"@text.txt\"};type=application/json"
Any insights would be appreciated.