AI Glot websiteOpen AI Glot
REST APIErrors

Errors

Handle AI Glot API failures using stable error codes, request IDs, retry guidance and anchored explanations for every documented error.

Every API failure uses one envelope. Branch on error.code, never on the human-readable message.

Example error
{
  "error": {
    "type": "permission_error",
    "code": "insufficient_scope",
    "message": "This credential is missing the batches:write scope.",
    "docs_url": "https://ai-glot.com/docs/api/errors#insufficient_scope"
  },
  "request_id": "req_example"
}

Status codes

StatusMeaningWhat to do
400Malformed request or unknown fieldFix the request
401Credential missing, invalid, expired or revokedReplace or renew it
403Authenticated but not allowedGrant the required scope or feature
404Resource absent or outside this workspaceCheck the ID and workspace
409Current state conflicts with the requestRead the resource, then decide
413Request body too largeSend a smaller body
422Well-formed but invalid valueFix the named value
429Rate limitedWait for Retry-After
500/503AI Glot failed or is temporarily unavailableRetry with backoff

Authentication and permission codes

authentication_required

No bearer credential was sent. Add the Authorization header.

invalid_api_key

The key is malformed or unknown. Check that the entire aig_live_… value was copied.

api_key_expired

The key reached its configured expiry. Create or use a replacement.

api_key_revoked

An admin revoked or rotated this key. Update the integration with an active credential.

insufficient_scope

The credential authenticated but lacks the scope required by this operation.

feature_not_available

The workspace plan or current platform version does not include the requested feature.

admin_required

Only a workspace admin may perform the operation.

Request codes

invalid_request

The request cannot be parsed or does not match the endpoint contract.

unknown_field

A query or body field is not recognised. Correct the spelling rather than removing validation.

invalid_parameter

A parameter has the wrong type, range or format.

invalid_cursor

The pagination cursor is invalid. Reuse next_cursor exactly as returned.

request_too_large

The request body exceeds the endpoint’s hard limit.

Resource and state codes

batch_not_found

No visible translation has that ID. Resources in another workspace intentionally return the same error.

glossary_not_found

No glossary exists for that language pair.

resource_not_found

The requested resource or route does not exist.

glossary_already_exists

A glossary already exists for this language pair. Update it instead of creating another.

result_not_ready

The translation has not completed, so no result can be downloaded yet.

batch_not_editable

The translation’s current state does not allow the requested housekeeping change.

Language and glossary codes

language_not_supported

The tag is outside the supported catalogue. Read GET /v1/languages.

invalid_language_pair

The language-pair identifier cannot be split into two supported BCP 47 tags.

glossary_term_limit_reached

The resulting term count would exceed the workspace plan’s allowance. The update is atomic; nothing changed.

glossary_limit_reached

The workspace has reached its number of glossaries for the current plan.

invalid_glossary_terms

One or more glossary entries are empty, incomplete or otherwise invalid.

Service codes

rate_limited

The credential exceeded a rate window. Wait for Retry-After, then retry with jitter.

internal_error

AI Glot failed unexpectedly. Retry with backoff and retain the request_id.

service_unavailable

A required service is temporarily unavailable. Retry with backoff.

Use these docs with your AI tools

An AI agent can read this documentation directly. You do not need an account or an API key. Everything here is public and read-only.

Query these docs via MCP

Recommended

Add this server to Claude, Claude Code, Cursor, Mistral, or any tool that supports MCP. Your agent can then search AI Glot Docs documentation and read it in full, instead of answering from memory.

https://ai-glot.com/docs/mcp
  • searchFind the passages that answer a question.
  • fetchRead one page in full, as Markdown.
  • list_pagesSee every page in this documentation.

Query these docs over HTTP

The same tools also work as plain web requests. Use this for scripts, or for any tool that does not support MCP. There is one endpoint per tool. Arguments go in the query string, and the answer comes back as JSON.

https://ai-glot.com/docs/api/docs/search?query=custom+domain

Read the OpenAPI description. It is built from the same definitions as the tools, so it always matches what the endpoints do.

Read these docs as Markdown

Add .md to any page URL to get its Markdown source. You can also send the headerAccept: text/markdown to the page URL itself.

To read the whole documentation in one file, open llms-full.txt. For a short index of every page, open llms.txt.