Skip to main content
Glama
1C OData MCP

1C OData MCP

Создать списание товаров

write.warehouse.create_writeoff

Creates an unposted goods write-off document for shortages or damage in 1C, with dry-run preview and explicit confirmation before writing.

Instructions

Создаёт документ «Списание товаров» (недостача/порча). НЕПРОВЕДЁННЫЙ; провести — post_document (проводки Дт 94 Кт 41). Можно указать документ-основание — инвентаризацию. dry-run/confirm. В Управлении торговлей — «Списание недостач товаров»: обязательна expenseItem (уточните у пользователя), основание — пересчёт; post_document сверяет движения по складу.

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": {
      "lines": "<lines>"
    },
    "name": "write.warehouse.create_writeoff"
  }
}

Input Schema

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

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.3/5.0
Behavior5/5

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

Annotations only say it is a non-read-only, open-world mutation; the description goes well beyond that by disclosing that the created document stays unposted, that posting produces Дт 94 Кт 41 entries via post_document, that the dry-run/confirm pattern with operationId prevents duplicates on retry, and that УТ requires expenseItem and rejects other bases. This is exactly the behavioral context an agent needs before mutating data.

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

Conciseness4/5

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

Dense but front-loaded: identity and posting state come first, then the dry-run/confirm contract, then УТ-specific caveats. The telegraphic phrasing ('dry-run/confirm', 'основание — пересчёт') is efficient though slightly clipped for an unfamiliar reader.

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

Completeness4/5

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

For a 12-parameter mutation with an output schema, the description covers the critical gaps: unposted state, the posting dependency, two-step confirmation, and the УТ-specific mandatory field. Return-value details are rightly left to the output schema, though the description could say more about how operationId appears in the preview result.

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

Parameters3/5

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

Schema coverage is 100%, so the schema already documents every parameter including the dry-run/confirm contract and the expenseItem rule. The description reinforces the mandatory expenseItem and the inventory basis but adds no syntax, format, or edge-case detail beyond what the schema already states, so the baseline 3 applies.

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 resource ('Создаёт документ «Списание товаров»') and immediately narrows the business case to недостача/порча, which separates it from sibling write-offs such as create_surplus or create_inventory. It also declares the document state (НЕПРОВЕДЁННЫЙ) up front, so the agent knows what it gets.

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 concrete when-to-use context (shortage/damage, optional inventory/пересчёт as basis) and an explicit hand-off to post_document for posting. It does not name sibling alternatives such as create_surplus or create_inventory directly, so the agent must infer the boundary from the business case rather than from an explicit comparison.

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