Update contract terms
assinafy_update_contractManage an existing document’s CLM record: set creates/patches terms or links a signed amendment; renew starts the next term; terminate closes tracking. Requires a tracking plan. Read first: include terms.updated_at for existing terms or links; renew requires the current term and updated_at, terminate requires updated_at. A conflict needs a fresh read and user review, never blind retries. Only supplied terms change; external_references replaces the list; null can clear values or unlink a pending amendment. Assinafy owns auto-renewal and owner reminders; changes can trigger lifecycle emails/webhooks. These actions do not sign, send or cancel the document itself. Use only for changes the user authorized.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| term | No | The term this renewal starts from, the contract's current `term`. Required unless `end_date` is sent; for a contract in another term the renewal is refused, so a repeated request never renews twice. | |
| terms | No | Every attribute is optional and only the ones sent change. `null` clears an attribute, except `auto_renew` (back to `false`) and `currency` (back to `BRL` while a `value` is set); `status` does not accept `null`. A changed `end_date` starts a new `term`. | |
| value | No | The new value; unchanged when not sent, cleared by `null`. | |
| action | Yes | ||
| reason | No | Kept in the `document_contract_terminated` event; HTML is stripped. | |
| end_date | No | The new end date, after the current one. Absent, empty or `null`: the current end date plus the renewal term, stepped until it is in the future; `term` is then required. | |
| account_id | No | ||
| updated_at | No | Optional precondition: the contract's `updated_at` as read. Changed since: `409`, nothing terminated. | |
| document_id | No |