sessions

Retrieve a session

Changed on

Retrieve a single session by its friendly id (session_…) or your externalId. The response includes triggerConfig and the friendly currentRunId of the live run, if any.

get/api/v1/sessions/{session}

Request

Response

Successful request

idstring required

The session's friendly ID, prefixed with session_.

externalIdstring nullable

Your stable identity for the session, if one was set.

typestring required

The session type discriminator.

taskIdentifierstring required

The task this session triggers runs against.

currentRunIdstring nullable

Friendly ID of the live run for this session, if any. Prefixed with run_. Omitted on list rows.

tagsstring[] required

Tags on the session row.

metadataobject nullable

Arbitrary JSON metadata, or null if unset.

closedAtstring date-time nullable

When the session was closed, or null if open.

closedReasonstring nullable

The optional reason recorded when the session was closed.

expiresAtstring date-time nullable

The session's retention deadline, or null if none.

createdAtstring date-time required
updatedAtstring date-time required

Example response

{
  "id": "session_abc123",
  "externalId": "chat_1234",
  "type": "chat.agent",
  "taskIdentifier": "my-chat",
  "triggerConfig": {
    "machine": "small-1x",
    "lockToVersion": "20240523.1"
  },
  "currentRunId": "run_def456",
  "tags": [
    "chat:1234"
  ]
}

Changes