Documentation Install and integrate

API endpoint reference

Find the current endpoints, required abilities, and response rules.

An API token grants selected abilities within one team.
An API token grants selected abilities within one team.

Product screen with sample data. Intake is the previous working name.

Authentication

All endpoints below start with /api and require a team bearer token. Send Accept: application/json. For a JSON body, also send Content-Type: application/json.

Run endpoints

Method and path Ability
POST /runs runs:write
POST /runs/{run_id}/answers runs:write
POST /runs/{run_id}/cancel runs:write
GET /runs runs:read
GET /runs/{run_id} runs:read
GET /runs/{run_id}/judgments runs:read
POST /runs/{run_id}/handled runs:handle
DELETE /runs/{run_id}/handled runs:handle

The run list returns runs and next_cursor. Pass the cursor to request the next page. The maximum limit is 100.

Run presentation fields

Every start, answer, identical answer retry, and run read response includes these additive keys:

Key Value
reply Authored plain text, or null.
reply_action An object with exactly label and url, or null.

Synthetic completed presentation fields:

{
  "reply": "Read the billing help page for the next step.",
  "reply_action": {
    "label": "Open billing help",
    "url": "https://example.com/billing"
  }
}

These are fields within the run view, not a separate endpoint. Only complete with an authored reply supplies text. ask, handoff, cancellation, and an outcome without a reply return both fields as null. A reply without a destination has reply_action: null.

The lookup uses the run’s published version. It does not call Jev, send mail, write a receipt, or change the verdict or summary. Integrators own delivery and safe link rendering.

Author reply fields

Each non-handoff outcome can have an optional reply and destination in the draft. destination has exactly label and url. A reply is 1 to 2000 Unicode characters after line-ending normalization. Its text is not trimmed. A label is trimmed and has 1 to 80 characters. The address is at most 2048 characters and must be public HTTPS with a DNS host. Credentials, fragments, IP hosts, whitespace, backslashes, and malformed escapes are rejected.

Blank replies, forbidden controls, orphan destinations, partial destinations, and reply fields on needs_human block publication. Draft/check/publish abilities, expected hashes, and locking rules remain the same.

Request type endpoints

Method and path Ability
GET /case-type-templates case-types:read
GET /case-types case-types:read
GET /case-types/{slug} case-types:read
GET /case-types/{slug}/versions/{version} case-types:read
GET /case-types/{slug}/editor case-types:read
POST /case-types/{slug}/judgments case-types:read; also case-types:write for fresh judgments
POST /case-types case-types:write
PUT /case-types/{slug}/draft case-types:write
POST /case-types/{slug}/checks case-types:write
POST /case-types/{slug}/publish case-types:write
PATCH /case-types/{slug} case-types:write
POST /case-types/{slug}/archive case-types:write
POST /case-types/{slug}/restore case-types:write
POST /case-types/{slug}/probe case-types:write

GET /case-type-templates lists the templates in the gallery's order. Each entry has template, group, title, description, the counts asks, rubrics, outcomes and examples, and outcome_list. Each item in outcome_list has code, label and reply. reply is true when the template's outcome has an outcome reply. group is a key, such as front_desk. The description is in the installation's language.

Draft writes use the contract’s expected hash to detect a changed draft. Read the current document before a change. Treat a conflict as a request to review the newer draft.

To create a request type, send POST /api/case-types with {"title":"Support triage","template":"support_triage"}. This example is synthetic. Omit template to start from Blank. The title must contain 1 to 120 characters after trimming. The server makes the slug from the title and adds _2, _3, or the next free suffix when needed. Archived request types still reserve their slugs.

An integration can supply slug with the pattern ^[a-z][a-z0-9_]{1,63}$. A taken slug or any unknown body field gives 422 invalid_request. Success returns 201 with the allocated slug.

Send an Idempotency-Key header of 1 to 64 characters when you may need to retry. Keep the same header and body until you receive an answer. An identical retry returns the original request type with 200, even after its title changes. A different body with that key gives 409 idempotency_conflict. Without the header, each call creates another request type.

Examples and replay

Method and path Ability
GET /case-types/{slug}/examples case-types:read
POST /case-types/{slug}/examples examples:write
DELETE /examples/{example} examples:write
POST /runs/{run_id}/examples examples:write
POST /case-types/{slug}/replays examples:write
GET /replays/{replay} case-types:read

An example contains answers and expected. Each answer has a step_id and value. The expected value is an outcome code.

Read an error

{
  "error": {
    "code": "stale_step",
    "message": "This step was already answered."
  }
}
HTTP status Meaning
401 Missing, expired, revoked, or invalid token.
403 Missing ability or an action that demo mode refuses.
404 Missing resource or a resource in another team.
409 Conflicting state, answer, draft, or idempotency key.
422 Invalid body, answer, publish checks, or unavailable request type.
429 Rate limit reached; read Retry-After.

Engine failure is part of the run view. It can return HTTP 200 with a handoff or a retry on the same step.

Limits

The current contract permits 600 requests per minute per API token and 30 answers per minute per run. Hosted creation has separate limits. Always handle 429 responses even if your average usage is lower.

Continue

Follow a complete API request before implementing advanced request type editing.

Find an answer

Try “publish”, “API”, or “human handoff”.