Skip to main content
Glama
mcp-1c-local-bridge

mcp-1c-local-bridge

by ntappw

query

Read-only

Executes 1C language requests against an open session with the session user's rights and returns results for all statements in the batch, with typed parameters and table or JSON output.

Instructions

Выполняет запрос 1С на сервере с правами пользователя сеанса и возвращает результаты всех запросов пакета.

Значения параметров: строка, число, булево и null передаются как есть, массив - список значений
(для В (&Список)). Особые значения - объекты:
{"_date": "2026-10-21T00:00:00"} - дата (можно "2026-10-21");
{"_type": "Справочник.Контрагенты", "_uuid": "..."} - ссылка; ссылку из результата format=json
можно передать целиком;
{"_type": "Перечисление.ВидыКонтрагентов", "_name": "ЮридическоеЛицо"} - значение перечисления;
{"_predefined": "Справочник.Валюты.Рубль"} - предопределённое значение;
{"_expr": "НачалоГода(ТекущаяДатаСеанса())"} - выражение 1С, вычисленное на сервере.
РАЗРЕШЕННЫЕ и ПЕРВЫЕ в текст не добавляются: пишите их сами.

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": {
      "text": "<text>"
    },
    "name": "query"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesТекст запроса 1С; пакет из нескольких запросов допустим.
formatNotable - таблицы и сводки для чтения, ссылки показаны представлениями; json - ответ как есть, с типами и UUID ссылок.table
paramsNoПараметры запроса: {"Имя": значение}. Подробности формата - в описании инструмента.
sessionNoСеанс моста: идентификатор из sessions или часть строки соединения, имени конфигурации, пользователя. Не указан - единственный открытый сеанс.
timeoutNoСколько секунд ждать ответ. Команда, которую обработка не начала за это время, снимается; начатая выполняется дальше, её результат забирается инструментом result.
row_limitNoСколько строк каждого результата вернуть.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.0

TDQS

A3.8/5.0
Behavior4/5

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

The annotation already establishes readOnlyHint=true, yet the description adds meaningful context: it runs with the session user's rights and returns results for all queries in a batch, not just the first. The timeout semantics are also disclosed, including that a command not yet started is cancelled while a started command continues and can be collected via the result tool. The remaining gap is that it doesn't describe result shape or how multiple batch results are keyed, though an output schema exists.

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?

The purpose is front-loaded in the first sentence, followed by the parameter value grammar, which is dense but every element is load-bearing. The special-value list is compact and uses inline examples rather than prose. Minor deduction for a somewhat run-on structure where the caveat about not adding РАЗРЕШЕННЫЕ/ПЕРВЫЕ sits at the end rather than near the text parameter guidance.

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?

Given an output schema exists, the description does not need to explain return values, and it sensibly focuses on authorization context, batch behavior, timeout/async handling, and parameter encodings. Session selection is left entirely to the schema, which does document it. For a six-parameter tool with a real output schema, this is nearly complete.

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

Parameters5/5

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

Schema coverage is 100%, so the baseline would be 3, but the description goes well beyond it by defining the params value model: scalars pass through, arrays become value lists for В (&Список), and five special object forms (_date, _type/_uuid reference, _name enum, _predefined, _expr) are specified with examples. It even notes that the 1C query builder's РАЗРЕШЕННЫЕ/ПЕРВЫЕ clauses are not injected, which an agent would otherwise assume. The schema itself defers to this description for params details, so this is essential, not redundant.

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

Purpose4/5

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

The description names a specific verb and resource: it executes a 1C query on the server under the session user's rights and returns the results of every query in the batch. That is well beyond a restatement of the name 'query'. It does not, however, distinguish the tool from siblings such as eval or execute, which could plausibly run server-side code as well.

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

Usage Guidelines2/5

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

The description contains no when-to-use guidance and no exclusions; it never says why an agent should use query instead of eval or execute. The only routing hint is buried in the timeout parameter description, which points to the 'result' tool for retrieving results of a command that was already started. That is incidental, not a usage policy.

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