bots.update
Save the draft.
All fields are optional — only include the fields you want to change. Updating workflow_definition creates a new versioned definition while preserving the history of previous versions.
Reference
PUT/api/v1/workflows/{workflow_id}
- Auth
- API key in
X-API-Key - Content
- application/json
- Returns
- 200 · WorkflowResponse
Update an existing workflow. Args: workflow_id: The ID of the workflow to update request: The update request containing the new name and workflow definition Returns: The updated workflow Raises: HTTPException: If the workflow is not found or if there's a database error
Arguments
| Argument | In | Type | Required | Description |
|---|---|---|---|---|
workflow_id | path | integer | required | |
name | body | string | optional | |
workflow_definition | body | object | optional | |
template_context_variables | body | object | optional | |
workflow_configurations | body | WorkflowConfigurationDefaults | optional |
Example request
curl -X PUT "https://api.decibyl.ai/api/v1/workflows/<workflow_id>" \
-H "X-API-Key: dcb_your_key" \
-H "Content-Type: application/json" \
-d '{"name":"string","workflow_definition":{},"template_context_variables":{},"workflow_configurations":{"channel":"voice","ambient_noise_configuration":{"enabled":false,"volume":0.3},"noise_suppression_configuration":{"enabled":true,"level":100},"recording_configuration":{"enabled":true},"backchannel_configuration":{"enabled":false,"delay_secs":1.2,"phrases":["string"]},"end_call_phrases":["string"],"end_call_farewell":"string","agent_can_end_call":false,"max_call_duration":300,"max_user_idle_timeout":10,"smart_turn_stop_secs":2,"turn_start_strategy":"default","turn_start_min_words":3,"provisional_vad_pause_secs":1.5,"turn_stop_strategy":"transcription","user_speech_timeout":0.4,"caller_environment":"auto","dictionary":"","agent_schedule":{"enabled":false,"timezone":"Asia/Kolkata","slots":[{}]},"interruption_backoff_secs":0,"context_compaction_enabled":false,"fallback_tts":[{"provider":"string","model":"","voice":"","language":""}],"fallback_stt":[{"provider":"string","model":"","voice":"","language":""}],"call_outcomes":[{"code":"","label":"","when":""}],"outcome_actions":[{"tool_uuid":"string","when":[],"arguments":{},"enabled":true}],"follow_caller_language":false,"accept_keypad_input":false,"speak_like_callers":true,"agent_languages":["string"]}}'Response
{
"id": 1,
"name": "string",
"status": "string",
"is_live": true,
"visibility": "everyone",
"created_at": "2026-09-14T09:30:00Z",
"workflow_definition": {},
"current_definition_id": 1,
"template_context_variables": {},
"call_disposition_codes": {
"disposition_codes": []
},
"total_runs": 1,
"workflow_configurations": {},
"version_number": 1,
"version_status": "string",
"workflow_uuid": "string"
}Errors
| Status | When |
|---|---|
404 | Not found |
422 | Validation Error |