update_lead
Edit an existing lead in the Leads CRM (crm_leads): name, email, phone, location, do-not-contact flag/reason, lifecycle state (new/active/flagged/archived), or the synopsis fields (title, company_name, tags, notes). Identify the lead with lead_id or email_lookup. Moving state to 'flagged' or 'archived' REQUIRES state_reason. Archiving sets archived_at (safe-archive, reversible — move state off archived to restore it). If the lead's outreach is set to auto and you move it off 'active', outreach is demoted back to manual (auto-outreach is only valid while active). Use when the operator or an agent needs to fix or maintain lead data — wrong email, bad name, DNC request, or a lifecycle move — instead of telling the user to edit it in the UI.
Routing: CRM/sales → edit a lead's fields, status, or DNC flag → use this (NOT update_lead_status/log_activity — those are removed)
[write-tier — first use may require a manager's approval; a from-now-on approval makes future calls seamless, a just-once approval re-asks next time.]
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | New full name. | |
| tags | No | Replacement tag list — folded into synopsis_jsonb.manual_entry. | |
| No | New email (normalized to lowercase/trim). Rejected if it already belongs to another lead in this company. | ||
| notes | No | Notes about the lead — folded into synopsis_jsonb.manual_entry. | |
| phone | No | New phone number. | |
| state | No | New lifecycle state. state_reason is REQUIRED when moving to 'flagged' or 'archived'. | |
| title | No | Job title — folded into synopsis_jsonb.manual_entry (other manual_entry keys are preserved). | |
| lead_id | No | UUID of the lead to update. Provide this OR email_lookup. | |
| location | No | New location. | |
| companyId | Yes | FreedomOS company id to act within (you must be a member). Required for company-scoped tools. | |
| company_name | No | Company they work for — folded into synopsis_jsonb.manual_entry. | |
| email_lookup | No | The lead's CURRENT email, used to find it. Provide this OR lead_id. | |
| state_reason | No | Reason for the state change. Required when state is 'flagged' or 'archived'. | |
| do_not_contact | No | Set true to flag the lead do-not-contact (excluded from outreach); false to clear it. | |
| do_not_contact_reason | No | Reason for do_not_contact, e.g. 'customer', 'churned', 'opted_out'. |