Skip to content
Browse the reference

Developers

API reference

Every endpoint a workspace API key can call, the webhook events ASDK sends and the objects they carry. Generated from the API contract, so it always matches the API.

Base URL
https://api.asdk.com
Version
0.1.0 · OpenAPI 3.1.0 · OpenAPI description (JSON)

Overview

Coming soon API access

The public API and the MCP server are coming soon. Server-side answers, knowledge search and the MCP server are part of API access, included from the Business plan and during the trial. Webhooks are in early access and included from the Starter plan. Reads with an API key work on every plan.

Send a workspace API key as a bearer token. Create keys in the dashboard under Settings → API; a key acts on its own workspace only. Keys with the read scope call the read endpoints; keys with the write scope also call the endpoints marked “Write scope”. Errors are RFC 9457 problem details with a stable type, such as insufficient-scope or rate-limited (retry after the Retry-After header).

Shell
curl https://api.asdk.com/v1/workspaces/$WORKSPACE_ID/sites \
  -H "Authorization: Bearer $ASDK_API_KEY"

Guides: authentication and scopes, webhooks, MCP server, rate limits.

Workspaces

Workspaces and their settings.

Get a workspace

GET/v1/workspaces/{id}· Read

Any member, or an API key of this workspace.

Parameters

Get a workspace: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

Responses

  • 200The workspace. (Workspace)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Whether ASDK suspended the workspace

GET/v1/workspaces/{id}/suspension· Read

Any member (and the workspace's API keys). A suspended workspace's widgets are unavailable and its dashboard is read-only: writes answer 403 (response WorkspaceSuspended). The dashboard shows a banner from this.

Parameters

Whether ASDK suspended the workspace: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

Responses

  • 200The workspace's suspension. (WorkspaceSuspension)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/suspension \
  -H "Authorization: Bearer $ASDK_API_KEY"

Sites

The websites a workspace's agents work on.

List the workspace's sites

GET/v1/workspaces/{id}/sites· Read

Every site with a summary of its knowledge, and the plan's site and page limits.

Parameters

List the workspace's sites: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

Responses

  • 200Sites, oldest first. (SiteList)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/sites \
  -H "Authorization: Bearer $ASDK_API_KEY"

A site

GET/v1/sites/{siteId}· Read

Parameters

A site: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

Responses

  • 200The site. (Site)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sites/{siteId} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Knowledge

Knowledge sources, their documents and Q&A pairs.

List a site's knowledge sources

GET/v1/sites/{siteId}/sources· Read

Sources, oldest first, including the site's Q&A source once it has pairs. Text snippet bodies are left out; read one source for its body.

Parameters

List a site's knowledge sources: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

Responses

  • 200The sources. (SourceList)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sites/{siteId}/sources \
  -H "Authorization: Bearer $ASDK_API_KEY"

A knowledge source

GET/v1/sources/{sourceId}· Read

Status and progress of the last or running sync; poll every few seconds while syncing.

Parameters

A knowledge source: Parameters
FieldTypeDescription
sourceIdpath · requiredstring (≤ 64 chars)

Knowledge source id (src_…).

Responses

  • 200The source. (Source)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sources/{sourceId} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Sync a source now

POST/v1/sources/{sourceId}/sync· Write scope

Reads the source again; unchanged pages are not embedded again. A request during a sync runs another sync after it.

Parameters

Sync a source now: Parameters
FieldTypeDescription
sourceIdpath · requiredstring (≤ 64 chars)

Knowledge source id (src_…).

Responses

  • 202The sync is queued. (Source)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 409Conflicts with the plan or the resource (types "limit-reached", "site-exists", "not-supported").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/sources/{sourceId}/sync \
  -H "Authorization: Bearer $ASDK_API_KEY"

List a source's documents

GET/v1/sources/{sourceId}/documents· Read

Ordered by URL, a page at a time; q searches URL and title.

Parameters

List a source's documents: Parameters
FieldTypeDescription
sourceIdpath · requiredstring (≤ 64 chars)

Knowledge source id (src_…).

qquery · optionalstring (≤ 200 chars)

Case-insensitive text search.

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–200)

Items per page (default 50).

statusquery · optional"pending" | "indexed" | "skipped" | "excluded" | "error"

Responses

  • 200A page of documents. (DocumentList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sources/{sourceId}/documents \
  -H "Authorization: Bearer $ASDK_API_KEY"

List a site's Q&A pairs

GET/v1/sites/{siteId}/qa· Read

Newest first, a page at a time; q searches questions and answers.

Parameters

List a site's Q&A pairs: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

qquery · optionalstring (≤ 200 chars)

Case-insensitive text search.

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–200)

Items per page (default 50).

