b24_crm_add
Creates a Bitrix24 CRM record for leads, deals, contacts, companies, quotes, or Smart Process items from supplied field values and returns the new ID.
Instructions
Create a CRM record. Returns the new id (classic) or {"item": {...}} (modern).
Writing requires a webhook with the acting user's permissions — pass personal_webhook to create under a specific user.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"fields": "<fields>"
},
"name": "b24_crm_add"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entity | No | Classic CRM entity: 'lead', 'deal', 'contact', 'company', or 'quote'. Ignored when entity_type_id is set. | deal |
| fields | Yes | Field values for the new record, e.g. {'TITLE':'New deal','OPPORTUNITY':1000}. | |
| webhook_url | No | Override the default incoming webhook for this call (https://<portal>/rest/<user_id>/<token>/). If omitted, uses personal_webhook, then the X-B24-Webhook HTTP header, then the BITRIX_WEBHOOK_URL env default. | |
| entity_type_id | No | Numeric CRM entity type id for the modern crm.item.* API (e.g. 1=lead, 2=deal, 1030+=Smart Process). Set this to work with SPA items. | |
| personal_webhook | No | Act as a specific user (their personal incoming webhook). Takes precedence over webhook_url. Required to write to the portal under that user's permissions. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |