Skip to main content

OpenAPI document

Everything your own software can call with a personal API key is described in one OpenAPI 3.1 document. It is produced from the same definitions the API validates requests with, so a field it lists is a field the server accepts, and a field it rejects is one the server rejects too.

  • Download: /openapi/public-v1.json - import it into Postman, Insomnia, Stoplight or any client generator.
  • From the API itself: GET https://api.yekar.ai/api/public/v1/openapi.json - the same document, with no key needed, so a self-hosted deployment serves its own.

Request bodies are strict: a field the document does not list is refused with 400 VALIDATION rather than ignored. Responses may gain fields over time, so a client should tolerate ones it does not know. Each route names the key scope that opens it; a key without that scope receives the same 404 as an unknown key.

The reference below is rendered from that document. The API reference page carries the longer explanations, event lists and examples.

Yekar.AI public API · version 1.0.0 · base URL https://api.yekar.ai/api/public/v1 · download the OpenAPI document

Specification

Read this API's OpenAPI document #

GET /openapi.json

The machine-readable description of every public route, generated from the same definitions the server validates requests with. Needs no key.

Responses

StatusMeaning
200The OpenAPI 3.1 document.

Triggers

Fire a trigger #

POST /triggers/fire · key scope triggers:fire

Fire an active API trigger. One request fans out to every subscribed agent and flow, starting one session for each successful start. `202` means the request was accepted, not that the work finished - register a webhook or read the sessions to follow it.

Send `Idempotency-Key` (or `idempotencyKey` in the body) to retry safely: a replay returns the original result with `Idempotency-Replayed: true` and never starts another run.

A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `triggers:fire` (Fire triggers).

Request body

FieldTypeRequiredNotes
idempotencyKeystring (pattern)No
triggerIdstring (uuid, pattern)Yes
inputobjectNo
callerCredentialsobjectNo
FieldTypeRequiredNotes
integrationsobjectYes
callerCredentialExpiresAtstring (date-time, pattern)No

Responses

StatusMeaning
202Accepted. One entry per agent or flow that started, and the subscribers that were skipped with the reason.
FieldTypeRequiredNotes
sessionsobject[]Yes
FieldTypeRequiredNotes
automationIdstringYes
sessionIdstringYes
skippedobject[]Yes
FieldTypeRequiredNotes
automationIdstringYes
automationNamestringYes
reason"unpublished" | "inactive" | "integration_not_unattended" | "person_unavailable" | "worker_paused" | "cost_cap_reached" | "event_input_unpublished" | "procedure_off" | "entitlement_disabled" | "missing"Yes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Agents

Start a conversation with an agent #

POST /agents/{automationId}/sessions · key scope agents:run

Open a session on a published agent and queue its first turn. The agent must be published and the key's owner must be allowed to run it. Include `callerCredentials` when the agent should act on your end user's own account for a bound integration.

`202` means the first turn was accepted. Follow it on the session's event stream.

A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
automationIdpathstringYesThe agent's id, from its page URL in the product.

Request body

FieldTypeRequiredNotes
messagestringYes
callerCredentialsobjectNo
FieldTypeRequiredNotes
integrationsobjectYes

Responses

StatusMeaning
202Accepted. The new session and its first execution.
FieldTypeRequiredNotes
sessionIdstringYes
executionIdstringYes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List conversations #

GET /agents/sessions · key scope agents:run

The agent conversations the key's owner can see, newest activity first. Narrow to one agent with `agentId`; `q` searches titles and agent names, never message content.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
qquerystringNo
limitqueryintegerNo
offsetqueryintegerNo
agentIdquerystring (uuid, pattern)No

Responses

StatusMeaning
200One page of conversations and the total.
FieldTypeRequiredNotes
conversationsobject[]Yes
FieldTypeRequiredNotes
idstringYes
titlestringYes
statusstringYes
agentIdstring | nullYes
agentNamestringYes
createdAtstringYes
lastMessageAtstring | nullYes
totalnumberYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Read a conversation #

