export_dataset
Export full row-level data to CSV or JSON for external analysis. Automatically paginates past Metabase's 2000-row limit and returns the file path.
Instructions
Export full row-level data to a local CSV or JSON file. Auto-paginates through the 2000-row Metabase cap internally. The file path is returned in the response. Use this when you need complete data for external analysis (Excel, Google Sheets). For analytical queries, use query_dataset with aggregations instead. Caps at 500K rows — add filters for larger tables. Output directory is configurable via METABASE_EXPORT_DIR env var (defaults to ~/Downloads/).
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": {
"database_id": "<database_id>",
"table_id": "<table_id>"
},
"name": "export_dataset"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fields | No | Field IDs to include (omit for all fields) | |
| filter | No | MBQL filter clause | |
| format | No | Output format: csv (default) or json | csv |
| order_by | No | MBQL order-by clause | |
| table_id | Yes | The table ID | |
| database_id | Yes | The database ID |