[POST] .../v1/partner/edit
Edits partner. Use this method to update partner master data while keeping the same partner ID used by documents and balances. The method validates id, optional legal_status, database string limits and optional custom field changes, then updates changed fields, writes an action log record, invalidates partner cache, sends the PartnerEdited webhook and returns row_affected. The request body is required; null string fields leave the current value unchanged, an empty string clears fields that are included in the payload and group_id changes the partner group only when it is greater than 0. The current request user must have partner edit permission and additional fields can be edited only when the tariff option is enabled. Missing body, invalid id, invalid legal_status, length violations, denied access, disabled additional fields, no changed fields, missing rows, transaction failures and storage errors are returned as HTTP 200 ErrorResult business errors.
Request Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| address | String | Optional | Partner address. |
| bank_name | String | Optional | Bank name. |
| boss_name | String | Optional | Partner manager name. |
| description | String | Optional | Partner description. |
| String | Optional | Partner email. | |
| fields | Array of FieldValueEdit | Optional | Custom field values. |
| fullname | String | Optional | Full partner name. |
| group_id | Int64 | Optional | Partner group ID. |
| id | Int64 | Required | Partner ID. |
| inn | String | Optional | Partner TIN. |
| legal_status | String | Optional | Partner legal status. Allowed values: Default, Legal, Natural. |
| mfo | String | Optional | Bank MFO code. |
| name | String | Optional | Partner name. |
| oked | String | Optional | OKED code. |
| phones | String | Optional | Partner phone numbers. |
| rs | String | Optional | Bank account number. |
| vat_index | String | Optional | VAT payer registration code. |
Request Example
{
"id": 15,
"name": "Coca-Cola Bottlers",
"phones": "\u002B998901234568",
"email": "accounts@example.test",
"description": "Updated supplier profile",
"fields": []
}
Response Parameters
| Name | Type | Description |
|---|---|---|
| ok | Boolean | Indicates whether the request completed successfully. |
| result | Update | Update operation result. |
Response Example
{
"ok": true,
"result": {
"row_affected": 1
}
}