Skip to main content
Glama
S-CurveLabs

letin

Official
by S-CurveLabs

get_query

Read-only

Retrieve the complete M code for a named query, including parsed steps, data sources, dependencies, and dependents, to inspect or refactor Power Query logic.

Instructions

Full M code of one query plus its parsed steps, data sources, dependencies and dependents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
sourceYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

B3/5.0
Behavior3/5

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

The readOnlyHint annotation already covers the safety profile, so the description adds value by detailing what is returned: full M code, parsed steps, data sources, dependencies, and dependents. It does not describe error behavior or how missing/ambiguous queries are handled, but for a simple read-only getter this is an acceptable gap.

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?

The description is a single efficient sentence that front-loads the most important fact, 'Full M code of one query', before listing additional returned content. There is no filler or redundancy.

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

Completeness2/5

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

With no output schema and no parameter documentation, the description leaves important invocation details to inference. It tells the caller what is returned but not how source and name are used, what constraints apply, or what the output structure looks like beyond a short list of content types.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must explain the two required parameters, source and name. It does not explicitly do so; 'one query' implies that name identifies a query and source scopes it, but the description never clarifies what a 'source' is or how it relates to the returned data sources.

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 states a clear resource ('one query') and a specific deliverable ('Full M code plus its parsed steps, data sources, dependencies and dependents'). It implicitly distinguishes itself from list-oriented siblings like list_queries and dependency_graph, though it does not explicitly name them.

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?

There is no guidance on when to use this tool versus alternatives such as list_queries, dependency_graph, or extract_parameter. The description implies a per-query retrieval use case, but it does not state when a caller should prefer this sibling or which excluded scenarios apply.

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