Responses

  • 200A page of Q&A pairs. (QaPairList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sites/{siteId}/qa \
  -H "Authorization: Bearer $ASDK_API_KEY"

Add a Q&A pair

POST/v1/sites/{siteId}/qa· Write scope

Each pair is embedded as its own vector (kind qa), which the answer engine prefers on ties.

Parameters

Add a Q&A pair: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

Request body (QaPairInput)

Add a Q&A pair: Request body
FieldTypeDescription
questionrequiredstring (≤ 1,000 chars)
answerrequiredstring (≤ 8,000 chars)

Responses

  • 201The new pair, being embedded. (QaPair)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 409Conflicts with the plan or the resource (types "limit-reached", "site-exists", "not-supported").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/sites/{siteId}/qa \
  -H "Authorization: Bearer $ASDK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"question":"…","answer":"…"}'

Answers

Server-side answers from a site's knowledge (API keys with the write scope).

Answer a question from a site's knowledge

POST/v1/sites/{siteId}/ask· Write scope

Answers a question server-side exactly as the site's chat widget would: the same knowledge base, the same grounding and citations. grounded is false when the knowledge base did not cover the question (the question is then recorded as a knowledge gap).

Needs a person (any member) or an API key with the write scope, and API access in the workspace's plan ("not-in-plan" otherwise). While the catalog lists API access as coming soon, every workspace gets 403 "coming-soon". Every answer counts toward the plan's monthly answers; past the hard cap (110 % of the limit) the request answers 429 with type "answer-limit-reached" until the next month. Conversations are not stored.

Parameters

Answer a question from a site's knowledge: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

Request body (AskRequest)

Answer a question from a site's knowledge: Request body
FieldTypeDescription
questionrequiredstring (≤ 2,000 chars)

The question, as a visitor would ask it.

localeoptionalstring (≤ 35 chars)

BCP 47 language for short questions whose language cannot be told (e.g. de).

Responses

  • 200The answer. (AskAnswer)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 429Too many requests (type "rate-limited"); retry after the Retry-After header.
  • 503The feature is not configured on this server (type "unavailable").
  • 504The answer took too long (type "timeout"); try again.
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/sites/{siteId}/ask \
  -H "Authorization: Bearer $ASDK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"question":"…"}'

Conversations

Conversations of the widget, read and reviewed in the dashboard.

List conversations

GET/v1/workspaces/{id}/conversations· Read

Any member or an API key. Conversations with at least one message, latest activity first, a page at a time. q searches message texts and the lead's email and name.

Parameters

List conversations: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

agentquery · optional"chat" | "sales" | "search" | "forms" | "voice"
unansweredquery · optionalboolean

Only conversations with an answer that was not grounded in the site's content.

withLeadquery · optionalboolean

Only conversations where the visitor left contact details.

unreviewedquery · optionalboolean

Only conversations nobody marked reviewed.

previewsquery · optional"include" | "exclude" | "only"

Conversations and leads from the dashboard's preview — include (default), exclude or only.

qquery · optionalstring (≤ 200 chars)

Case-insensitive text search.

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–200)

Items per page (default 50).

Responses

  • 200A page of conversations. (ConversationList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/conversations \
  -H "Authorization: Bearer $ASDK_API_KEY"

A conversation

GET/v1/workspaces/{id}/conversations/{conversationId}· Read

Any member or an API key. Every message with its sources and the visitor's rating, the visitor, and the leads left in it.

Parameters

A conversation: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

conversationIdpath · requiredstring (≤ 64 chars)

Conversation id (conv_…).

Responses

  • 200The conversation. (ConversationDetail)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/conversations/{conversationId} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Leads

Contact details visitors left, their status and CSV export.

List leads

GET/v1/workspaces/{id}/leads· Read

Any member or an API key. Newest first, a page at a time, with the number of leads per status under the same filters. q searches email, name, company and note.

Parameters

List leads: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

statusquery · optional"new" | "contacted" | "archived"
previewsquery · optional"include" | "exclude" | "only"

Conversations and leads from the dashboard's preview — include (default), exclude or only.

qquery · optionalstring (≤ 200 chars)

Case-insensitive text search.

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–200)

Items per page (default 50).

