Update an agent
update_agentChange a saved agent. Safe to repeat: the same call gives the same result.
Instructions
Change a saved agent. Safe to repeat: the same call gives the same result.
Only the fields you pass change; a field left out keeps its value.
``status`` is ``"live"`` or ``"paused"``; a paused agent does not
answer. ``language`` is a lowercase ISO 639-1 code. Pass ``language``
or ``voice_id`` alone: the other value is kept. ``max_duration_seconds``
and ``handover_max_duration_seconds`` are 60..3600.
``handover_contacts`` replaces the whole list: ``[{contact_id, note}]``
(max 10) as in ``create_agent``; ``[]`` removes every contact.
To remove a value, list its name in ``clear_fields``. Allowed:
``first_message`` (the agent waits for the caller),
``ai_disclosure_line`` (back to the workspace line), ``tools``
(back to all tools), ``max_duration_seconds`` (back to the workspace
limit), ``handover_max_duration_seconds`` (back to 1800). Any other
name is refused. Do not set and clear one field.
Live calls keep the settings they started with. The change applies
to the next call or text.
Returns the updated ``AgentResponse`` as a dict, or
``{"error": "<message>"}``.Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| tools | No | ||
| status | No | ||
| agent_id | Yes | ||
| language | No | ||
| voice_id | No | ||
| sms_enabled | No | ||
| clear_fields | No | ||
| ai_disclosure | No | ||
| first_message | No | ||
| system_prompt | No | ||
| voice_enabled | No | ||
| handover_contacts | No | ||
| recording_enabled | No | ||
| ai_disclosure_line | No | ||
| max_duration_seconds | No | ||
| handover_max_duration_seconds | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||