Using curl on Windows to interact with Qlik SaaS API may give you an error, like the one below:
{"traceId":"67d14d4c1cd2410595748ce67ac04c88","errors":[{"code":"RELOADS-001","title":"Invalid request."}]}
The above is a result of using the Reloads endpoint to reload an app as outlined here: https://qlik.dev/apis/rest/reloads#%23%2Fentries%2Freloads-post
curl "https://your-tenant.us.qlikcloud.com/api/v1/reloads" \
-X POST \
-H "Authorization: Bearer <API-key>" \
-H "Content-type: application/json" \
-d '{"appId":"116dbfae-7fb9-4983-8e23-5ccd8c508722","partial":true}'
Environment
Resolution
Here is a working example for curl on Windows. Note the change in using double quotes (“) instead of single quotes (‘) around the body as well as escaping (\) the double quotes inside the body.
Also note the use of ^ instead of \ for line breaks.
curl "https://your-tenant.us.qlikcloud.com/api/v1/reloads" ^
-X POST ^
-H "Authorization: Bearer <API-key>" ^
-H "Content-type: application/json" ^
-d "{\"appId\":\"116dbfae-7fb9-4983-8e23-5ccd8c508722\",\"partial\":true\"}"
Cause
This is an artifact of curl on Windows. The above example is for Linux/Mac OS systems and quoting and escape characters are a bit different on Windows.