API Responses
This section describes how Apex Central responds to API requests.
After sending an authorization request to the intended API, Apex Central returns a JSON-formatted response object. The response format depends on the accessed resource.
General API Responses
Apex Central returns JSON-formatted responses and uses standard HTTP response codes.
Apex Central returns a JSON-formatted response object in the following format:
{
'Data': (if provided, a JSON object representing the return value of the API),
'Meta': {
'Result': (an integer indicating the result of this API call),
'ErrorCode': (an integer indicating the nature of an encountered error),
'ErrorMsg': (a string describing the error code)
},
'PermissionCtrl': (an object indicating the permissions assigned to the logged-on user account for accessing Apex Central features),
'FeatureCtrl': (an object indicating the Apex Central deployment model),
'SystemCtrl': (an object indicating the suspicious object distribution role of the Apex Central server)
}
The following table provides more information on certain fields in the response body.
Field |
Details |
---|---|
PermissionCtrl |
|
FeatureCtrl |
mode: An integer indicating the deployment model
|
SystemCtrl |
TmcmSoDist_Role: A string indicating the suspicious object distribution role
|
The following table lists the possible responses.
HTTP Status Code |
Response Status |
Response Body |
---|---|---|
200 |
Successful |
|
400 |
Unsuccessful due to invalid parameters |
|
401 |
Unsuccessful due to authorization error |
|
500 |
Unknown error |
|
Server and Security Agent API Responses
This section describes the JSON-formatted responses and standard HTTP response codes for Server and Security Agent APIs.
Apex Central returns a JSON-formatted response object in the following format:
{
"result_code":(an integer indicating the result of this API call),
"result_description":"(a string describing the result code)",
"result_content":"(if provided, a JSON object representing the return value of the API)"
}
The result_description
field in the response body is subject to
change. If your application depends on Apex
Central API responses, use the result_code
value.
For a complete list of result_code
status values, see API Result Codes.
The following table lists the possible responses.
HTTP Status Code |
Response Status |
Response Body |
---|---|---|
200 |
Successful |
|
400 |
Unsuccessful due to invalid parameters |
|
401 |
Unsuccessful due to authorization error |
|
500 |
Unknown error |
|
API Result Codes
Apex Central uses standard HTTP response codes.
The following table lists the Apex Central Automation API result codes and the corresponding descriptions:
Result Code |
Description |
---|---|
1 |
Operation successful |
-2 |
Authentication unsuccessful: Authentication token not provided. |
-3 |
Authentication unsuccessful: Malformed authentication token |
-4 |
Authentication unsuccessful: Unsupported authentication token version |
-5 |
Authentication unsuccessful: Invalid application ID |
-6 |
Authentication unsuccessful: Authentication token expired |
-7 |
Authentication unsuccessful: Invalid authentication token signature |
-8 |
Authentication unsuccessful: Invalid request checksum |
-9 |
Authentication unsuccessful: Unsupported authentication token signing algorithm |
-21 |
Invalid input parameters |
-22 |
Action invalid |
-50 |
Unsupported HTTP method |
-99 |
Internal server error |
-102 |
Agent action unsuccessful: Multiple matches not supported |
-103 |
Agent action unsuccessful: Unable to isolate agents reporting to another Apex Central server |
-104 |
Agent action unsuccessful: Unable to connect to remote server |
-105 |
Agent action unsuccessful: Target server not found |
-106 |
Agent action unsuccessful: Target server managed by a child Apex Central server |
-107 |
Agent action unsuccessful: Target server does not support command |
-1101 |
Suspicious object action unsuccessful: Maximum quantity exceeded |
-1102 |
Suspicious object action unsuccessful: Unable to generate Scan Prefilter for uploaded file, file likely to be blocked by antivirus |