Errors
Error response format and HTTP status codes.
Failed calls return a non-2xx HTTP status with a JSON body whose detail field describes the error, usually an object with message and error_type. Use error_type in your code, not the message. Invalid request bodies (including fields the endpoint doesn’t take) return 422 with the fields that are wrong.
Copy this section as context for your AI coding agent
json
{
"detail": {
"success": false,
"message": "No automation with that ID on this Instagram account.",
"error_type": "NOT_FOUND"
}
}Read detail.error_type in your code, not the human-readable message. Some chat and form errors return detail as plain text, and invalid request bodies return 422 with a list of field errors.
401Unauthorized: missing, invalid or revoked API key, or the Instagram account was disconnected402Plan required: the plan doesn’t include the Instagram API (PLAN_REQUIRED)403Forbidden: called from a browser (call from your server)404Not found: no automation with that ID on this account422Invalid request body or ID429Rate limited (RATE_LIMITED) or the month’s calls are used up (QUOTA_EXCEEDED)502Instagram refused or didn’t answer: retry with backoff500Server error: retry with backoff