Status and error codes

All API responses are assigned specific numeric codes that allow you to quickly identify if a request to an endpoint has been successful or not; and if not, why.

You may inspect response codes via curl by adding the --include option:

curl -s https://eu2-cloud.acronis.com/api/2/clients/<your client ID> \
     --header "Authorization: Bearer <your token>" \
     --include

Then, the first line of the response output will contain the code, which is 200 (a successful request) in the following output:

HTTP/1.1 200 OK
<...> 
{"created_by": "f90e086b...","last_access_at": "2020-05-22T10:13:28+00:00","tenant_id": "e5afb5e8...", ...}

HTTP status codes

Here is the summary of the response codes returned by the API, along with their descriptions. The API reference provides the list of error codes and their detailed descriptions for each endpoint.

Code

Description

20x

A request to an endpoint has been successful and the response body may contain a JSON object with the results.

400

A request to an endpoint has failed and the response body contains a JSON object with the error details. See an example of such response below.

401

Cannot process a request to an endpoint because the token specified in the Authorization header is expired or invalid.

403

Cannot process a request to an endpoint because your account has no right to access this endpoint. For example, the account does not own a tenant being accessed.

404

A request to a non-existing endpoint or no requested data is found in the service.

405

A request uses a method that is not supported by the endpoint.

409

Another object of the same type already exists.

415

A request uses a format that is not supported by the endpoint. This problem might occur when an incorrect or no Content-Type header was provided in a request.

50x

A service operation issue. In such cases, it is a good practice to retry the request twice with a 1-2 seconds interval. If the issue is not resolved after retrying, contact the company administrator or try again later.