Skip to main content
Glama

local_ydb_sql

Destructive

Run YQL queries, retrieve execution plans, or preflight and confirm mutating executions against a local YDB instance.

Instructions

Run managed YQL v1 against the configured local-ydb target through Query Service. query uses SnapshotRO, explain returns plan/AST, and execute always runs EXPLAIN first and sends one NoTx execution only with confirm=true.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionNoManaged YQL action. query uses SnapshotRO, explain returns plan/AST without execution, and execute always EXPLAIN-preflights before optional confirmed NoTx execution.query
scriptYesWell-formed-Unicode YQL v1 script; lone UTF-16 surrogates are rejected. Parameter DECLARE statements are generated from parameters and prepended before execution.
confirmNoConsidered only for action=execute. Must be true to send one NoTx execution after successful EXPLAIN; query remains SnapshotRO even when true.
maxRowsNoMaximum retained rows per result set. The first limit hit stops all further result capture: read-only execution is cancelled, while confirmed NoTx execution drains without capturing later output.
profileNoNamed profile from local-ydb.config.json. Defaults to config.defaultProfile.
timeoutMsNoSingle deadline in milliseconds shared by connection, session, preflight, execution, and cancellation.
configPathNoExplicit local-ydb config file path to load for this tool call. Useful when the MCP server should pick up a different config without restart.
parametersNoTyped YQL parameters keyed by bare name. The request is limited to 100 parameters, 1,000 descriptor nodes, 10,000 value nodes, and 1 MiB of serialized parameter data. Struct field names must be well-formed Unicode. Values use the documented JSON representation and are never echoed in response metadata. Json/JsonDocument numbers must be finite, integer values must be JavaScript safe integers, and negative zero is rejected because JSON encoding cannot preserve its sign.
databasePathNoConfigured tenant or root database path. Defaults to the selected profile tenant path; root paths use the static gRPC port.
maxOutputBytesNoShared retained-output budget for issues, plan/AST, columns, and rows.
Behavior4/5

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

Annotations declare readOnlyHint=false, destructiveHint=true, and idempotentHint=false, setting an accurate baseline safety profile. The description adds substantial behavioral context: the explain-before-execute preflight, the SnapshotRO vs NoTx transaction distinction, parameter data never being echoed in response metadata, and the maxRows stop-vs-drain behavior distinction. This meaningfully exceeds the annotation baseline, though it could note auth requirements or the destructiveness scope more explicitly.

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 description is dense but front-loaded with the core purpose in the first sentence and action semantics in the second. It packs significant value per sentence. It doesn't repeat schema-redundant protocol details, though the second sentence is quite dense and spends most of its length on differentiating the three actions, which is appropriate given the tool's complexity.

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 complex 10-parameter tool with nested objects and no output schema, the description covers action semantics, confirm-gating, maxRows edge behavior, parameter limits, and value encoding constraints. The parameters description in schema is thorough, and the description adds the key execution guarantees. It doesn't describe return-value shape, but there's no output schema; some guidance on response structure would be helpful, though the schema is rich enough overall.

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 schema already documents all 10 parameters. The description goes well beyond that baseline by adding critical semantics: the action parameter's SnapshotRO vs NoTx distinction, confirm being considered only for execution, maxRows' stop-vs-drain behavior difference between read-only and confirmed NoTx, and the parameters object's limits (100 params, 1,000 descriptor nodes, 1 MiB serialized data) plus finite-number/JS-safe-integer/negative-zero rejection rules. This adds real value beyond schema.

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?

The description states a specific verb+resource ('Run managed YQL v1 against the configured local-ydb target through Query Service') and explicitly enumerates the three action modes (query uses SnapshotRO, explain returns plan/AST, execute always runs EXPLAIN first). This clearly distinguishes it from siblings like local_ydb_scheme or local_ydb_generate_schema, which handle schema, not SQL execution.

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?

The description explicitly explains when to use each action: query uses SnapshotRO, explain returns plan/AST, execute EXPLAIN-preflights then sends one NoTx execution with confirm=true. The confirm parameter is described as required for execution, and the behavior of maxRows on read-only vs NoTx execution is differentiated. This gives clear decision context for the agent.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/astandrik/local-ydb-toolkit'

If you have feedback or need assistance with the MCP directory API, please join our Discord server