GET /agents/sessions/{sessionId} · key scope agents:run

The session's transcript and state as the key's owner may see it: status, the latest 100 messages with `messagesTotal`, pending approval, and `canParticipate` / `canManage` / `readOnlyReason` for this caller.

A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
sessionIdpathstringYesThe session id returned when the conversation started.

Responses

StatusMeaning
200The session detail. The full shape is documented on the API reference page (Personal-key Agent conversations).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Send a message #

POST /agents/sessions/{sessionId}/messages · key scope agents:run

Append a message to a conversation the key's owner may take part in and queue the next turn. Caller credentials sent here belong to this turn only.

A visible conversation the owner cannot drive returns `403 SESSION_NOT_DRIVABLE`. A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
sessionIdpathstringYesThe session id.

Request body

FieldTypeRequiredNotes
messagestringYes
callerCredentialsobjectNo
FieldTypeRequiredNotes
integrationsobjectYes

Responses

StatusMeaning
200The execution queued for this turn.
FieldTypeRequiredNotes
executionIdstringNo
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Approve or reject a paused action #

POST /agents/sessions/{sessionId}/turn-approval · key scope agents:run

Resolve an approval the event stream reported (`turn.suspended`). The key's owner must be allowed to decide it: the credential owner for a call on someone's own account, otherwise an approver under the domain's approval policy; a confirmation the agent asked for is answered only by the person who started the turn.

`editedArgs` amends the pending call before approving it; `rememberForSession` approves the tool for the rest of the conversation (confirmations only). An approved decision queues the turn to resume; it does not wait for the call to finish.

A visible conversation the owner cannot decide returns `403 FORBIDDEN`. A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
sessionIdpathstringYesThe session id.

Request body

FieldTypeRequiredNotes
approvalIdstring (uuid, pattern)No
decision"approved" | "rejected"Yes
commentstringNo
callerCredentialsobjectNo
FieldTypeRequiredNotes
integrationsobjectYes
rememberForSessionbooleanNo
editedArgsobjectNo

Responses

StatusMeaning
200`{ ok: true, approvalId, decision }`.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Follow a conversation live #

GET /agents/sessions/{sessionId}/stream · key scope agents:run

Server-Sent Events for one conversation: a `snapshot` first, then `turn.started`, `message.delta`, `tool_call.started`, `tool_call.finished`, `turn.suspended` (carrying the approval to decide), `turn.completed`, `session.changed` and the rest, with a heartbeat comment every 25 seconds. Reading the stream needs visibility, not participation.

A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `agents:run` (Run agents).

Parameters

NameInTypeRequiredNotes
sessionIdpathstringYesThe session id.

Responses

StatusMeaning
200An event stream. Each `data:` frame is a JSON envelope with `sessionId`, `seq`, `ts` and `event`.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

MCP

MCP server (Streamable HTTP) #

POST /mcp · key scope mcp

Your published agents as tools for any assistant that speaks the Model Context Protocol. One endpoint carries every JSON-RPC method in its body (`initialize`, `tools/list`, `tools/call`, …). A notification gets `202` with no body.

A missing or invalid key, a key without the required scope, an unknown id or an id in another organization all return the same `404 NOT_FOUND`.

**Key scope:** `mcp` (MCP server).

Request body

A JSON-RPC 2.0 request or notification.

object

Responses

StatusMeaning
200The JSON-RPC response object.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Agent authoring

List domains #

GET /authoring/domains · key scope authoring

The domains the caller belongs to - every domain for an organization admin. A domain owns agents, knowledge and connections; creating an agent needs one.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
qquerystringNo
limitqueryintegerNo
offsetqueryintegerNo

Responses

StatusMeaning
200One page of domains and the total.
FieldTypeRequiredNotes
domainsobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
descriptionstring | nullYes
totalnumberYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List agents #

GET /authoring/automations · key scope authoring

The agents in the caller's domains, published or not. `status: active` keeps only agents that can run; `domainId` narrows to one domain.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
qquerystringNo
limitqueryintegerNo
offsetqueryintegerNo
domainIdquerystring (uuid, pattern)No
statusquery"draft" | "active" | "archived"No

