Skip to main content
Glama
1C OData MCP

1C OData MCP

Зарегистрировать счёт от поставщика

write.purchase.create_supplier_invoice

Creates a supplier invoice in 1C to register an incoming invoice for payment or prepayment, supporting goods and service lines; previews by default and writes only on confirmation.

Instructions

Создаёт документ «Счёт на оплату поставщика» — регистрирует входящий счёт-основание для оплаты (подходит для предоплаты, когда товар ещё не пришёл). Проводок НЕ делает (счёт не проводится), счета учёта не нужны. Табличная часть «Товары» вмещает и товары, и услуги (напр. доставку — задайте content/Содержание). Реквизиты входящего счёта: incomingNumber/incomingDate. По умолчанию dry-run; создание — при confirm=true. Контрагент — поставщик, договор — вида «СПоставщиком».

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": {
      "counterpartyRef": "<counterpartyRef>",
      "lines": "<lines>"
    },
    "name": "write.purchase.create_supplier_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
dateNoДата документа YYYY-MM-DD (по умолчанию — момент предпросмотра)
linesYesПозиции счёта (товары и услуги в одной таблице)
commentNoКомментарий к документу
confirmNofalse (по умолчанию) — только предпросмотр (dry-run), запись НЕ выполняется. true — выполнить создание. Сначала всегда показывайте dry-run и получайте согласие пользователя; при подтверждении передавайте operationId из результата предпросмотра и те же аргументы. После таймаута повторяйте подтверждение с тем же id, не создавая новый предпросмотр.
databaseNoИмя базы 1С из list_databases. Без указания — база по умолчанию; если баз несколько и неясно какая, спросите пользователя.
contractRefNoRef_Key договора (вид «СПоставщиком»)
operationIdNoUUID из предпросмотра. Передайте его при confirm=true, чтобы повтор не создал дубликат.
incomingDateNoДата входящего счёта YYYY-MM-DD
organizationNoОрганизация (юрлицо) для фильтра: часть названия, ИНН или Ref_Key из list_organizations. Без указания — все организации базы.
incomingNumberNoНомер входящего счёта поставщика
responsibleRefNoОтветственный документа — Ref_Key пользователя 1С (read.catalog.list_users): ставится в «Ответственный» или, где его нет (продажи и закупки УТ), в «Менеджер». Помеченный, недействительный и служебный — отказ; у документов без обоих полей (ПКО, РКО и заявка на расходование УТ) — отказ. Заменяет ответственного из fields
sumIncludesVatNoСумма включает НДС
counterpartyRefYesRef_Key контрагента-поставщика
supplierBankAccountRefNoRef_Key банковского счёта поставщика (БанковскийСчетКонтрагента)

Output Schema

NameRequiredDescriptionDefault
refNo
codeNo
noteNo
notesNo
dryRunNo
createdNo
payloadNo
retriedNo
warningNo
databaseNo
replayedNo
entitySetNo
reconciledNo
willCreateNo
descriptionNo
operationIdNo
deletionMarkNo
writableBaseNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A4.7/5.0
Behavior5/5

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

Goes well beyond the annotations (which only say readOnly=false, destructive=false, openWorld=true): it discloses that the document is NOT posted, that accounting accounts are not required, that dry-run is the default, how to resume after a timeout using the same operationId without creating a duplicate preview, and that the contract must be of type «СПоставщиком».

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?

A tight single paragraph ordered from what the tool does, to what it does not do, to line-item specifics, to the dry-run/confirm protocol. Every clause carries distinct information; nothing repeats the schema verbatim.

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?

For a 14-parameter mutation with a full schema, annotations and an output schema, the description supplies exactly what structured fields cannot: the posting/non-posting consequence, the prepayment use case, and the two-step preview-then-confirm safety protocol. Nothing an agent needs in order to call it safely is missing.

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 real meaning: it tells the agent that «Товары» mixes goods and services, that content/Содержание must be filled for services because 1С does not populate it, and pairs incomingNumber with incomingDate as the incoming invoice requisites. That is guidance beyond the field-level descriptions.

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 and document type («Создаёт документ «Счёт на оплату поставщика»») and immediately scopes it: registers an incoming invoice-basis for payment, no postings. It distinguishes itself from the sibling create_received_invoice by explicitly denying posting behavior and by naming the prepayment scenario where goods have not yet arrived.

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

Usage Guidelines4/5

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

Gives a concrete when-to-use condition («подходит для предоплаты, когда товар ещё не пришёл») and a required workflow: always show dry-run first, obtain consent, then confirm=true with the operationId. It does not explicitly name a competing sibling to route away from, so it stops short of full when-not guidance.

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

Deploy Server

Other Tools