VideohatiDocs
API reference

Errors

The error envelope, status-code map, and shared error codes.

Every error response uses one envelope:

{
  "error": {
    "code": "<machine_code>",
    "message": "<human text>"
  }
}
  • code is a machine-readable snake_case string. Branch on this, not the HTTP status alone.
  • message is a human-readable English string for logs and developer display.

Each operation page lists the exact code values that operation emits.

Status codes

StatusMeaning
400The request body or query failed validation.
401No valid credential was presented.
403The credential is valid but does not permit this action.
404The resource does not exist or is not visible to the caller.
409The request conflicts with the resource's current state.
429Rate limit exceeded.
500The server failed to complete the request.

Shared codes

These appear across many operations:

CodeStatusMeaning
invalid_body400Request body failed validation.
invalid_input400A field failed validation.
unauthorized401Authentication required.
insufficient_scope403The API key lacks the required scope.
not_found404Resource not found or not visible.
already_revoked409The target resource is already revoked.
rate_limit_exceeded429Too many requests; see Retry-After.
internal_error500Unexpected server error.

Rate limiting

A 429 carries three headers:

  • X-RateLimit-Limit — the ceiling for the window.
  • X-RateLimit-Remaining — requests left in the window.
  • Retry-After — seconds to wait before retrying.

Back off until Retry-After elapses, then retry the same request.