Skip to main content
POST
Stop Bot Chat

Authorizations

Authorization
string
header
required

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

Path Parameters

chat_id
string<uuid>
required
Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$

Body

application/json
bot_id
string<uuid>

Stop only this bot. Without it, every bot working in the chat stops.

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
cursor
string

The cursor of the previous response, so only what happened since is returned. Without one, the read starts after your own newest message.

Required string length: 1 - 2000

Response

The state of the chat after stopping.

chat_id
string
required
title
string
required
status
enum<string>
required

working while a bot is mid-turn, needs_input when a bot waits on question, then done, failed or stopped.

Available options:
working,
needs_input,
done,
failed,
stopped
finished
boolean
required

True once status is done, failed or stopped.

bots
object[]
required
working
object[]
required
progress
string[]
required

New steps of the working bots' turns.

messages
object[]
required

New visible messages since cursor, oldest first.

text
string
required

The bots' new message text, joined.

media
object[]
required

Images, video and audio the bots posted since cursor.

files
object[]
required
out_of_compute_bot_ids
string[]
required

Bots held in this chat because the workspace ran out of compute units. Add units, then call retry or send a message.

timed_out
boolean
required

True when wait ran out while a bot was still working, or more is unread than one response carries. Read again with cursor.

cursor
string
required
url
string
required
question
object
error
object

Present when status is failed. out_of_compute, bot_usage_limit and chat_usage_limit are billing holds, not faults.