Skip to main content
Glama

execute_card

Read-onlyIdempotent

Run an existing Metabase card by ID to return query results, with optional parameters, row limits, field selection, and pagination.

Instructions

Execute an existing question/card and get results

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": {
      "card_id": "<card_id>"
    },
    "name": "execute_card"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMax rows to return (default: server maxRows setting)
fieldsNoColumn names to include in results (default: all)
formatNoResponse format (default: compact). Use "default" for pretty-printed output
offsetNoRow offset for pagination
card_idYesCard ID to execute
parametersNoValues for the card's SQL variables, keyed by variable name, e.g. { "state": "CA", "min_total": 100 }

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv1.7.0
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / parameters / description
      Previous value: -"Optional parameters for parameterized queries"New value: +"Values for the card's SQL variables, keyed by variable name, e.g. { \"state\": \"CA\", \"min_total\": 100 }"
    • addedInput schema / properties / parameters / propertyNames
      Added value: +{
      +  "type": "string"
      +}
  2. Changed4 schema fields changedv1.3.0
    • addedInput schema / properties / fields
      Added value: +{
      +  "description": "Column names to include in results (default: all)",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / format
      Added value: +{
      +  "description": "Response format (default: compact). Use \"default\" for pretty-printed output",
      +  "enum": [
      +    "default",
      +    "compact"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Max rows to return (default: server maxRows setting)",
      +  "maximum": 10000,
      +  "minimum": 1,
      +  "type": "number"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "description": "Row offset for pagination",
      +  "minimum": 0,
      +  "type": "number"
      +}
  3. First observedv1.1.1

TDQS

C2.9/5.0
Behavior2/5

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

Annotations already declare readOnlyHint, idempotentHint and openWorldHint, so safety is covered. The description adds nothing further: it is silent on pagination behavior, the server maxRows interaction with the limit parameter, how parameters are bound, and whether execution is costly or long-running.

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?

A single short sentence with the verb and resource front-loaded and zero filler. It is economical, though the economy comes partly at the cost of the guidance and behavioral detail noted elsewhere.

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?

For a tool with six parameters, a nested free-form parameters object, pagination controls, and open-world execution, one sentence is not enough. The description never explains how SQL variables are bound, what happens at the server row cap, or how to page through large result sets.

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 every parameter including the parameters object and enum-constrained format is already documented in the schema. The description adds no meaning beyond that, making the baseline 3 the right score.

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 gives a specific verb ('Execute') and resource ('existing question/card') plus the outcome ('get results'), which separates it from metadata-reading siblings like get_card. It stops short of naming any sibling explicitly, so the differentiation is inferable rather than stated.

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?

The word 'existing' hints the card must already be defined, but there is no explicit when-to-use framing and no mention of alternatives such as execute_query for ad-hoc SQL or batch_execute for multiple cards. An agent has to guess which execution tool fits.

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