Responses

  • 200A page of leads. (LeadList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/leads \
  -H "Authorization: Bearer $ASDK_API_KEY"

Export leads as CSV

GET/v1/workspaces/{id}/leads/export· Read

Any member or an API key. The leads matching the filters, newest first, at most 50,000: UTF-8 with a byte order mark, RFC 4180 quoting, and every cell that starts with =, +, -, @, a tab or a carriage return prefixed with an apostrophe so spreadsheets never run it as a formula.

Parameters

Export leads as CSV: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

statusquery · optional"new" | "contacted" | "archived"
previewsquery · optional"include" | "exclude" | "only"

Conversations and leads from the dashboard's preview — include (default), exclude or only.

qquery · optionalstring (≤ 200 chars)

Case-insensitive text search.

Responses

  • 200The CSV file. (string)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/leads/export \
  -H "Authorization: Bearer $ASDK_API_KEY"

A lead

GET/v1/workspaces/{id}/leads/{leadId}· Read

Any member or an API key. The lead with the conversation it was left in.

Parameters

A lead: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

leadIdpath · requiredstring (≤ 64 chars)

Lead id (lead_…).

Responses

  • 200The lead. (LeadDetail)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/leads/{leadId} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Change a lead's status

PATCH/v1/workspaces/{id}/leads/{leadId}· Write scope

Any member.

Parameters

Change a lead's status: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

leadIdpath · requiredstring (≤ 64 chars)

Lead id (lead_…).

Request body (LeadUpdate)

Change a lead's status: Request body
FieldTypeDescription
statusrequired"new" | "contacted" | "archived"

Responses

  • 200The lead after the change. (LeadDetail)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X PATCH https://api.asdk.com/v1/workspaces/{id}/leads/{leadId} \
  -H "Authorization: Bearer $ASDK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"status":"new"}'

Insights

Overview numbers, knowledge gaps and what visitors ask.

Overview of the workspace

GET/v1/workspaces/{id}/overview· Read

Any member or an API key. Conversations, answers, grounded rate, leads and ratings of the last days days (whole days in the workspace's time zone, today included) per day and per site, the same numbers for the period before, the pages chats start on, and the number of open knowledge gaps.

Parameters

Overview of the workspace: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

daysquery · optional7 | 30 | 90

The period in days, today included (default 30).

Responses

  • 200The overview. (Overview)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/overview \
  -H "Authorization: Bearer $ASDK_API_KEY"

What visitors ask

GET/v1/workspaces/{id}/insights· Read

Any member or an API key. The questions visitors ask most (grouped by normalized text), the pages answers cite and the answers visitors rated down, over the last days days. These lists need a plan with the catalog feature insights-report; without it entitled is false, the lists are empty and minPlan names the plan to upgrade to. Knowledge gaps are in every plan (/gaps).

Parameters

What visitors ask: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

daysquery · optional7 | 30 | 90

The period in days, today included (default 30).

Responses

  • 200The insights. (Insights)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/insights \
  -H "Authorization: Bearer $ASDK_API_KEY"

List open knowledge gaps

GET/v1/workspaces/{id}/gaps· Read

Any member or an API key. Questions the knowledge base could not answer, most asked first, a page at a time.

Parameters

List open knowledge gaps: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

siteIdquery · optionalstring (≤ 64 chars)

Only this site of the workspace (site_…); all sites when absent.

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–200)

Items per page (default 50).

Responses

  • 200A page of open gaps. (KnowledgeGapList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/gaps \
  -H "Authorization: Bearer $ASDK_API_KEY"

The Search agent of a site — its settings and what visitors search for.

What visitors search for

GET/v1/sites/{siteId}/search/analytics· Read

Any member, or a workspace API key. Searches visitors settled on in the last days days (UTC, today included): totals with the click-through rate (clicked searches among those with results), every day of the period, the top searches, and the searches that found nothing useful — no result or only weak ones, and no answer — that were not answered since.

Parameters

What visitors search for: Parameters
FieldTypeDescription
siteIdpath · requiredstring (≤ 64 chars)

Site id (site_…).

daysquery · optionalinteger (1–365)

Length of the period in days (default 30).

limitquery · optionalinteger (1–50)

Rows per query list (default 20).

Responses

  • 200The analytics. (SearchAnalytics)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/sites/{siteId}/search/analytics \
  -H "Authorization: Bearer $ASDK_API_KEY"

Webhooks

Workspace webhooks — signed events for leads, conversations, knowledge gaps and source syncs.

List webhook endpoints

GET/v1/workspaces/{id}/webhooks· Read

Owners, admins and API keys. The workspace's endpoints, the events they can subscribe to, and whether the plan includes webhooks (entitled; without them endpoints are kept but receive nothing).

Parameters

List webhook endpoints: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

Responses

  • 200The endpoints. (WebhookEndpointList)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/webhooks \
  -H "Authorization: Bearer $ASDK_API_KEY"

Add a webhook endpoint

POST/v1/workspaces/{id}/webhooks· Write scope

Owners, admins and API keys with the write scope (Zapier- and Make-style subscriptions). The answer carries the signing secret, shown this once. At most 10 endpoints per workspace (limit-reached); the plan must include webhooks (not-in-plan). The address must be public https.

Parameters

Add a webhook endpoint: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

Request body (WebhookEndpointInput)

Add a webhook endpoint: Request body
FieldTypeDescription
urlrequiredstring (≤ 2,048 chars)

A public https address.

descriptionoptionalstring (≤ 120 chars)
eventsrequiredarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"

Responses

  • 201The endpoint and its secret. (CreatedWebhookEndpoint)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 409Conflicts with the current state (types "already-member", "last-owner", "limit-reached", "refresh-conflict").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/workspaces/{id}/webhooks \
  -H "Authorization: Bearer $ASDK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url":"…","events":["lead.created"]}'

Change a webhook endpoint

PATCH/v1/workspaces/{id}/webhooks/{webhookId}· Write scope

Owners, admins and API keys with the write scope. Switching an endpoint on (enabled: true) also clears a stop after repeated failures.

Parameters

Change a webhook endpoint: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

webhookIdpath · requiredstring (≤ 64 chars)

Webhook endpoint id (whk_…).

Request body (WebhookEndpointPatch)

Change a webhook endpoint: Request body
FieldTypeDescription
urloptionalstring (≤ 2,048 chars)
descriptionoptionalstring (≤ 120 chars)
eventsoptionalarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"
enabledoptionalboolean

Responses

  • 200The endpoint after the change. (WebhookEndpoint)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X PATCH https://api.asdk.com/v1/workspaces/{id}/webhooks/{webhookId} \
  -H "Authorization: Bearer $ASDK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url":"…","description":"…","events":["lead.created"],"enabled":true}'

Remove a webhook endpoint

DELETE/v1/workspaces/{id}/webhooks/{webhookId}· Write scope

Owners, admins and API keys with the write scope. Its delivery log goes with it.

Parameters

Remove a webhook endpoint: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

webhookIdpath · requiredstring (≤ 64 chars)

Webhook endpoint id (whk_…).

Responses

  • 204Removed.
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X DELETE https://api.asdk.com/v1/workspaces/{id}/webhooks/{webhookId} \
  -H "Authorization: Bearer $ASDK_API_KEY"

Send a test event

POST/v1/workspaces/{id}/webhooks/{webhookId}/test· Write scope

Owners, admins and API keys with the write scope. Sends a signed test event now (one attempt, also to a switched-off endpoint) and answers with the logged delivery: the status the endpoint answered, the start of its answer and how long it took. The plan must include webhooks (not-in-plan).

Parameters

Send a test event: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

