Skip to main content
Glama
takeokunn

@takeokunn/metabase-mcp

by takeokunn

execute_query

Run MBQL or native SQL queries against a specified database in Metabase. Choose between query objects or raw SQL strings to retrieve data.

Instructions

Execute an MBQL or native SQL query against a database. For MBQL queries, use type="query" and provide query object. For native SQL, use type="native" and provide native.query string.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYes
Behavior1/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. The tool can execute arbitrary SQL, including destructive statements (DELETE, UPDATE, INSERT), but the description gives no warning about potential side effects, permissions required, or whether results are returned. For a query execution tool, this is a significant omission.

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 two sentences with no unnecessary words. The first sentence states the core function, and the second sentence provides the key usage distinction. It is front-loaded and each sentence serves a purpose.

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?

Given that the tool takes a nested input object and has no output schema, the description should explain what the tool returns (e.g., query results, status, error handling). It does not. The description is incomplete for an agent to fully understand the tool's behavior and output.

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?

While the input schema includes descriptions for parameters like 'type' and 'native.query', the overall description adds little beyond echoing the schema. It does not explain the structure of the 'query' object or the 'template-tags' object, which are complex. With 0% schema description coverage (meaning the description does not compensate for missing schema explanations), the description falls short.

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 explicitly states it executes MBQL or native SQL queries against a database. It clearly distinguishes between the two query types, which sets it apart from sibling tools like execute_card or run_dashcard_query that operate on specific entities.

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

Usage Guidelines4/5

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

The description provides explicit guidance on when to use each query type: 'For MBQL queries, use type="query" and provide query object. For native SQL, use type="native" and provide native.query string.' It doesn't mention when to use this tool versus alternatives like execute_card, but within its scope it is clear.

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/takeokunn/metabase-mcp'

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