query_data
Use query_data for read-only DuckDB analysis against project data sources
Parameters
Section titled “Parameters”| Name | Type | Required | Default | Description |
|---|---|---|---|---|
project_name | Annotated[str, Field(description='Name of the Bridge Town project whose data sources to query.')] | Yes | — | |
sql | Annotated[str, Field(description="SQL SELECT statement to execute against the project's registered data sources using DuckDB syntax.")] | Yes | — | |
row_limit | Annotated[int, Field(description='Maximum number of rows to return. Defaults to 1000. Use to avoid overwhelming the context window with large result sets.')] | No | 1000 |
Returns
Section titled “Returns”Returns a structured object. Top-level fields:
columns(array<string>)rows(array<array<string>>)row_count(integer)truncated(boolean)sources(array<object>)
See the response example below for the full payload shape.
Example
Section titled “Example”Tool Call
Section titled “Tool Call”{ "name": "query_data", "arguments": { "project_name": "forecasts", "sql": "SELECT month, revenue FROM actuals ORDER BY month LIMIT 3", "row_limit": 1000 }}Response
Section titled “Response”{ "columns": [ "month", "revenue" ], "rows": [ [ "2026-01-01", 100.0 ], [ "2026-02-01", 110.0 ], [ "2026-03-01", 121.0 ] ], "row_count": 3, "truncated": false, "sources": [ { "source_name": "actuals", "source_type": "parquet", "tables": [ "actuals" ], "snapshot_taken_at": null } ]}- Module:
Data - Requires authentication via API token or Auth0 JWT.