Responses

StatusMeaning
200One page of agents and the total.
FieldTypeRequiredNotes
agentsobject[]Yes
FieldTypeRequiredNotes
idstringYes
domainIdstringYes
domainNamestringYes
namestringYes
descriptionstring | nullYes
publishedbooleanYes
publishedRevisionnumber | nullYes
archivedbooleanYes
totalnumberYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Create an agent #

POST /authoring/automations · key scope authoring

Create a draft agent in a domain the caller may edit agents in, optionally with its first Setup. The agent is not published until you publish it.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Request body

FieldTypeRequiredNotes
domainIdstring (uuid, pattern)Yes
namestringYes
descriptionstringNo
initialSetupobjectNo
FieldTypeRequiredNotes
principlesstringNo
procedurestringNo
modelstringNo
confirmToolsstring[]No

Responses

StatusMeaning
201Created. The new agent.
FieldTypeRequiredNotes
idstringYes
domainIdstringYes
namestringYes
descriptionstring | nullYes
kind"agent"Yes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Edit an agent's draft Setup #

PATCH /authoring/automations/{id}/setup · key scope authoring

Change the draft's principles, procedure, model or the tools that ask for confirmation. Edits land on the draft only; publish to make them run.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

FieldTypeRequiredNotes
principlesstringNo
procedurestringNo
modelstringNo
confirmToolsstring[]No

Responses

StatusMeaning
200`{ setup }` - the draft after the edit.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Check a draft before publishing #

GET /authoring/automations/{id}/verify · key scope authoring

The findings publishing would raise for the current draft - unknown tool references, missing integrations and the like.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Responses

StatusMeaning
200The verification findings for the draft.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Publish an agent's draft #

POST /authoring/automations/{id}/publish · key scope authoring

Make the draft the version that runs. Refused with `422` while the draft has blocking findings; the response names the new revision and the tools it will run with. `procedureMode` chooses how the Procedure runs - `free_text` or `structured` - and omitting it keeps the mode the draft already has.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

FieldTypeRequiredNotes
changeNotestringNo
procedureMode"free_text" | "structured"No

Responses

StatusMeaning
200`{ revision, belt }` - the published revision number and the integrations it is bound to.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Choose what knowledge an agent reads #

PUT /authoring/automations/{id}/knowledge-selection · key scope authoring

Nothing, the whole organization library, the agent's domain, or named knowledge modules. Applies on the agent's next turn.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

FieldTypeRequiredNotes
mode"none" | "org" | "domain" | "modules"Yes
moduleIdsstring (uuid, pattern)[]No

Responses

StatusMeaning
200The selection as saved.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List an agent's triggers #

GET /authoring/automations/{id}/triggers · key scope authoring

The schedules, API triggers and event triggers subscribed to this agent.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Responses

StatusMeaning
200The agent's triggers.
FieldTypeRequiredNotes
triggersobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
type"schedule" | "api" | "event"Yes
status"active" | "disabled"Yes
cronstring | nullYes
timezonestring | nullYes
inputobject | nullYes
eventanyNo
eventFilterobject | nullYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Add a trigger to an agent #

POST /authoring/automations/{id}/triggers · key scope authoring

Create a schedule, API or event trigger subscribed to this agent. New triggers start switched off; switch one on from the product once the agent is published.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

any

Responses

StatusMeaning
201Created. The new trigger.
FieldTypeRequiredNotes
triggerobjectYes
FieldTypeRequiredNotes
idstringYes
namestringYes
type"schedule" | "api" | "event"Yes
status"active" | "disabled"Yes
cronstring | nullYes
timezonestring | nullYes
inputobject | nullYes
eventanyNo
eventFilterobject | nullYes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Edit one of an agent's triggers #

PATCH /authoring/automations/{id}/triggers/{triggerId} · key scope authoring

