Chatbots
Update chatbot
Update a chatbot's metadata, trigger, variables, settings, or status. All fields are optional — only the provided fields are changed.
Authorization
ApiKeyAuth X-API-Key<token>
API key from your dashboard (Settings > API Keys)
In: header
Path Parameters
id*string
Chatbot ID (cuid2)
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X PUT "https://loading/api/v1/chatbots/cbt_abc123" \ -H "Content-Type: application/json" \ -d '{ "name": "Support Bot v2", "status": "PAUSED" }'{
"success": true,
"data": {
"id": "cbt_abc123",
"user_id": "string",
"name": "string",
"description": "string",
"status": "DRAFT",
"trigger_type": "MESSAGE_CONTAINS",
"trigger_config": {},
"start_node_id": "string",
"active_version_id": "string",
"variables": [
{
"id": "string",
"name": "string",
"type": "string",
"default_value": null,
"description": "string",
"is_required": true
}
],
"settings": {
"session_timeout_minutes": 0,
"fallback_message": "string",
"max_retries": 0,
"handoff_enabled": true,
"handoff_team_id": "string"
},
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"node_count": 0
}
}{
"success": false,
"message": "to field is required"
}{
"success": false,
"message": "user not authenticated"
}{
"success": false,
"message": "Chatbot not found"
}{
"success": false,
"message": "internal server error"
}

