Skip to content

What to expect from us ​

Doppio uses standard HTTP response codes so our API responses stay easy to understand. The table below explains what each status code means:

Status codeMeaningDescription
200OKThe request succeeded.
400Bad RequestThe server cannot or will not process the request because of an apparent client error, such as malformed request syntax or invalid parameters.
401UnauthorizedNo valid API key provided.
403ForbiddenYour subscription is inactive, or it does not include the requested functionality.
404Not FoundThe requested resource does not exist.
408Request TimeoutThe request was not received in full in time, for example over a very slow connection.
413Payload Too LargeThe request body is too large. Contact support if you need help.
422Unprocessable EntityThe total number of requests exceeds your subscription limits.
429Too Many RequestsToo many requests were sent to the server in a short period of time.
500Internal Server ErrorAn error occurred on Doppio's server, or a /sync or /direct render failed.
502, 503Bad Gateway, Service UnavailableDoppio's server is temporarily unreachable. Retry later.
504Gateway TimeoutThe response took longer than our network layer allows, for example a very long synchronous render. For long renders, prefer an async render.

Error Response ​

When our API rejects a request with a 4xx status code, it returns a JSON payload such as:

json
{
    "statusCode": 403,
    "message": "Current subscription does not allow async requests.",
    "error": "Forbidden",
    "code": "ASYNC_NOT_ALLOWED"
}
FieldDescription
statusCodeThe status code, as in the table above.
messageDetails about the error: a string, or an array of strings for validation errors. Messages are meant for humans and may change, so don't parse them.
errorThe meaning of the status code, as in the table above. Some errors, such as 413 and 429, don't include it.
codeA stable code, only in the errors listed in Error Codes.

Here are a few examples of messages you might receive for a Bad Request error:

  • page.goto.url must be an URL address
  • page.goto and setContent are mutually exclusive
  • Expected double-quoted property name in JSON at position 49 (line 1 column 50)

The body of other errors can differ. When a /sync or /direct render fails, the API answers 500 with a render response whose renderStatus is ERROR. The 408, 502, 503 and 504 statuses come from our network layer, not from the API, and have no JSON body: rely on the status code.

Error Codes ​

The errors below include a code. Unlike the message, the code of an error does not change: use it to handle the error in your integration.

CodeStatus codeDescription
INVALID_API_KEY401The API key is missing or does not belong to any organization.
UNPAID_INVOICES403Your organization is blocked because of unpaid invoices.
ASYNC_NOT_ALLOWED403The plan of your organization does not allow asynchronous renders.
TEMPLATES_NOT_ALLOWED403The plan of your organization does not allow templates.
TEMPLATE_NOT_FOUND404The template does not exist in your organization.
MONTHLY_QUOTA_REACHED422Your organization has reached the monthly request limit of its plan.
RATE_LIMIT_EXCEEDED429Your organization sends requests faster than its plan allows.

Compatibility ​

Success responses and webhook payloads don't change. We may add new fields to error responses, and new codes. To keep your integration working:

  • ignore unknown fields;
  • handle unknown codes, for example by falling back on the status code;
  • rely on code and the status code, not on message.

All rights reserved