Change a trigger's name and the fields of its kind (schedule: cron, timezone, input; event: connection, event type, filter). The body must match the trigger's kind; a field of another kind is a `400`.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.
triggerIdpathstringYesThe trigger's id.

Request body

Option 1

FieldTypeRequiredNotes
namestringNo
cronstringNo
timezonestringNo
inputobjectNo

Option 2

FieldTypeRequiredNotes
namestringNo

Option 3

FieldTypeRequiredNotes
namestringNo
connectionIdstring (uuid, pattern)No
eventTypestringNo
eventFilterobject | nullNo

Responses

StatusMeaning
200The trigger after the edit.
FieldTypeRequiredNotes
triggerobjectYes
FieldTypeRequiredNotes
idstringYes
namestringYes
type"schedule" | "api" | "event"Yes
status"active" | "disabled"Yes
cronstring | nullYes
timezonestring | nullYes
inputobject | nullYes
eventanyNo
eventFilterobject | nullYes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Remove one of an agent's triggers #

DELETE /authoring/automations/{id}/triggers/{triggerId} · key scope authoring

Delete a trigger subscribed to this agent.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.
triggerIdpathstringYesThe trigger's id.

Responses

StatusMeaning
204Deleted; no body.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Add a simulated test to an agent #

POST /authoring/automations/{id}/eval-cases · key scope authoring

A conversation the agent will be tested on, with the tool results it will receive and the checks that decide it. Nothing it tests ever runs for real: every tool call is answered from the script, and a call the script does not cover is refused unexecuted.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

FieldTypeRequiredNotes
namestringYes
notestringNo
turnsstring[]YesWhat the person says, turn by turn.
scriptobject[]NoWhat each tool answers, consumed in order per tool.
FieldTypeRequiredNotes
toolstringYesThe tool's name as the agent calls it.
responseanyYesWhat the tool answers with.
failedbooleanNoAnswer as a failure - an expired sign-in, a rate limit.
holdoutbooleanNoKeep the case's contents out of what this API returns, so a fix cannot be fitted to it.
assertionsobject[]Yes
FieldTypeRequiredNotes
kind"reply_contains" | "reply_omits" | "tool_called" | "tool_not_called" | "tool_precedes" | "no_divergence" | "token_ceiling" | "round_budget" | "tool_called_with" | "tool_call_count"Yes
valuestringNoKind-specific: a literal, a tool name, `a|b` for tool_precedes, `tool|/json/pointer|expected` for tool_called_with, `tool|n` for tool_call_count, or a number.
labelstringYesThe success criterion in the person's words; what the pass/fail line says.

Responses

StatusMeaning
201The new case's id.
FieldTypeRequiredNotes
idstringYes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List an agent's tests #

GET /authoring/automations/{id}/eval-cases · key scope authoring

Every case the agent is tested on, with its turns, script and checks. A held-out case is listed by name only.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Responses

StatusMeaning
200The agent's cases.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Remove a test the Builder wrote #

DELETE /authoring/automations/{id}/eval-cases/{caseId} · key scope authoring

Delete a case this API created. A case a person wrote cannot be removed here.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.
caseIdpathstringYesThe case's id.

Responses

StatusMeaning
200Deleted.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Test an agent's draft #

POST /authoring/automations/{id}/eval-suites · key scope authoring

Run every case against the agent's saved draft. Each case runs `repeat` times (1-5); a case passes only when every run passes. Runs spend model tokens like any turn.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.

Request body

FieldTypeRequiredNotes
repeatintegerNo

Responses

StatusMeaning
202The suite's id and how many runs it started.
FieldTypeRequiredNotes
suiteRunIdstringYes
runsintegerYes
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Read a test run's results #

GET /authoring/automations/{id}/eval-suites/{suiteId} · key scope authoring

Each case's standing - pass, fail, error, unscored or still running - with the failed checks and the failing conversation. A held-out case reports its standing only. Waits up to `waitSeconds` (at most 45) for the suite to finish.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe agent's id.
suiteIdpathstringYesThe suite's id, from startAgentEvalSuite.
waitSecondsqueryintegerNo

