Why do I get a malformed JSON in request body in this cURL call?
I found the answer in the blog post: "Expecting to find valid JSON in request body..." curl for Windows.
For example, for Purge everything --data
value will be:
# On Linux
--data '{"purge_everything":true}'
# On Windows
--data "{\"purge_everything\":true}"
For Windows:
- Replace the single quotes with double quotes:
'
-->
"
- Escape the double quotes with a backslash:
"
-->
\"