webhookIdpath · requiredstring (≤ 64 chars)

Webhook endpoint id (whk_…).

Responses

  • 200The delivery of the test event. (WebhookDelivery)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 429Too many requests (type "rate-limited"); retry after the Retry-After header.
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/workspaces/{id}/webhooks/{webhookId}/test \
  -H "Authorization: Bearer $ASDK_API_KEY"

An endpoint's delivery log

GET/v1/workspaces/{id}/webhooks/{webhookId}/deliveries· Read

Owners, admins and API keys. Newest first, a page at a time, kept 30 days, with each delivery's payload.

Parameters

An endpoint's delivery log: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

webhookIdpath · requiredstring (≤ 64 chars)

Webhook endpoint id (whk_…).

cursorquery · optionalstring (≤ 4,096 chars)

The nextCursor of the previous page.

limitquery · optionalinteger (1–100)

Deliveries per page (default 25).

Responses

  • 200A page of deliveries. (WebhookDeliveryList)
  • 400Invalid input (type "validation"; field names the input).
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • defaultAn error, as RFC 9457 problem details.
Shell
curl https://api.asdk.com/v1/workspaces/{id}/webhooks/{webhookId}/deliveries \
  -H "Authorization: Bearer $ASDK_API_KEY"

Send a delivery's event again

POST/v1/workspaces/{id}/webhooks/{webhookId}/deliveries/{deliveryId}/redeliver· Write scope

Owners, admins and API keys with the write scope. One attempt now, logged as a new delivery of the same event (same body, new signature). The plan must include webhooks (not-in-plan).

Parameters

Send a delivery's event again: Parameters
FieldTypeDescription
idpath · requiredstring (≤ 64 chars)

Workspace id (wsp_…).

webhookIdpath · requiredstring (≤ 64 chars)

Webhook endpoint id (whk_…).

deliveryIdpath · requiredstring (≤ 64 chars)

Delivery id (whd_…).

Responses

  • 200The new delivery. (WebhookDelivery)
  • 401Missing, expired or revoked credentials (types "unauthorized", "token-expired", "invalid-token").
  • 403Authenticated but not allowed (types "forbidden", "origin-not-allowed", "api-key-not-accepted", "email-mismatch"; P36 "insufficient-scope", "not-in-plan", "coming-soon").
  • 404Not found, or not visible to the caller (type "not-found").
  • 429Too many requests (type "rate-limited"); retry after the Retry-After header.
  • defaultAn error, as RFC 9457 problem details.
Shell
curl -X POST https://api.asdk.com/v1/workspaces/{id}/webhooks/{webhookId}/deliveries/{deliveryId}/redeliver \
  -H "Authorization: Bearer $ASDK_API_KEY"

Webhook events

ASDK POSTs these events as JSON to the endpoints a workspace adds (Settings → Webhooks, or the webhooks endpoints above). Each delivery is signed; see verifying webhooks for code in JavaScript, Python and Go. Any 2xx answer is a delivery; 408, 429 and 5xx are retried after 30 seconds, 2 and 10 minutes, 1 and 6 hours.

lead.created

A visitor left their contact details

Sent for every new lead (chat, forms, WebMCP). lead.preview marks leads from the dashboard's preview.

Payload: LeadWebhookEvent

Headers

lead.created: Headers
FieldTypeDescription
X-ASDK-Signatureheader · requiredstring

t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")>; during a secret rotation two v1 values.

X-ASDK-Eventheader · requiredstring

The event type (also type in the body).

X-ASDK-Deliveryheader · requiredstring

The delivery id, the same on every retry (use it to drop duplicates).

lead.updated

A lead's details, status or qualification changed

data.changes names the changed fields (email, name, company, phone, note, status, qualifiedAt) and data.previous their earlier values. Score-only changes are not sent.

Payload: LeadWebhookEvent

Headers

lead.updated: Headers
FieldTypeDescription
X-ASDK-Signatureheader · requiredstring

t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")>; during a secret rotation two v1 values.

X-ASDK-Eventheader · requiredstring

The event type (also type in the body).

X-ASDK-Deliveryheader · requiredstring

The delivery id, the same on every retry (use it to drop duplicates).

conversation.closed

A conversation went quiet

Sent when a conversation had no new message for 30 minutes, with its transcript (the latest 100 messages). A visitor who returns and goes quiet again closes it again.

Payload: ConversationClosedWebhookEvent

Headers

conversation.closed: Headers
FieldTypeDescription
X-ASDK-Signatureheader · requiredstring

t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")>; during a secret rotation two v1 values.

X-ASDK-Eventheader · requiredstring

The event type (also type in the body).

X-ASDK-Deliveryheader · requiredstring

The delivery id, the same on every retry (use it to drop duplicates).

knowledge_gap.created

Visitors asked something the knowledge base could not answer

Sent the first time a question goes unanswered (repeats count up the same gap).

Payload: KnowledgeGapWebhookEvent

Headers

knowledge_gap.created: Headers
FieldTypeDescription
X-ASDK-Signatureheader · requiredstring

t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")>; during a secret rotation two v1 values.

X-ASDK-Eventheader · requiredstring

The event type (also type in the body).

X-ASDK-Deliveryheader · requiredstring

The delivery id, the same on every retry (use it to drop duplicates).

source.synced

A knowledge source finished syncing

data.source.status is ready after a successful sync and error after a failed one (with error).

Payload: SourceSyncedWebhookEvent

Headers

source.synced: Headers
FieldTypeDescription
X-ASDK-Signatureheader · requiredstring

