Update company
well_update_companyUpdate an existing company in the current workspace.
Use this tool when the user asks to change, fix, rename, or edit a company's fields.
REQUIRED: company_id OPTIONAL (only include fields the user wants changed): name, description, domain, registered_name, trade_name, tax_id_value, tax_id_type, registry_country (ISO 3166-1 alpha-2, e.g. "FR"), business_type, registered_value, registry_name, locale (ISO 639-1 two-letter language code, e.g. "en", "fr" — not "en_US").
CATEGORIES (a counterparty's industry): pass category_ids — the COMPLETE set
of category ids the company should carry. It REPLACES the current set: ids you
leave out are unlinked, and [] clears every category. Omit the field to
leave the categories untouched. Read the catalog first with
well_query_records({ root: "categories", whereClause: { category_type: { _eq:
"company" } } }) and pass ids from it — an id that is not a
category_type = "company" row is refused, and this tool never creates a
category.
NOT CHANGEABLE via this tool: emails, phones, locations, linked people, media. Those require dedicated tools (not yet available).
PROVENANCE: decision says HOW the set was chosen. accepted_suggestion —
the user let a category the classifier had already proposed stand, without
touching it. explicit — the user chose the labels.
A request the user typed is always an explicit choice, so never send
accepted_suggestion from a conversation. The affirmation belongs to the
categorization card, where a pre-filled picker the reader leaves alone is the
only thing that can be let stand; a user who names a category in words has
chosen it, even when they say they agree with a suggestion. Omit the field
and the write is explicit.
The server checks an accepted_suggestion claim against the company's own
pending proposals and returns explicit when the written set matches none
of them, so the claim can never manufacture classifier provenance.
Returns { success: true, company_id, name } on success — plus category_count,
the number of categories the company carries afterwards, and decision, the
provenance the server settled on, when the call passed category_ids. Returns
{ success: false, error } on failure.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Company name | |
| domain | No | Primary website domain (e.g. acme.com) | |
| locale | No | Preferred language as an ISO 639-1 two-letter code (e.g. en, fr, de). Pass null to clear. | |
| decision | No | How the user arrived at `category_ids`. Omit it: a request the user typed is an explicit choice, and accepted_suggestion belongs to the categorization card. See the description. | |
| company_id | Yes | The UUID of the company to update (required) | |
| trade_name | No | Trading name / DBA | |
| description | No | Brief company description; pass null to clear | |
| tax_id_type | No | Tax identifier type (VAT, SIRET, EIN, ...) | |
| category_ids | No | The COMPLETE set of company-category ids this company should carry. Replaces the current set; [] clears it; omit to leave categories unchanged. | |
| tax_id_value | No | Tax identifier value (VAT, SIRET, EIN, ...) | |
| workspace_id | No | Target workspace. Omit when the token authorizes one workspace. Required when it authorizes several — a write lands in exactly one workspace and this call would not say which. | |
| business_type | No | Business type / legal form | |
| registry_name | No | Registry name | |
| conversation_id | No | The conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation. | |
| idempotency_key | No | Optional client-supplied key. A retried write with the same key returns the original result instead of re-applying the operation. | |
| registered_name | No | Official registered legal name | |
| registered_value | No | Registry identifier value | |
| registry_country | No | ISO 3166-1 alpha-2 country code of the registry (e.g. FR, US) | |
| ledger_default_source | No | How the AP/AR pick was made. The only value this write accepts is `human_override`: the person chose the account from the chart of accounts. Optional, and it defaults to `human_override`, so a plain assign needs it not at all. | |
| account_payable_default_id | No | The counterparty's default account-payable ledger account (a vendor payable, FR PCG 401). Set it for a counterparty you pay. Omit to leave it; null clears it. Read the ids with `well_list_ledger_accounts`. | |
| account_receivable_default_id | No | The counterparty's default account-receivable ledger account (a customer receivable, FR PCG 411). Set it for a counterparty that pays you. Omit to leave it; null clears it. Must differ from the payable default. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | ||
| error | No | ||
| success | Yes | ||
| decision | No | ||
| company_id | No | ||
| category_count | No | ||
| conversation_id | No | The conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation. | |
| conversation_id_note | No | Present only when the server opened a fresh lane, stating that no choice recorded earlier was read. | |
| conversation_id_source | No | Where the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened. |