UpCloud

Errors

API responses use regular HTTP codes to indicate successful and failed requests. This guide covers the status codes and error types you might encounter when working with the UpCloud API.


Successful requests

Successful requests are responded with a response code between 200 and 299.

  • Name
    200 OK
    Description

    The request was successful.

  • Name
    201 Created
    Description

    The request resulted in the generation of a new resource such as a server or a storage.

  • Name
    202 Accepted
    Description

    The request resulted in the asynchronous creation or update of an existing resource.


Failed requests

Failed requests include a machine-readable error code and a human-readable error description in the response body. Invalid requests are responded with a response code between 400 and 499.

  • Name
    400 Bad Request
    Description

    The request has invalid, unknown or missing attributes or the request cannot be properly parsed.

  • Name
    401 Unauthorized
    Description

    The request does not use or fails authentication.

  • Name
    402 Payment Required
    Description

    The request cannot be processed because of insufficient credits.

  • Name
    403 Forbidden
    Description

    The request accesses resources owned by some other user.

  • Name
    404 Not Found
    Description

    The request accesses resources that do not exist, but may have existed before.

  • Name
    405 Method Not Allowed
    Description

    The request uses an invalid HTTP verb, e.g. use POST on an operation that only accepts GET.

  • Name
    406 Not Acceptable
    Description

    The request has requirements given in the Accept headers that the API service cannot comply with.

  • Name
    409 Conflict
    Description

    The request cannot be processed because of a conflict between resources, e.g. trying to start an already started server.

Error Response

GET
/1.3/server/{uuid}
curl -X GET https://api.upcloud.com/1.3/server/00af0f73-7082-4283-b925-811d1585774b \
  -u your_username:your_password

API errors

Should there be a problem with the API service, a request is responded with an error code between 500 and 599.

  • Name
    500 Internal Server Error
    Description

    The request cannot be processed because of a temporary problem in the cloud service.

  • Name
    503 Service Unavailable
    Description

    The API service is not in use because of maintenance.

Error response format

The error_code parameter defines the specific error code. The error codes are defined under each operation in this API documentation.

The error_message parameter gives a human-readable error description that can include dynamic content such as UUIDs of resources to help track down the source of the error.

Server Error

GET
/1.3/server
curl -X GET https://api.upcloud.com/1.3/server \
  -u your_username:your_password