Skip to main content
Glama
SynapCores MCP Server

SynapCores MCP Server

Official

Check SQL without running it

validate_query
Read-onlyIdempotent

Check SQL syntax without executing it, returning validity, statement type, and errors. Detect slow queries via EXPLAIN before running writes or debugging failures.

Instructions

Check whether a SQL statement parses, without running it, and return {valid, statement_type, errors}. With include_plan=true, a SELECT also returns its execution plan (EXPLAIN), which helps spot slow queries. Use it before execute on writes you want to be sure of, or to debug a failing query; it never changes data.

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": {
      "sql": "<sql>"
    },
    "name": "validate_query"
  }
}

Input Schema

NameRequiredDescriptionDefault
sqlYesThe SQL statement to check (any statement type).
include_planNotrue = also return the execution plan; applies to SELECT statements (default false).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv1.0.1
    • changedInput schema / properties / include_plan / description
      Previous value: -"Include execution plan (default: false)"New value: +"true = also return the execution plan; applies to SELECT statements (default false)."
    • changedInput schema / properties / sql / description
      Previous value: -"SQL query to validate"New value: +"The SQL statement to check (any statement type)."
  2. First observedv1.0.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnlyHint, idempotentHint, destructiveHint=false), so the bar is lower. The description still adds useful context beyond them by enumerating the returned fields and explaining that include_plan triggers an EXPLAIN for SELECTs, which is the one behavior an agent might not expect from a 'check only' tool. It reinforces rather than contradicts 'never changes data'.

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?

Two sentences with zero waste; the core purpose and return shape are front-loaded, followed by the optional-plan caveat and the usage routing. Every clause earns its place.

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?

There is no output schema, yet the description discloses the returned keys and the include_plan variant, which is exactly what an agent needs to interpret results. For a two-parameter read-only tool with full annotation coverage, nothing material 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 coverage is 100%, so both parameters are already documented. The description only restates that include_plan yields an execution plan for SELECTs, adding the minor nuance that it 'helps spot slow queries' — helpful framing but not substantial semantics beyond the 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?

States a specific verb and resource ('Check whether a SQL statement parses, without running it') and names the exact return shape {valid, statement_type, errors}. It also distinguishes itself from the write path by naming `execute` and `query`, so an agent can separate it from its siblings without opening a schema.

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?

Gives explicit when-to-use conditions: before `execute` on writes, or to debug a failing `query`. It names both alternatives and the situation that selects this tool, leaving nothing to inference.

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