Skip to main content
POST
Create chat session

Authorizations

Authorization
string
header
required

Bearer token authentication. Supports two token types:

  • JWT Access Token — obtained via POST /v1/auth/login
  • Personal Access Token (PAT) — created via POST /v1/api-tokens, format: cmnd_<tokenId>.<secret>

Body

application/json
model
string
required

Model ID to use for this session

Example:

"gpt-4o-mini"

name
string

Optional name for the session

Example:

"Q&A about Product Docs"

knowledgebase_ids
string[]

Optional knowledge base IDs to attach to the session

Example:
temperature
number
default:1

Sampling temperature

Required range: 0 <= x <= 2
system_message
string

Optional system message for the session

Example:

"You are a helpful assistant."

Response

Session created successfully

id
string
Example:

"session_xyz789"

object
string
Example:

"chat.session"

name
string
Example:

"Q&A about Product Docs"

knowledgebase_ids
string[]
model
string
Example:

"gpt-4o-mini"

temperature
number
system_message
string
created_at
integer

Unix timestamp

Example:

1699564800

updated_at
integer

Unix timestamp

Example:

1699564900

message_count
integer
Example:

10