t=<unix seconds>,v1=<hex HMAC-SHA256(secret, "<t>.<raw body>")>; during a secret rotation two v1 values.

X-ASDK-Eventheader · requiredstring

The event type (also type in the body).

X-ASDK-Deliveryheader · requiredstring

The delivery id, the same on every retry (use it to drop duplicates).

Objects

AskAnswer

AskAnswer
FieldTypeDescription
answerrequiredstring

The answer as Markdown, in the question's language.

sourcesrequiredarray of AskSource

The pages the answer cites.

groundedrequiredboolean

False when the knowledge base did not cover the question.

languageoptionalstring

Base code of the answer's language (en).

AskRequest

AskRequest
FieldTypeDescription
questionrequiredstring (≤ 2,000 chars)

The question, as a visitor would ask it.

localeoptionalstring (≤ 35 chars)

BCP 47 language for short questions whose language cannot be told (e.g. de).

AskSource

AskSource
FieldTypeDescription
titlerequiredstring
urlrequiredstring

CitedPage

CitedPage
FieldTypeDescription
urlrequiredstring
titlerequiredstring
answersrequiredinteger

ConversationClosedWebhookEvent

ConversationClosedWebhookEvent
FieldTypeDescription
idrequiredstring
typerequired"conversation.closed"
createdAtrequiredstring (date-time)
workspaceIdrequiredstring
datarequiredobject
data.siterequiredWebhookSite
data.conversationrequiredobject
data.conversation.idrequiredstring
data.conversation.siteIdrequiredstring
data.conversation.visitorIdrequiredstring
data.conversation.agentrequiredstring
data.conversation.pageUrlrequiredstring | null
data.conversation.leadIdrequiredstring | null
data.conversation.startedAtrequiredstring (date-time)
data.conversation.lastMessageAtrequiredstring (date-time)
data.conversation.messageCountrequiredinteger
data.conversation.previewrequiredboolean
data.conversation.messagesrequiredarray of WebhookMessage
data.conversation.messagesTruncatedrequiredboolean

Only the latest 100 messages are sent.

data.conversation.dashboardUrloptionalstring

ConversationDetail

ConversationDetail
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
siteNamerequiredstring
siteOriginrequiredstring
agentrequired"chat" | "sales" | "search" | "forms" | "voice"
pageUrloptionalstring
startedAtrequiredstring (date-time)
lastMessageAtrequiredstring (date-time)
previewrequiredboolean
unansweredrequiredboolean
reviewedAtoptionalstring (date-time)
reviewedByoptionalPersonRef
visitorrequiredInboxVisitor
messagesrequiredarray of InboxMessage

Oldest first, at most 1,000.

leadsrequiredarray of Lead

ConversationList

ConversationList
FieldTypeDescription
conversationsrequiredarray of ConversationSummary
nextCursoroptionalstring

ConversationSummary

ConversationSummary
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
siteNamerequiredstring
siteOriginrequiredstring
agentrequired"chat" | "sales" | "search" | "forms" | "voice"
pageUrloptionalstring

The page the conversation started on.

startedAtrequiredstring (date-time)
lastMessageAtrequiredstring (date-time)
reviewedAtoptionalstring (date-time)
previewrequiredboolean

Started in the dashboard's preview, not by a visitor.

leadoptionalLeadRef
messagesrequiredinteger
questionsrequiredinteger
unansweredrequiredboolean

An answer was not grounded in the site's content.

thumbsUprequiredinteger
thumbsDownrequiredinteger
firstQuestionrequiredstring

The visitor's first message, shortened to 200 characters.

lastMessagerequiredstring

The last message, shortened to 200 characters.

lastMessageRolerequired"visitor" | "agent"

CreatedWebhookEndpoint

CreatedWebhookEndpoint
FieldTypeDescription
endpointrequiredWebhookEndpoint
secretrequiredstring

The signing secret (whsec_…). Shown once; store it now.

Document

Document
FieldTypeDescription
idrequiredstring
sourceIdrequiredstring
siteIdrequiredstring
urlrequiredstring

The page address, or the file name of an upload.

titlerequiredstring
statusrequired"pending" | "indexed" | "skipped" | "excluded" | "error"
chunkCountrequiredinteger
languageoptionalstring

ISO 639-1 code, when detected.

erroroptionalstring

Why the page is skipped or failed, in words for people.

indexedAtoptionalstring (date-time)
updatedAtrequiredstring (date-time)

DocumentList

DocumentList
FieldTypeDescription
documentsrequiredarray of Document
totalrequiredinteger

Documents matching the filters.

nextCursoroptionalstring

Present when there are more.

DownvotedAnswer

DownvotedAnswer
FieldTypeDescription
messageIdrequiredstring
conversationIdrequiredstring
siteIdrequiredstring
siteNamerequiredstring
questionrequiredstring
answerrequiredstring
commentoptionalstring
ratedAtrequiredstring (date-time)

InboxMessage

InboxMessage
FieldTypeDescription
idrequiredstring
rolerequired"visitor" | "agent"
textrequiredstring
createdAtrequiredstring (date-time)
sourcesrequiredarray of InboxSource
groundedoptionalboolean

Agent answers that went through retrieval; absent for greetings.

refusalrequiredboolean

The agent said it does not know.

ratingoptional"up" | "down"
ratingCommentoptionalstring

InboxSource

InboxSource
FieldTypeDescription
titlerequiredstring
urlrequiredstring

InboxVisitor

InboxVisitor
FieldTypeDescription
idrequiredstring
emailoptionalstring

