I am trying to send a POST request with both a FILE upload and some JSON body data. The file is not an issue using the form-data, however I can’t seem to get past the JSON body part regardless of trying everything I can think of.
This is the API I’m trying to post to:
https://docs.developer.focusvision.com/docs/decipher/api#operation/createSurveyDataRespondentsImport
Here is what the JSON body should more or less look like:
{
“key”: “source”,
“tabfile”: “string”,
“questions”: [
{
“index”: “string”,
“reportLabel”: “string”,
“label”: “string”,
“title”: “string”,
“type”: “single”,
}
]
}
The issue I keep running into is this 400 error and this regardless of what I try using form-data:
Basically I can’t figure out how to pass it as an array using form-data and I have no idea if you can use raw to upload a file along with doing the above, so any thoughts/tips/tricks to get this to work would be amazing!
Thanks,
Justin