CRM · Изменение
Изменить группу, карту или скидку клиента
Сохраняет изменения в выбранной карточке CRM по её ревизии. Среди доступных полей — группа клиента, номер карты и скидка.
crm_workspace_customer_update
Попробуйте три запроса
Сменить группу
- Вы указываетеКлиент и группа
- ПомощникПроверка ID группы
- Вы получаетеПредлагаемая группа
Запрос в чат
Для выбранного клиента найди существующую группу «Постоянные». Покажи текущую группу и подготовь изменение GroupClient по актуальной ревизии карточки. Если подходящих групп несколько, дай мне выбрать.
- Поле
- GroupClient
- Новая группа
- Постоянные
Изменить скидку
- Вы указываетеВыбранный клиент
- ПомощникИзменение Discount
- Вы получаетеСохранённый процент
Запрос в чат
В выбранной карточке CRM установи персональную скидку 5 %. Сверь текущее значение и ревизию, запиши Discount и покажи сохранённую скидку.
- Поле
- Discount
- Новое значение
- 5 %
Исправить номер карты
- Вы указываетеПрежний номер
- ПомощникПравка CardNumber
- Вы получаетеНомер после записи
Запрос в чат
В выбранной карточке замени номер карты с DEMO-51 на DEMO-52. Если исходный номер отличается, покажи расхождение. После изменения сверь CardNumber.
- Было
- DEMO-51
- Стало
- DEMO-52
Как работает действие
Этот вызов может изменить рабочие данные. Согласуйте точный объект, новые значения и ожидаемый результат. Присвойте операции стабильный requestId. При повторе той же операции используйте прежний ключ и те же значения. Прочитайте актуальную версию записи перед подготовкой запроса.
Описание разработчика
Edit the exact reviewed native CRM customer profile at its revision, including permitted ordinary fields, addresses, cars and existing contact/custom-field indices. Native writer rechecks protected membership and ownership. Does not create an Auth login or change access grants.
Параметры запроса
- requestId
- Ключ этой операции. Для повтора с теми же аргументами сохраните исходное значение. обязательно по схеме · string
- customerId
- Идентификатор клиента, выбранного по результату поиска. обязательно по схеме · string
- revision
- Текущая версия выбранной записи. обязательно по схеме · string
- values
- Значения для записи. Состав и вложенность указаны в схеме. обязательно по схеме · object · по умолчанию {}
- points
- Native points value; use the value and type returned by the corresponding service. обязательно по схеме · array · по умолчанию [] · до элементов 500
- fields
- Native fields value; use the value and type returned by the corresponding service. обязательно по схеме · array · по умолчанию [] · до элементов 500
- Address
- Native Address value; use the value and type returned by the corresponding service. обязательно по схеме · array · по умолчанию [] · до элементов 100
- Cars
- Native Cars value; use the value and type returned by the corresponding service. обязательно по схеме · array · по умолчанию [] · до элементов 100
Что вернёт команда
- companyId
- Native companyId value; use the value and type returned by the corresponding service. обязательно по схеме · string
- result
- Native result value; use the value and type returned by the corresponding service. обязательно по схеме · object
Поля и технические схемы

