Change a lead field
update_lead_fieldChange a lead field
Changes a custom field's label, whether it is required, or its choices. The key and the
type stay (to change them, add a new field). Built-in fields (built_in: true), the lead
statuses included, can't be changed through the API (422 system_field). The AI's lead
capture follows the change in the background, usually within a minute. A request that
changes nothing returns the field as it is.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | No | Can't contain angle brackets. | |
| options | No | Replaces the choices of an `enum` field (`422 invalid_request` for another type), in the order sent, each `value` distinct. A choice whose `value` stays keeps what the dashboard set on it, such as its colour. Leads keep values you remove. | |
| 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`. | |
| required | No | Whether the AI treats the field as needed before it saves a lead. | |
| field_key | Yes | A lead field's `key`, as `listLeadFields` returns it, matched exactly (case included). A key the agent has no field for is `404 not_found`. |