From the site's identify call, when it made one.

nameoptionalstring
firstSeenAtoptionalstring (date-time)
otherConversationsrequiredinteger

Insights

Insights
FieldTypeDescription
timezonerequiredstring
fromrequiredstring (date-time)
torequiredstring (date-time)
daysrequiredinteger
openGapsrequiredinteger
entitledrequiredboolean

The plan includes "What visitors ask" insights (catalog feature insights-report).

minPlanrequiredPlanRef
topQuestionsrequiredarray of TopQuestion
citedPagesrequiredarray of CitedPage
downvotedrequiredarray of DownvotedAnswer

KnowledgeGap

KnowledgeGap
FieldTypeDescription
idrequiredstring

The hex SHA-256 of the normalized question.

siteIdrequiredstring
siteNamerequiredstring
questionrequiredstring
countrequiredinteger

How often visitors asked it.

firstSeenAtrequiredstring (date-time)
lastSeenAtrequiredstring (date-time)

KnowledgeGapList

KnowledgeGapList
FieldTypeDescription
gapsrequiredarray of KnowledgeGap
totalrequiredinteger
nextCursoroptionalstring

KnowledgeGapWebhookEvent

KnowledgeGapWebhookEvent
FieldTypeDescription
idrequiredstring
typerequired"knowledge_gap.created"
createdAtrequiredstring (date-time)
workspaceIdrequiredstring
datarequiredobject
data.siterequiredWebhookSite
data.gaprequiredobject
data.gap.idrequiredstring

The gap's id for POST /v1/sites/{siteId}/gaps/{gapId}/answer.

data.gap.siteIdrequiredstring
data.gap.questionrequiredstring
data.gap.countrequiredinteger
data.gap.firstSeenAtrequiredstring (date-time)
data.gap.lastSeenAtrequiredstring (date-time)
data.gap.dashboardUrloptionalstring

KnowledgeSummary

KnowledgeSummary
FieldTypeDescription
statusrequired"empty" | "pending" | "syncing" | "ready" | "error"
sourcesrequiredinteger

Sources other than the Q&A source.

documentsrequiredinteger

Indexed documents (pages, files, snippets).

chunksrequiredinteger
qaPairsrequiredinteger
lastSyncedAtoptionalstring (date-time)

Lead

Lead
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
siteNamerequiredstring
siteOriginrequiredstring
conversationIdoptionalstring
emailrequiredstring
nameoptionalstring
companyoptionalstring
phoneoptionalstring
noteoptionalstring
consentrequiredboolean
pageUrloptionalstring
statusrequired"new" | "contacted" | "archived"
previewrequiredboolean
createdAtrequiredstring (date-time)
statusChangedAtoptionalstring (date-time)

LeadCounts

LeadCounts
FieldTypeDescription
newrequiredinteger
contactedrequiredinteger
archivedrequiredinteger

LeadDetail

LeadDetail
FieldTypeDescription
leadrequiredLead
statusChangedByoptionalPersonRef
conversationoptionalConversationDetail

LeadList

LeadList
FieldTypeDescription
leadsrequiredarray of Lead
countsrequiredLeadCounts
nextCursoroptionalstring

LeadRef

LeadRef
FieldTypeDescription
idrequiredstring
emailrequiredstring
nameoptionalstring
statusrequired"new" | "contacted" | "archived"

LeadUpdate

LeadUpdate
FieldTypeDescription
statusrequired"new" | "contacted" | "archived"

LeadWebhookEvent

LeadWebhookEvent
FieldTypeDescription
idrequiredstring
typerequired"lead.created" | "lead.updated"
createdAtrequiredstring (date-time)
workspaceIdrequiredstring
datarequiredobject
data.siterequiredWebhookSite
data.leadrequiredWebhookLead
data.changesoptionalarray of string

lead.updated only.

data.previousoptionalobject (any keys)

lead.updated only; the changed fields' earlier values.

LimitUsage

LimitUsage
FieldTypeDescription
usedrequiredinteger
limitrequiredinteger

Overview

Overview
FieldTypeDescription
timezonerequiredstring
fromrequiredstring (date-time)
torequiredstring (date-time)

End of today in the time zone (exclusive).

daysrequiredinteger
totalsrequiredStatsTotals
previousrequiredStatsTotals
seriesrequiredarray of OverviewDay

One entry per day of the period, oldest first.

sitesrequiredarray of OverviewSite
topPagesrequiredarray of PageCount

Pages visitors' conversations started on, most first (query strings dropped).

openGapsrequiredinteger
hasConversationsrequiredboolean

Visitors ever talked to an agent of the workspace (or the site).

installedrequiredboolean

A site has a verified installation.

OverviewDay

OverviewDay
FieldTypeDescription
daterequiredstring (date)

The day in the workspace's time zone.

totalsrequiredStatsTotals

OverviewSite

OverviewSite
FieldTypeDescription
siteIdrequiredstring
namerequiredstring
originrequiredstring
installedAtoptionalstring (date-time)
totalsrequiredStatsTotals

PageCount

PageCount
FieldTypeDescription
urlrequiredstring
conversationsrequiredinteger

PersonRef

PersonRef
FieldTypeDescription
namerequiredstring
emailrequiredstring

PlanRef

PlanRef
FieldTypeDescription
idrequiredstring
namerequiredstring

PlanUsage

PlanUsage
FieldTypeDescription
planIdrequiredstring
trialoptionalboolean

The limits are a running trial's (P20).

sitesrequiredLimitUsage
pagesrequiredLimitUsage

