Skip to main content
POST
/
v1
/
agents
/
{agentId}
/
preview
/
start
Start preview chat
curl --request POST \
  --url https://release0.com/api/v1/agents/{agentId}/preview/start \
  --header 'Content-Type: application/json' \
  --data '
{
  "isStreamEnabled": false,
  "message": {
    "type": "text",
    "text": "<string>",
    "attachedFileUrls": [
      "<string>"
    ]
  },
  "isOnlyRegistering": false,
  "agent": "<unknown>",
  "startFrom": {
    "type": "group",
    "groupId": "<string>"
  },
  "initialContext": {
    "First name": "John",
    "Email": "john@gmail.com"
  },
  "sessionId": "<string>",
  "password": "<string>",
  "textBubbleContentFormat": "richText"
}
'
{
  "code": "BAD_REQUEST",
  "message": "Invalid input data",
  "issues": []
}

Path Parameters

agentId
string
required

Identifier of the agent.

Body

application/json
isStreamEnabled
boolean
default:false
message
Text · object
isOnlyRegistering
boolean
default:false

If set to true, the session will only be registered and the bot will not be started.

agent
any

If provided, overrides the agent used to start the chat.

startFrom
object
initialContext
object

Initial context used to prefill variables when starting the session.

Example:
{
"First name": "John",
"Email": "john@gmail.com"
}
sessionId
string

If provided, it will be used as the session identifier and will overwrite any existing session with the same ID.

password
string

Password required if the agent was created with password protection.

textBubbleContentFormat
enum<string>
default:richText
Available options:
richText,
markdown

Response

Successful response