Update an agent's settings
update_agentUpdate an agent's settings
Changes the settings you send: the name, the description, the Main Instructions
(instructions), the time zone, the AI handoff, comment auto-hide, and when the AI stops
responding (ai_stop_enabled, ai_stop_when). Send at least one (422 no_settings
otherwise). Everything is validated before anything changes. instructions replaces the
whole text, and the AI follows the new text on its next replies, usually within a minute;
sending the text the agent already has changes nothing. A key can't change an agent's
status (so it can't delete one), ai_model, model_provider, avatar_url or
language: sending any of them with a value is 422 field_not_writable, with the field
in param, and nothing changes. Deleting an agent stays in the dashboard; follow-ups have
updateFollowUpSettings, and the AI's switch per channel updateConnection.
The answer's message_weight says what the agent now reads (Main Instructions, active
knowledge, active attachments' text, in characters) and what one of its replies costs; when
it has a notice, pass it on to the user.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Can't be blank or contain angle brackets. Stored without surrounding spaces. | |
| agent_id | Yes | The agent the resource belongs to. Another company's agent, or the nil UUID, is `404 agent_not_found`; an agent outside the key's agent list is `403 agent_not_authorized`. | |
| time_zone | No | An IANA time zone in Region/City form, such as `Africa/Cairo` (`422 unknown_timezone` otherwise), or an empty string for the platform default. | |
| description | No | An empty string clears it. Can't contain angle brackets. Stored without surrounding spaces. | |
| ai_stop_when | No | When the AI should stop responding, in your words, such as "When the customer asks to talk to a person or wants a refund." Replaces the whole text; an empty string clears it. Stored without surrounding spaces. Sending it without `ai_stop_enabled` keeps the switch as it is. | |
| instructions | No | The Main Instructions. Replaces the whole text, stored and given to the AI exactly as sent; can't be blank. Send plain text with a blank line between rules: the dashboard shows lines without one as a single paragraph, and saves them that way when someone edits them there. | |
| ai_stop_enabled | No | Whether the AI may stop responding in a conversation and hand it to your team. Switching it on, or changing `ai_stop_when` while it's on, applies from the agent's next message. | |
| ai_handoff_enabled | No | Whether a reply from your team pauses the AI in that conversation. | |
| ai_handoff_window_minutes | No | How long the AI stays paused after your team's last message. Kept while the handoff is off. | |
| comment_auto_hide_enabled | No | Whether the AI hides negative Facebook and Instagram comments on the agent's pages. |