Skip to content

Errors

Every error has the same JSON shape and a stable, machine-readable code. Branch on the code, show the message to people, and quote the request ID when you contact support.

The error object

Error responses use a 4xx or 5xx status and this body:

403 Forbidden
{
  "error": {
    "code": "insufficient_scope",
    "message": "This API key is missing the scope `changes:approve`.",
    "details": {
      "required": [
        "changes:approve"
      ],
      "missing": [
        "changes:approve"
      ]
    },
    "requestId": "req_8fK2mQx1Lz0a",
    "docs": "https://semanticson.com/developers/errors#insufficient_scope"
  }
}
FieldDescription
codeStable identifier. Listed below; new codes may be added, so handle unknown codes by their HTTP status.
messageA readable explanation in English. It can change; do not parse it.
detailsOptional. For validation errors, an array of { field, message } where field is prefixed with path., query. or body. (for example body.url). For scope errors, { required, missing }. For plan limits, { upgrade: true }.
requestIdAlso returned in the x-request-id header of every response. Include it in support requests.
docsA link to the explanation of the code on this page.

Validation errors list every field at fault:

400 Bad Request
{
  "error": {
    "code": "invalid_request",
    "message": "The request body is invalid.",
    "details": [
      {
        "field": "body.url",
        "message": "Invalid input: expected string, received undefined"
      }
    ],
    "requestId": "req_Qm41sLx9Ta2c",
    "docs": "https://semanticson.com/developers/errors#invalid_request"
  }
}

HTTP statuses

StatusMeaning
200 OKThe request succeeded.
201 CreatedA resource was created; the body is the new object.
202 AcceptedWork was queued (tool runs, crawl audits). Poll the returned object for the result.
204 No ContentDeleted. The body is empty.
400 Bad RequestInvalid JSON, invalid fields or an action the resource's state does not allow.
401 UnauthorizedMissing, invalid or revoked key.
402 Payment RequiredA plan limit blocks the action (tool not in plan, run or AI allowance used up).
403 ForbiddenThe key is valid but not allowed: missing scope, wrong key type, read-only access or plan restriction.
404 Not FoundNo such endpoint, or a resource that does not exist or is not visible to this key.
409 ConflictDuplicate resource, Idempotency-Key conflict, or a precondition such as no synced pages.
413 Payload Too LargeThe body is larger than 4 MB.
429 Too Many RequestsPer-minute rate limit or monthly allowance reached. See Retry-After.
500 Internal Server ErrorAn unexpected error on our side. Safe to retry with backoff.

Error codes

Each code has its own anchor, so an error's docs link lands on the right row.

Authentication

CodeStatusMeaningWhat to do
unauthorized401No API key was sent, or the Authorization header is not in the form Bearer <key>.Send Authorization: Bearer <key> with every request (except POST /connect/exchange and the OpenAPI document).
invalid_api_key401The key is malformed, unknown, revoked, or a site key whose website record no longer exists.Check that the full key was copied (it starts with so_live_ or so_site_). Create a new key in API Settings, or reconnect the website for site keys.
site_disconnected401The site key belongs to a website that was disconnected.Connect the website again (one-click connect or POST /sites) and store the new site key.
account_inactive403The account that owns the key is suspended or closed.Sign in to the dashboard or contact support.
api_access_not_in_plan403Account keys need a plan that includes API access.Upgrade the plan. Site keys of connected websites keep working on every plan.
site_limit_exceeded403The account has more connected websites than its plan includes; the newest websites beyond the limit are paused.Upgrade, or disconnect another website. The oldest websites keep working.
site_key_required403The endpoint belongs to the site protocol and only accepts a site key.Call it with the so_site_ key issued when the website was connected.
user_key_required403Site keys cannot call this endpoint (for example connecting websites or approving changes through the general API).Use an account key (so_live_).
insufficient_scope403The key does not have every scope the endpoint requires. details.required and details.missing list them.Create a key with the missing scopes, or use a key with the Full access preset.
forbidden403Your role in the workspace does not allow this action (for example only owners and admins can delete a project).Ask a workspace owner or admin to do it, or to change your role.
read_only403You have read-only (client) access to this project, so you cannot change it.Ask the workspace owner for edit access.

Request

CodeStatusMeaningWhat to do
invalid_request400A path, query or body value failed validation, or the action is not allowed in the resource's current state (for example approving a change that was already rejected). details lists each field and message when fields are at fault.Fix the fields listed in details and send the request again. For state errors, read the resource first.
invalid_json400The request body is not valid JSON.Send a JSON body with Content-Type: application/json.
invalid_input400The input of a tool run does not match the tool's fields.Read the tool's fields from GET /tools and send values for the required ones.
payload_too_large413The request body is larger than 4 MB.Send fewer items per request (for example fewer pages per POST /site/pages batch).
invalid_grant400One-click connect: the code is invalid, expired (10 minutes), already used, issued for another website address, or the PKCE verifier does not match.Start the connection again from the website. Codes are single-use, even after a failed attempt.
invalid_url400The URL cannot receive webhooks, for example because it is not public http(s) or points to a private address.Use a public https URL that resolves to a public IP address.
invalid_hierarchy400The topical map change breaks the map's structure: for example moving a page underneath itself, going deeper than the supporting level, or moving or deleting the central node.Read the message for the exact rule and choose a different parent or type.
no_report_data400None of the chosen report sections has data in this project yet.Pick sections that have data, or run the tools that produce it first.
no_pages_synced409A site audit was requested before the website synced any pages.Run a full page sync from the website, then start the audit.

