Response Format

Every API call provides a JSON formatted example and the list of parameters for that call.

HTTP response codes

  • Successful REST API requests return a 200 OK HTTP response.
  • Unsuccessful requests that fail validation return a 422 HTTP response.
  • A request that tries to access objects outside its domain returns a 403 Forbidden response.

Default JSON success response

The default success response is a full JSON object that removes repeating parameters.

{
  “responseStatus”:“ok”,
  “responseHeader”:{
    “status”:“ok”,
    “now”:{milliseconds from the UNIX epoch},
    “requestId”:“UzGX8cCoDkMAABiqF4kAAABJ”
  },
  “responseData”:{}
}

Default JSON failure response

The default failure response is a full JSON object.

{
  “responseStatus”:“fail”,
  “responseHeader”:{
    “status”:“fail”,
    “now”:{milliseconds from the UNIX epoch},
    “requestId”:“UzCeScCoDkMAABiqBtQAAABO”
  },
  “responseData”:{
    “errors”:[
      {
        “field”:“{field}”,
        “message”:“{message}”,
        “code”:“{code}”
      }
    ]
  }
}

Common response parameters

All API responses include these parameters.

Table 1. Common API response parameters
Parameter Type Description
responseData object Contains information or error response data. All of the parameters that are listed in each response are part of and within the responseData object.
errors object List of error messages that are generated when a request is processed.
message string Human-readable error response.
code string Error code.
responseHeader object Contains request status, date, and log entry ID.
status string Result is "OK" or "Fail" depending on whether request succeeded or failed.

If "Fail", an array of errors is displayed in responseData.

now integer Timestamp of when response was sent from Manager to client in milliseconds since the UNIX epoch.
requestId string Request ID maps to a request in logs.
responseStatus string Matches responseHeader.status and is depreciated.