Zapier · API by Zapier
JSON errors in the request body
Short answer
A JSON parsing error in an API by Zapier step means the request body is not valid JSON. Validate the body, quote mapped fields properly, and escape special characters with a Formatter step.
VerifiedLast verified
01Error text
A JSON parsing error02Likely causes
- Missing or extra quotes, brackets, or commas.
- Mapped fields containing special characters, such as quotes, that break the JSON.
- Trailing commas after the last item in an object or array.
03How to fix it
- Paste the request body into a JSON validator.
- Check that all mapped fields are properly quoted, for example
{"name": "{{name}}"}. - For fields with special characters, escape the value with a Formatter step before mapping it into the JSON body.
iNotes
Zapier does not quote a fixed message for this problem. The text above is its description of the error.
04Official documentation
→Related errors
- 401 or 403 errors in API by ZapierA 401 or 403 from an API by Zapier step means the credentials expired, were revoked, or lack the permissions or scopes the endpoint requires. Create a new connection with updated credentials and confirm the permissions with the API provider.
- Domain not allowedThis API by Zapier error means the domain in the step URL does not match the domain filter set when the connection was created. Compare the two, use a wildcard for subdomains, or create a new connection with the correct domains.
- 4xx or 5xx errors from the API in API by ZapierThese status codes in an API by Zapier step come from the API being called, not from Zapier. Check the endpoint URL and request against the provider documentation, add a delay for rate limits, and retry later for 5xx errors.
Test every fix in a non-production environment before you apply it to production. See how entries are verified.
More for Zapier work:Open Zapier jobsZapier rates and salaries