code field in the response body for detailed error identification.
Response format
Error responses follow this structure:HTTP status codes
Authentication & permission errors
Validation errors (400)
Resource not found (404)
Lead errors (400)
Transaction errors (400)
Agent lifecycle errors (200 with error code)
POST /v2.0/agents/{agentId}/deactivate and POST /v2.0/agents/{agentId}/reactivate always return HTTP 200 once authentication passes. Check the response body’s code field (absent or 0 means success) rather than the status code.