Problem

Problem
FieldTypeDescription
typerequiredstring

URI reference identifying the problem type; "about:blank" for plain HTTP errors.

titlerequiredstring

Short, human-readable summary of the problem type.

statusrequiredinteger

HTTP status code.

detailoptionalstring

Human-readable explanation of this occurrence.

instanceoptionalstring

Request path the problem occurred on.

request_idoptionalstring

Request id, also returned in the X-Request-ID header.

trace_idoptionalstring

W3C trace id of the request, also returned in the X-Trace-Id header (the id to look the request up by in the tracing backend).

fieldoptionalstring

For type "validation", the request field that is invalid.

QaPair

QaPair
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
questionrequiredstring
answerrequiredstring
statusrequired"pending" | "indexed" | "error"
erroroptionalstring
createdByoptionalPersonRef
createdAtrequiredstring (date-time)
updatedAtrequiredstring (date-time)

QaPairInput

QaPairInput
FieldTypeDescription
questionrequiredstring (≤ 1,000 chars)
answerrequiredstring (≤ 8,000 chars)

QaPairList

QaPairList
FieldTypeDescription
qaPairsrequiredarray of QaPair
totalrequiredinteger
nextCursoroptionalstring

SearchAnalytics

SearchAnalytics
FieldTypeDescription
siteIdrequiredstring
fromrequiredstring (date)
torequiredstring (date)
daysrequiredinteger
totalsrequiredSearchTotals
dailyrequiredarray of SearchDay
topSearchesrequiredarray of SearchQueryStat
missedSearchesrequiredarray of SearchQueryStat

Searches without a useful result (no result or only weak ones, no answer) that are not resolved.

SearchDay

any

SearchQueryStat

SearchQueryStat
FieldTypeDescription
idrequiredstring
queryrequiredstring

The query as a visitor last typed it.

searchesrequiredinteger
zeroResultsrequiredinteger
lowScorerequiredinteger
answersrequiredinteger
clicksrequiredinteger
clickThroughRaterequirednumber
lastSeenAtrequiredstring (date-time)
lastMissAtoptionalstring (date-time)

The last search of it that found nothing useful.

SearchTotals

SearchTotals
FieldTypeDescription
searchesrequiredinteger

Searches visitors settled on.

zeroResultsrequiredinteger

Of them without any result and without an answer.

lowScorerequiredinteger

Of them with only weak results and without an answer.

answersrequiredinteger

Of them with an answer shown.

clicksrequiredinteger

Of them with a result clicked.

clickThroughRaterequirednumber

clicks / (searches − zeroResults), 0–1; 0 without searches with results.

Site

Site
FieldTypeDescription
idrequiredstring
workspaceIdrequiredstring
namerequiredstring
originrequiredstring

Normalized scheme://host[:port].

allowedOriginsrequiredarray of string

