Callback requests and responses
Request body
Each callback request sent by API Callback Gateway includes the following fields that must be processed by the callback handler:
Field |
Type |
Description |
---|---|---|
|
string |
An identifier of the callback request. The callback handler can verify whether this identifier matches the one defined for this callback. Example: |
|
string |
A UUID of the request. |
|
string |
A date in RFC3339 format when the request was made. |
|
object |
An object containing the information about the context of the request. |
|
string |
An identifier of the callback. The callback handler must use this identifier to identify which action needs to be done and which responses can be provided. Example: |
|
string |
An identifier of the endpoint. The callback handler can use this identifier to verify whether the request was intended for the endpoint where it is located. |
|
string |
An identifier of the tenant ID from which the request was made. |
|
string |
The URL of Acronis data center from which the request was made. |
|
object |
An object containing the data structure specified for the callback request. Optional if not specified. |
Response body
Each callback response sent by the callback handler must include the following fields:
Field |
Type |
Description |
---|---|---|
|
string |
An identifier of the callback response. The response identifier must match one of the identifiers defined for this callback. Example: |
|
string |
A UUID of the request that corresponds to this response. |
|
string |
A UUID of the response. |
|
object |
An object containing the data structure configured for the callback response. Optional if not specified. |
Request headers
To successfully process the requests coming from API Callback Gateway, the callback handler must check the following headers that are sent with each request:
Header |
Description |
---|---|
X-CyberApp-Auth |
An authentication header containing the base64-encoded credentials from ISV’s cloud. The credentials format is |
X-CyberApp-Extra |
A header containing extra data specified by the ISV. The data is formatted as a base64-encoded JSON text. For example, if extra data was not provided, the header will contain the |
Default error handling
While callbacks may define their own error responses, the API Callback Gateway provides default handling for specific HTTP error response codes and communication errors.
Default error response codes
The following HTTP status codes do not need to be specified in the callbacks and will be processed by the API Callback Gateway. A corresponding error message will also be rendered in the user interface for MSPs and end customers:
HTTP code |
Description |
UI message |
---|---|---|
401 Unauthorized |
Callback handler rejected the unauthorized request. |
Connection to |
403 Forbidden |
Callback handler rejected the request due to invalid credentials. |
Connection to |
410 Gone |
Callback handler is no longer available at the provided URL. |
Response from to |
429 Too Many Requests |
Callback handler rejected the request due to too many requests. The request can be retried by API Callback Gateway. |
- |
500-599 |
Callback handler responded with an error that indicates a server error. |
Connection to |
Where <application_name>
is your CyberApp name.
Communication errors
The following communication errors will be handled by the API Callback Gateway and a corresponding error message will be rendered in the user interface for MSPs and End Customers:
Error |
Description |
UI message |
---|---|---|
TLS handshake failed |
API Callback Gateway was unable to negotiate the secure protocol with the callback handler. |
Connection to |
Invalid SSL certificate |
API Callback Gateway was unable to verify the SSL certificate of the callback handler domain name. |
Connection to |
Server is unreachable |
API Callback Gateway was unable to find a route to the callback handler. The request can be retried by API Callback Gateway. |
Connection to |
Connection timed out |
API Callback Gateway was able to establish the connection but did not receive a response within the specific time. The request can be retried by API Callback Gateway. |
Connection to |
Unexpected 2xx-3xx response |
Callback handler responded with a response within the 200-399 range that does not match any code defined for this callback. |
Response from to |
Unexpected 4xx response |
Callback handler responded with a response within the 400-499 range that does not match any code defined for this callback or in the Status codes table. |
Response from to |
Response schema error |
Callback handler responded with a structure that does not match the schema defined for this callback. |
Response from to |
Request schema error |
Callback handler received a request from the user interface which structure does not match the schema defined for this callback. |
Request to |
Where <application_name>
is your application name.