API Reference
Chat Sessions & Threads
Managing persistent chat threads, message DAG history, and session metadata.
GET /v1/workspaces/:workspaceId/chats
Lists all chat threads in the specified workspace.
- Scope Required:
chat
Response
[
{
"id": "thread_01jze9m2xw",
"title": "Onboarding Q&A",
"messageCount": 12,
"createdAt": "2026-08-16T00:00:00.000Z",
"updatedAt": "2026-08-16T00:00:00.000Z"
}
]POST /v1/workspaces/:workspaceId/chats
Creates a new chat session thread.
- Scope Required:
chat
Request Body
{
"title": "Project Planning"
}Response
{
"id": "thread_01jze9m2new",
"title": "Project Planning",
"createdAt": "2026-08-16T00:00:00.000Z"
}GET /v1/workspaces/:workspaceId/chats/:threadId/messages
Retrieves the complete message DAG array for a chat thread.
- Scope Required:
chat
Response
[
{
"id": "msg_01",
"role": "user",
"content": "Hello agent",
"createdAt": "2026-08-16T00:00:00.000Z"
},
{
"id": "msg_02",
"role": "assistant",
"content": "Hello! How can I assist you today?",
"createdAt": "2026-08-16T00:00:01.000Z"
}
]