Вход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"requestId": {
"type": "string",
"pattern": "^[A-Za-z0-9_-]{8,128}$",
"description": "Stable request ID for these exact arguments. Keep it if the response is uncertain."
},
"customerId": {
"type": "string",
"pattern": "^[A-Za-z0-9_~:@+.-]{1,128}$",
"description": "Native customerId value; use the value and type returned by the corresponding service."
},
"revision": {
"type": "string",
"pattern": "^\\d+:\\d+$",
"description": "Native revision value; use the value and type returned by the corresponding service."
},
"values": {
"default": {},
"description": "Native values value; use the value and type returned by the corresponding service.",
"type": "object",
"properties": {
"display_name": {
"description": "Native display_name value; use the value and type returned by the corresponding service.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"Firstname": {
"description": "Native Firstname value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Lastname": {
"description": "Native Lastname value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Comment": {
"description": "Native Comment value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 20000
},
"CardNumber": {
"description": "Native CardNumber value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Discount": {
"description": "Native Discount value; use the value and type returned by the corresponding service.",
"anyOf": [
{
"type": "number",
"minimum": 0,
"maximum": 100
},
{
"type": "null"
}
]
},
"GroupClient": {
"description": "Native GroupClient value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"TaxID": {
"description": "Native TaxID value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Language": {
"description": "Native Language value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 35
},
"Establishment": {
"description": "Native Establishment value; use the value and type returned by the corresponding service.",
"type": "string",
"pattern": "^[A-Za-z0-9_~:@+.-]{1,128}$"
},
"BF": {
"description": "Native BF value; use the value and type returned by the corresponding service.",
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
},
{
"type": "null"
}
]
},
"NotificationEmail": {
"description": "Native NotificationEmail value; use the value and type returned by the corresponding service.",
"type": [
"boolean",
"null"
]
},
"NotificationSMS": {
"description": "Native NotificationSMS value; use the value and type returned by the corresponding service.",
"type": [
"boolean",
"null"
]
},
"NotificationPUSH": {
"description": "Native NotificationPUSH value; use the value and type returned by the corresponding service.",
"type": [
"boolean",
"null"
]
}
},
"additionalProperties": false
},
"points": {
"default": [],
"description": "Native points value; use the value and type returned by the corresponding service.",
"maxItems": 500,
"type": "array",
"items": {
"type": "object",
"properties": {
"index": {
"$ref": "#/$defs/_mcp0"
},
"value": {
"type": "string",
"maxLength": 512,
"description": "Native value value; use the value and type returned by the corresponding service."
}
},
"required": [
"index",
"value"
],
"additionalProperties": false
}
},
"fields": {
"default": [],
"description": "Native fields value; use the value and type returned by the corresponding service.",
"maxItems": 500,
"type": "array",
"items": {
"type": "object",
"properties": {
"index": {
"$ref": "#/$defs/_mcp0"
},
"value": {
"anyOf": [
{
"type": "string",
"maxLength": 20000
},
{
"type": "number"
},
{
"type": "boolean"
}
],
"description": "Native value value; use the value and type returned by the corresponding service."
}
},
"required": [
"index",
"value"
],
"additionalProperties": false
}
},
"Address": {
"default": [],
"description": "Native Address value; use the value and type returned by the corresponding service.",
"maxItems": 100,
"type": "array",
"items": {
"type": "object",
"properties": {
"index": {
"$ref": "#/$defs/_mcp0"
},
"values": {
"type": "object",
"properties": {
"name": {
"description": "Native name value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"address": {
"description": "Native address value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"city": {
"description": "Native city value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"state": {
"description": "Native state value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"country": {
"description": "Native country value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"zipCode": {
"description": "Native zipCode value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Apartment": {
"description": "Native Apartment value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Comment": {
"description": "Native Comment value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
}
},
"additionalProperties": false,
"description": "Native values value; use the value and type returned by the corresponding service."
}
},
"required": [
"index",
"values"
],
"additionalProperties": false
}
},
"Cars": {
"default": [],
"description": "Native Cars value; use the value and type returned by the corresponding service.",
"maxItems": 100,
"type": "array",
"items": {
"type": "object",
"properties": {
"index": {
"$ref": "#/$defs/_mcp0"
},
"values": {
"type": "object",
"properties": {
"Mark": {
"description": "Native Mark value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Model": {
"description": "Native Model value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Number": {
"description": "Native Number value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"Color": {
"description": "Native Color value; use the value and type returned by the corresponding service.",
"type": "string",
"maxLength": 2000
},
"FuelConsumption": {
"description": "Native FuelConsumption value; use the value and type returned by the corresponding service.",
"anyOf": [
{
"type": "number",
"minimum": 0
},
{
"type": "null"
}
]
}
},
"additionalProperties": false,
"description": "Native values value; use the value and type returned by the corresponding service."
}
},
"required": [
"index",
"values"
],
"additionalProperties": false
}
}
},
"required": [
"requestId",
"customerId",
"revision",
"values",
"points",
"fields",
"Address",
"Cars"
],
"additionalProperties": false,
"$defs": {
"_mcp0": {
"type": "integer",
"minimum": 0,
"maximum": 10000,
"description": "Native index value; use the value and type returned by the corresponding service."
}
}
}Выход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"companyId": {
"type": "string",
"description": "Native companyId value; use the value and type returned by the corresponding service."
},
"result": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/$defs/__schema0"
},
"description": "Native result value; use the value and type returned by the corresponding service."
}
},
"required": [
"companyId",
"result"
],
"additionalProperties": false,
"$defs": {
"__schema0": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"items": {
"$ref": "#/$defs/__schema0"
}
},
{
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/$defs/__schema0"
}
}
]
}
}
}