Agent Sessions

Submit

Submit sends the first chat message. It posts agent assistant, channel web, and "Ask about a company, a promise, or the next step." as both the message and the title. The stored session is active, with no completed turns yet.

post/v1/agent-sessions

Request

  • Base URL: / (relative, and the document was published on a file host, not at the API’s origin)
  • URL: /v1/agent-sessions
  • Auth: HTTP bearer

Request body

agentstring required

Selected agent.

channelstring

Composer channel.

inputstring

Message text.

titlestring

Conversation title.

Example request

{
  "agent": "assistant",
  "channel": "web",
  "input": "Ask about a company, a promise, or the next step.",
  "title": "Ask about a company, a promise, or the next step."
}

Response

Stored session.

agentstring required

Pinned agent slug.

agentSourcestring nullable

Agent definition source.

channelstring required

Originating channel.

continuationTokenstring nullable required

Signed continuation handle when configured.

costUnitsinteger required

Cumulative metered cost units.

createdAtstring date-time required

Session creation time.

errorstring nullable

Terminal error summary.

errorCodestring nullable

Stable terminal error code.

lastActivityAtstring date-time nullable

Most recent activity time.

llmCallsinteger required

Cumulative model calls.

sessionIdstring required

Stable session id.

status'active' | 'paused' | 'completed' | 'failed' | 'canceled' required

Lifecycle/status slug. Subscription rows use billing states; background task runs use queued/running/succeeded/failed/stopped.

titlestring nullable

Conversation title.

toolCallsinteger required

Cumulative tool calls.

turnsinteger required

Completed turn count.

Example response

{
  "agent": "assistant",
  "agentSource": "builtin",
  "channel": "web",
  "continuationToken": "agt_example",
  "costUnits": 45,
  "createdAt": "2026-09-02T15:00:00Z",
  "lastActivityAt": "2026-09-02T15:01:00Z",
  "llmCalls": 3,
  "sessionId": "session_abc123",
  "status": "active",
  "title": "Review the Acme renewal",
  "toolCalls": 1,
  "turns": 2
}

Changes

No operation changes recorded.