Skip to main content
Glama

Создать сделку

b24_create_deal

Creates a Bitrix24 deal, optionally with a new contact or an existing contact_id, and returns deal_id and contact_id. Set funnel and stage via b24_portal; verify contacts first to avoid duplicates.

Instructions

Создаёт сделку в Битрикс24, при необходимости вместе с новым контактом (contact_name + phone/email) или привязывает существующий contact_id. Возвращает deal_id и contact_id. Воронку и стадию берите из b24_portal; без них сделка попадёт в первую стадию общей воронки. Перед созданием проверьте b24_find_contact, чтобы не плодить дубли контактов. Изменяет данные в Битрикс24: покажите пользователю, что будет записано, и получите согласие. Требует BITRIX24_WEBHOOK_URL (входящий вебхук с правами crm, task, user); лимит 2 запроса/с соблюдается автоматически.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
emailNoE-mail нового контакта
phoneNoТелефон нового контакта
titleYesНазвание сделки
amountNoСумма
commentNoОписание сделки
currencyNoВалюта, например RUBRUB
stage_idNoID стадии
contact_idNoID существующего контакта
category_idNoID воронки
contact_nameNoИмя нового контакта
responsible_idNoID ответственного

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond annotations (readOnly=false, destructive=false, idempotent=false): it discloses the return values (deal_id, contact_id), that data is modified and user consent must be obtained, the required BITRIX24_WEBHOOK_URL with crm/task/user rights, and that the 2 req/s limit is handled automatically. Rich, actionable behavioral context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads what the tool does and the return shape, then stacks prerequisites, consent, and config requirements. Every sentence carries distinct information with no filler, appropriate for an 11-parameter mutation tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description compensates by naming the returned IDs. Safety/consent, auth config, rate limits, and the funnel/stage dependency are all covered, leaving nothing an agent needs to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds non-obvious relational semantics: contact_name + phone/email creates a new contact while contact_id links an existing one, and funnel/stage come from b24_portal. It does not spell out every field (amount, currency, responsible_id), but the cross-parameter logic is the valuable part.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Создаёт сделку в Битрикс24') plus the secondary capability of optionally creating or linking a contact. This clearly distinguishes it from b24_create_lead and b24_update_deal, which are the nearest siblings.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly prescribes prerequisites and alternatives: pull funnel/stage from b24_portal (with the consequence of omitting them — first stage of the general funnel), and check b24_find_contact first to avoid duplicate contacts. This is real when-to-use/when-not guidance, not implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.