get_facets
Retrieve facet values and record counts for a dataset's filterable fields to build accurate where/refine filters before querying records.
Instructions
Get facet values and their record counts for a dataset's filterable fields. Call this before query_records to discover valid values for where/refine filters instead of guessing.
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": {
"datasetId": "<datasetId>"
},
"name": "get_facets"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| where | No | ODSQL boolean expression to narrow facet counts | |
| refine | No | Repeatable facet filters, each formatted as "field:value" | |
| datasetId | Yes | The dataset_id, e.g. "greenest-city-projects" |