Skip to main content
Glama
elekto-com-br

Elekto MCP for SQL Server

Official

List stored procedures

list_procedures
Read-onlyIdempotent

Lists user stored procedures in a SQL Server database with line, join, and referenced object counts to identify complex ones for review.

Instructions

Lists the user stored procedures the login can see, with line count, join count and number of referenced objects as rough complexity metrics. Use it to find procedures and pick the complex ones; for one procedure's text use get_procedure_definition. definition_visible is false, and the metrics null, for a procedure whose text is hidden from the login; referenced_object_count is null when the login cannot read dependencies. SQL Server leaves out procedures the login has no permission on without an error: get_database_overview says whether that happens, check_permissions why.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schemaNoFilter by schema name. Empty means every schema. Example: 'Feeder'
databaseYesName of the database as registered in the configuration.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, but the description adds substantial behavior beyond them: definition_visible=false and null metrics when text is hidden, referenced_object_count null when dependencies are unreadable, and SQL Server's silent omission of unauthorized procedures.

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?

Front-loaded with the core purpose and routing, then the caveats. Dense but every sentence carries information; the caveat sentence is long and could be split, but nothing is wasted.

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?

Despite no output schema, the description explains the returned complexity metrics and their null semantics, and covers the edge case of silently omitted procedures plus where to diagnose it. Nothing an agent needs to call or interpret this tool is missing.

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 description coverage is 100%, so both parameters (database, schema filter with default and example) are already fully documented in the schema. The description adds no parameter-level syntax or format detail, so the baseline of 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 ('Lists the user stored procedures') plus scope ('the login can see') and the extra data returned. It is clearly separable from the sibling get_procedure_definition, which it names.

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?

Explicitly says when to use it ('find procedures and pick the complex ones') and names the alternative for the other case ('for one procedure's text use get_procedure_definition'). It further routes the agent to get_database_overview and check_permissions for the silent-permission-omission situation.

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