Origins whose pages may load the widget (https://*.example.com covers subdomains).

statusrequired"active" | "paused"
installVerifiedAtoptionalstring (date-time)
createdAtrequiredstring (date-time)
updatedAtrequiredstring (date-time)
knowledgerequiredKnowledgeSummary

SiteList

SiteList
FieldTypeDescription
sitesrequiredarray of Site
usagerequiredPlanUsage

Source

Source
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
kindrequired"crawl" | "sitemap" | "file" | "qa" | "text"
titlerequiredstring

What to call the source in a list (an address, a file name, a snippet title).

statusrequired"pending" | "syncing" | "ready" | "error"
configrequiredSourceConfig
statsrequiredSourceStats
erroroptionalstring

Why the last sync failed or stopped early, in words for people.

lastSyncedAtoptionalstring (date-time)
nextSyncAtoptionalstring (date-time)
createdAtrequiredstring (date-time)
updatedAtrequiredstring (date-time)

SourceConfig

The fields of the source's kind.

SourceConfig
FieldTypeDescription
urloptionalstring

crawl — where reading starts; pages under its path are read.

includeoptionalarray of string

crawl — only pages matching one of these path patterns.

excludeoptionalarray of string

crawl and sitemap — pages matching these path patterns are skipped.

maxPagesoptionalinteger

crawl and sitemap — at most this many pages (never more than the plan allows).

sitemapUrloptionalstring

sitemap — the sitemap or sitemap index.

fileNameoptionalstring

file — the uploaded file's name.

fileSizeoptionalinteger

file — size in bytes.

contentTypeoptionalstring

file — media type.

titleoptionalstring

text — the snippet's title.

bodyoptionalstring

text — the snippet (only when one source is read).

SourceList

SourceList
FieldTypeDescription
sourcesrequiredarray of Source

SourceStats

Counters of the last or running sync.

SourceStats
FieldTypeDescription
foundrequiredinteger

Pages read so far.

indexedrequiredinteger

Pages in the knowledge base after the sync (unchanged ones included).

unchangedrequiredinteger

Pages whose content did not change (not embedded again).

skippedrequiredinteger

Pages left out (duplicates, too little text, the plan's page limit).

failedrequiredinteger

Pages that could not be read.

removedrequiredinteger

Pages that disappeared from the site since the last sync.

chunksrequiredinteger
limitReachedoptionalboolean

The plan's page limit stopped the sync.

startedAtoptionalstring (date-time)
finishedAtoptionalstring (date-time)

SourceSyncedWebhookEvent

SourceSyncedWebhookEvent
FieldTypeDescription
idrequiredstring
typerequired"source.synced"
createdAtrequiredstring (date-time)
workspaceIdrequiredstring
datarequiredobject
data.siterequiredWebhookSite
data.sourcerequiredobject
data.source.idrequiredstring
data.source.siteIdrequiredstring
data.source.kindrequired"crawl" | "sitemap" | "file" | "qa" | "text"
data.source.titlerequiredstring
data.source.statusrequired"ready" | "error"
data.source.errorrequiredstring | null
data.source.statsrequiredobject (any keys)

Pages found, indexed, unchanged, skipped, failed and removed, and chunks.

data.source.lastSyncedAtrequiredstring (date-time) | null
data.source.nextSyncAtrequiredstring (date-time) | null
data.source.dashboardUrloptionalstring

StatsTotals

StatsTotals
FieldTypeDescription
conversationsrequiredinteger

Visitors' conversations with at least one question, started in the period.

answersrequiredinteger

Agent answers in visitors' conversations.

measuredAnswersrequiredinteger

Answers that went through retrieval (greetings do not).

groundedAnswersrequiredinteger

Measured answers backed by the site's content.

groundedRateoptionalnumber (0–1)

groundedAnswers / measuredAnswers; absent without measured answers.

leadsrequiredinteger
thumbsUprequiredinteger
thumbsDownrequiredinteger

TopQuestion

TopQuestion
FieldTypeDescription
textrequiredstring

The wording visitors used most.

countrequiredinteger
answeredrequiredinteger

Times the answer was grounded in the site's content.

unansweredrequiredinteger
lastAskedAtrequiredstring (date-time)
conversationIdrequiredstring

The newest conversation it was asked in.

siteIdrequiredstring

WebhookDelivery

WebhookDelivery
FieldTypeDescription
idrequiredstring
eventIdrequiredstring
eventTyperequiredstring

The event type, or test.

testrequiredboolean
statusrequired"pending" | "retrying" | "delivered" | "failed"
attemptsrequiredinteger
nextAttemptAtoptionalstring (date-time)
responseStatusoptionalinteger

The HTTP status of the last attempt (absent when there was no answer).

responseBodyoptionalstring

The start of the endpoint's answer (1,000 characters).

erroroptionalstring
durationMsoptionalinteger
createdAtrequiredstring (date-time)
lastAttemptAtoptionalstring (date-time)
deliveredAtoptionalstring (date-time)
payloadrequiredobject (any keys)

The JSON body sent (a webhook event).

WebhookDeliveryList

WebhookDeliveryList
FieldTypeDescription
deliveriesrequiredarray of WebhookDelivery
nextCursoroptionalstring

WebhookEndpoint

WebhookEndpoint
FieldTypeDescription
idrequiredstring
urlrequiredstring
descriptionrequiredstring
eventsrequiredarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"
enabledrequiredboolean
disabledReasonoptional"manual" | "failing"

Why the endpoint is off; failing after 15 deliveries in a row failed for good.

secretHintrequiredstring

The last characters of the signing secret.

previousSecretExpiresAtoptionalstring (date-time)

After a rotation, until when the previous secret also signs.

createdAtrequiredstring (date-time)
updatedAtrequiredstring (date-time)

WebhookEndpointInput

WebhookEndpointInput
FieldTypeDescription
urlrequiredstring (≤ 2,048 chars)

A public https address.

descriptionoptionalstring (≤ 120 chars)
eventsrequiredarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"

WebhookEndpointList

WebhookEndpointList
FieldTypeDescription
endpointsrequiredarray of WebhookEndpoint
eventsrequiredarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"

Every event an endpoint can subscribe to.

entitledrequiredboolean

Whether the plan includes webhooks.

minPlanoptionalstring

The cheapest plan with webhooks (when not entitled).

maxEndpointsrequiredinteger

WebhookEndpointPatch

WebhookEndpointPatch
FieldTypeDescription
urloptionalstring (≤ 2,048 chars)
descriptionoptionalstring (≤ 120 chars)
eventsoptionalarray of "lead.created" | "lead.updated" | "conversation.closed" | "knowledge_gap.created" | "source.synced"
enabledoptionalboolean

WebhookLead

WebhookLead
FieldTypeDescription
idrequiredstring
siteIdrequiredstring
conversationIdrequiredstring | null
emailrequiredstring
namerequiredstring | null
companyrequiredstring | null
phonerequiredstring | null
noterequiredstring | null
consentrequiredboolean
pageUrlrequiredstring | null
statusrequired"new" | "contacted" | "archived"
scorerequiredinteger | null

The Sales agent's score, 0–100.

qualifiedAtrequiredstring (date-time) | null
createdAtrequiredstring (date-time)
previewrequiredboolean

Left in the dashboard's preview, not by a visitor.

dashboardUrloptionalstring

WebhookMessage

WebhookMessage
FieldTypeDescription
idrequiredstring
rolerequired"visitor" | "agent"
textrequiredstring
sourcesrequiredarray of AskSource
createdAtrequiredstring (date-time)

WebhookSite

WebhookSite
FieldTypeDescription
idrequiredstring
namerequiredstring
originrequiredstring

Workspace

Workspace
FieldTypeDescription
idrequiredstring
namerequiredstring
planIdrequiredstring

Catalog plan id (packages/catalog).

trialEndsAtoptionalstring (date-time)
createdAtrequiredstring (date-time)
roleoptional"owner" | "admin" | "member" | "client"

WorkspaceSuspension

WorkspaceSuspension
FieldTypeDescription
suspendedrequiredboolean
suspendedAtoptionalstring (date-time)
contactrequiredstring

Where to write about it.