---
title: "POST /api/agent/v1/question/{id}/query"
method: POST
path: "/api/agent/v1/question/{id}/query"
tags: ["/api/agent"]
---

# POST /api/agent/v1/question/{id}/query

`POST /api/agent/v1/question/{id}/query`

## Request

- Base URL: `` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/agent/v1/question/{id}/query`
- Auth: API key in header `X-API-Key`

Run a saved question (card) and return its results.

  Executes the query stored on the card under the caller's permissions and returns rows +
  column metadata — the same response shape as /v1/execute.

  Parameterized questions are NOT supported: if the card declares parameters or input
  template tags (field filters / variables), this returns a 400. Run it in Metabase, or
  save a parameterless version.

## Path parameters

- `id` integer, required

## Request body

- object

## Response `2XX`

Successful response

- MetabaseAgentApiApiExecuteQueryResponse: Response from query execution. The HTTP status is always 202 because results are streamed — check the `status` field to determine success or failure.
  - `data` object
    - `cols` MetabaseAgentApiApiColumnMetadata[], required
      - `base_type` string, required
      - `display_name` string, required
      - `effective_type` string, nullable
      - `name` string, required
    - `rows` array[], required
      - unknown[]
        - unknown
  - `error` string
  - `row_count` integer
  - `running_time` integer
  - `status` 'completed' | 'failed', required

## Other responses

- `4XX`: Client error response
- `5XX`: Server error response

## Changes

- **2026-11-04** `2e178f5a7934`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/metabase/apis/metabase-api/changes/api/agent/v1/question/:id/query/post.md)

---

[API](https://skmtc.dev/metabase/apis/metabase-api.md) - [All operations](https://skmtc.dev/metabase/apis/metabase-api/llms.txt) - [OpenAPI document](https://skmtc.dev/metabase/apis/metabase-api/revisions/2e178f5a7934?raw)
