Skip to main content

Developers · Guide

Errors

What every error code means, the status it comes with, and which ones are safe to retry.

A refused request answers a 4xx or 5xx status with a small JSON body. error is a machine code your system switches on; error_description, where present, is a fixed English sentence for the person reading a log.

A refusal
{
  "error": "invalid_request",
  "error_description": "limit is invalid"
}
  • invalid_transition also carries current_status, the state the record is in.
  • validation_failed also carries fields, the name of each field the product’s own form would refuse.
  • A write refused for any reason has changed nothing.

Every code

Error codes
StatusCodeWhen
400idempotency_key_requiredThe write has no Idempotency-Key header of 1 to 255 characters.
400invalid_requestA query parameter is invalid, or a write’s body is not a JSON object.
400unsupported_grant_typeThe grant type is not client_credentials.
401invalid_clientClient authentication failed: an unknown client_id, a wrong secret, a revoked credential or another Organisation’s, or API access is not Full.
401invalid_tokenThe token is missing, invalid, expired or revoked, of another Organisation, or API access is not Full. Ask for a new token.
403approval_limit_exceededThe amount is above the run-as Administrator’s approval limit.
403forbiddenThe run-as Administrator lacks the permission, or the record is outside their Data Access Rules.
403https_requiredThe request was sent over plain HTTP and was not processed.
403insufficient_scopeThe credential does not hold the scope the route needs.
403run_as_disabledThe credential has no run-as Administrator, or that person is no longer one.
404module_disabledThe Organisation has the module this route belongs to turned off.
404not_foundAn unknown host or path, or an id that is unknown, deleted or of another Organisation.
405method_not_allowedThe method is not served on this path. Allow lists what is: GET, HEAD on a read path, POST on /oauth/token, the write’s own method on a write path.
409conflict_declaredThe Assessor has declared a conflict of interest with an application.
409file_not_scannedThe file has not finished its malware scan; try the attach again shortly.
409idempotency_in_progressThe first request with this Idempotency-Key has not finished. Nothing was written; retry after the given seconds.
409invalid_stateThe record is not in a state that admits this write.
409invalid_transitionThe move is not open from where the record stands; current_status says where that is.
412precondition_failedIf-Match is missing, malformed or not the record’s current lock_version, or the record changed under the write. Nothing was written.
413payload_too_largeThe body, or the declared file, is larger than the limit that applies.
415unsupported_media_typeThe body is not application/json, or the target does not accept the file’s content type.
422file_infectedThe file failed its malware scan and was not attached.
422idempotency_key_reusedThe Idempotency-Key was used in the last 24 hours for a different method, path or body.
422unknown_fieldThe body has a property the route does not document; the first is named.
422unknown_tagA tag is not one of the Organisation’s tags. None is created.
422validation_failedBody values the product’s own form would refuse; fields names each.
429rate_limitedA rate limit was exceeded: 120 requests a minute per credential, 30 token requests a minute per client_id.
500server_errorAn unexpected server error.
503temporarily_unavailableThe Organisation’s API access cannot be determined, or a dependency is unavailable. Retry after the given seconds.

Which to retry

  • 429 rate_limited, 503 temporarily_unavailable and 409 idempotency_in_progress carry Retry-After: wait that many seconds and send the same request again, with the same Idempotency-Key for a write.
  • 500 server_error: retry a read later. Retry a write with the same Idempotency-Key, so that a write that did happen is answered again rather than made twice. See the idempotency guide.
  • 401 invalid_token: ask for a new token, then retry.
  • Anything else is about the request itself: change it before you send it again.

The OData reporting feed answers its own query errors in the OData error body: 400 bad_request, 404 not_found, 410 delta_token_expired, 501 not_implemented. See Power BI and Idempotency.