Responses

StatusMeaning
200The suite's results by case.
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Integrations

Search integrations #

GET /authoring/integrations · key scope authoring

The integrations available to the caller's organization, with their tools. `q` matches ids, names and descriptions of integrations and tools; at most 50 are returned.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
qquerystringNo

Responses

StatusMeaning
200The matching integrations.
FieldTypeRequiredNotes
integrationsobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
descriptionstringYes
toolsobject[]Yes
FieldTypeRequiredNotes
namestringYes
referencestringYes
descriptionstringYes
isReadonlybooleanYes
eventTypesstring[]Yes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List an integration's usable connections #

GET /authoring/integrations/{id}/connections · key scope authoring

The connections of this integration an event trigger may be created on.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe integration id, such as `yekar.gmail`.

Responses

StatusMeaning
200The connections.
FieldTypeRequiredNotes
connectionsobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Read an integration #

GET /authoring/integrations/{id} · key scope authoring

One integration with each tool's input schema and the events it can fire a trigger on.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
idpathstringYesThe integration id, such as `yekar.gmail`.

Responses

StatusMeaning
200The integration.
FieldTypeRequiredNotes
idstringYes
namestringYes
descriptionstringYes
toolsobject[]Yes
FieldTypeRequiredNotes
namestringYes
referencestringYes
descriptionstringYes
isReadonlybooleanYes
inputSchemaobjectYes
eventsobject[]Yes
FieldTypeRequiredNotes
typestringYes
namestringYes
descriptionstringYes
schemaVersionnumberYes
filterablePathsstring[]Yes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Knowledge

List knowledge bases #

GET /authoring/knowledge-bases · key scope authoring

The knowledge bases the caller can see: those of their domains and the organization-wide ones. New articles are written into a base.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
qquerystringNo
limitqueryintegerNo
offsetqueryintegerNo
domainIdquerystring (uuid, pattern)No

Responses

StatusMeaning
200One page of knowledge bases and the total.
FieldTypeRequiredNotes
knowledgeBasesobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
descriptionstring | nullYes
domainIdstring | nullYes
totalnumberYes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

List a domain's knowledge modules #

GET /authoring/knowledge-modules · key scope authoring

The knowledge modules of one domain the caller may view.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
domainIdquerystring (uuid, pattern)Yes

Responses

StatusMeaning
200The modules.
FieldTypeRequiredNotes
modulesobject[]Yes
FieldTypeRequiredNotes
idstringYes
namestringYes
descriptionstring | nullYes
kind"domain" | "org" | "platform"Yes
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Create a knowledge module #

POST /authoring/knowledge-modules · key scope authoring

A named set of articles an agent can be pointed at. A domain module needs `domainId`.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Request body

FieldTypeRequiredNotes
kind"domain" | "org"Yes
domainIdstring (uuid, pattern)No
namestringYes
descriptionstringNo

Responses

StatusMeaning
201Created. The module.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Create a draft article #

POST /authoring/knowledge-bases/{baseId}/articles · key scope authoring

A new article in a knowledge base, as a draft. Publish it from the product when it is ready.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
baseIdpathstringYesThe knowledge base's id.

Request body

FieldTypeRequiredNotes
titlestringYes
draftBodystring | nullNo

Responses

StatusMeaning
201Created. The article.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).

Add an article to a module #

POST /authoring/knowledge-modules/{moduleId}/articles · key scope authoring

Reference an existing article from a knowledge module.

**Key scope:** `authoring` (Build agents, integrations and knowledge).

Parameters

NameInTypeRequiredNotes
moduleIdpathstringYesThe module's id.

Request body

FieldTypeRequiredNotes
articleIdstring (uuid, pattern)Yes

Responses

StatusMeaning
201Created. The module membership.
400The body is invalid - an unknown field, a missing one or a bad value (`VALIDATION`).
404Not found: the key is missing, invalid or lacks the scope, or the target does not exist or is in another organization.
429Too many requests from this key or address (`RATE_LIMITED`).