I know what I am doing wrong is probably a very simple fix but I can't find it. See my curl request below
curl.exe -k -X POST -H "Authorization: Bearer 7a15dbf7-bd65-****-****-************:**" -H "Content-Type: application/json"-H "Accept: application/json" -F "folder={\"id\":****, \"type\":\"Folder\"}" -F "name=myFirstApiFile.jpg" -F "file=@D:\*****\*****\*****\header.img" https://***-***-***.mktorest.com/rest/asset/v1/files.json
I receive 701: file is mandatory. But as you can see file is clearly one of my posted fields.
Solved! Go to Solution.
figured it out. needed to drop the "Content-Type" Header
Hi Chris, I am facing the same issue.
Could you please share the code snippet for uploading an image via API.
Thanks in advance!