Skip to main content
POST
Create AI agent

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required

AI agent name.

Required string length: 1 - 255
prompt
string
required

System prompt that defines the agent's behavior.

Required string length: 1 - 10000
messages
object[]
required

Seed conversation history (role/content pairs) shown to the model before user input.

models
object[]
required

Ordered fallback list of provider/model pairs to try. The first entry is preferred; later ones are used if it fails.

temperature
number
required

Sampling temperature, 0-2.

Required range: 0 <= x <= 2
maxOutputTokens
number
required

Maximum tokens the model may generate in one reply.

Required range: 1 <= x <= 32768
tools
string[]
required

Tool names this agent is allowed to call.

isDefault
boolean
required

Whether this is the workspace's default AI agent.

webSearchAuthorizedDomains
object[]

Domains the agent's web-search tool is restricted to, up to 20. Empty means unrestricted.

Maximum array length: 20
isRichResponse
boolean
default:false

Whether the agent may return rich (card/button) responses instead of plain text.

Response

OK

createdAt
string<date-time>
required
updatedAt
string<date-time>
required
name
string
required
prompt
string | null
required
messages
(string | number | boolean | null | object | null[])[]
required
isDefault
boolean
required
isRichResponse
boolean
required
tools
string[]
required
webSearchAuthorizedDomains
string[]
required
models
(string | number | boolean | null | object | null[])[]
required
temperature
number
required
Required range: -140737488355328 <= x <= 140737488355327
maxOutputTokens
integer
required
Required range: -2147483648 <= x <= 2147483647
id
any
workspaceId
any