Not found & conflicts

CodeStatusMeaningWhat to do
not_found404The URL does not match any API endpoint, or the resource no longer exists.Check the method and path against the API reference.
*_not_found404Codes ending in _not_found (such as project_not_found, site_not_found, change_not_found, audit_not_found, tool_not_found) mean the resource does not exist or your key cannot see it. Other accounts' resources are always reported as not found.Check the ID, and that the key belongs to an account with access. Site keys only see their own project.
conflict409A resource with the same unique values already exists.Read the existing resource instead of creating it again.
project_archived409The project is archived, so its content cannot be changed.Restore it with PATCH /projects/{projectId} and { "status": "active" }, then retry.
cluster_exists409A cluster with that name already exists in the project. details.clusterId is the existing cluster.Use the existing cluster, or choose another name.
entity_exists409An entity with that name already exists in the project. details.entityId is the existing entity.Update the existing entity instead.
relation_exists409That relation between the two entities already exists.Nothing to do; read or update the existing relation.
node_locked409The topical map page (or a page beneath it) is locked, so it cannot be moved or deleted.Unlock it with locked: false, then retry.
execution_not_succeeded409The tool run has not succeeded (it is queued, running, failed or cancelled), so it cannot be exported.Wait for status: "succeeded" before exporting.
webhook_limit_reached409The workspace already has the maximum number of webhooks.Delete a webhook you no longer use, or subscribe an existing one to more events.
idempotency_key_reused409The Idempotency-Key was already used with a different method, path or body.Use a new key for every distinct request.
idempotency_in_progress409A request with the same Idempotency-Key is still being processed.Wait a moment and retry with the same key to receive the stored response.

Not-found codes in use: audit_not_found, brand_profile_not_found, brief_not_found, change_not_found, cluster_not_found, delivery_not_found, document_not_found, entity_not_found, execution_not_found, issue_not_found, keyword_not_found, link_not_found, map_not_found, media_not_found, node_not_found, page_not_found, project_not_found, redirect_not_found, relation_not_found, report_not_found, schedule_not_found, site_not_found, term_not_found, tool_not_found, topical_map_not_found, version_not_found, webhook_not_found.

Limits

CodeStatusMeaningWhat to do
rate_limited429Too many requests per minute for this key, or tool runs started too quickly. The Retry-After header says how many seconds to wait.Wait for Retry-After seconds, then retry. Spread requests out.
monthly_limit_reached429The account used every API request its plan includes for the current billing period.Wait for the next period or upgrade. Site key traffic is not counted.
tool_not_in_plan402The tool is not included in the account's plan. details.upgrade is true.Upgrade to a plan that includes the tool (GET /tools shows includedInPlan).
run_limit402The daily, weekly or monthly tool run limit of the plan is reached.Wait for the limit to reset or upgrade.
tool_daily_limit402This tool's own daily run limit is reached.Try again tomorrow or upgrade.
tool_monthly_limit402This tool's own monthly run limit is reached.Wait for the next period or upgrade.
ai_token_limit402The plan's monthly AI allowance is used up and there are no credits left.Add your own AI provider key in API Settings, buy credits (when offered) or upgrade.
project_limit402The plan's number of active projects is reached.Archive a project or upgrade.
export_not_in_plan402The export format is not included in the plan. details.allowed lists the formats you can use.Use an allowed format or upgrade.
feature_not_in_plan403The action needs a plan feature you do not have (for example deleting projects).Follow the suggestion in the message (such as archiving instead) or upgrade.
white_label_not_in_plan403White-label branding (brand profiles on exports and reports) is not included in the plan.Leave out brandId, or upgrade to a plan with white-label.
tool_disabled404The tool is temporarily unavailable.Try again later or choose another tool from GET /tools.

Server

CodeStatusMeaningWhat to do
internal_error500Something went wrong on our side. The error was logged.Retry with backoff (with the same Idempotency-Key for writes). If it persists, contact support with the requestId.

Handling errors

  • Branch on error.code, fall back to the HTTP status for codes you do not know.
  • Retry only what can succeed later: 429 (after Retry-After), 409 idempotency_in_progress and 5xx. Do not retry other 4xx errors unchanged.
  • Use exponential backoff for 5xx and network errors (for example 1 s, 2 s, 4 s … up to a minute), and send writes with an Idempotency-Key so a retry cannot act twice.
  • Show message to people where it helps (it is written for humans), and log requestId.

Not found means “not yours” too

Resources owned by other accounts are reported as 404, never 403, so IDs cannot be probed.