pbi_execute_query
Run DAX queries against Power BI datasets to retrieve data rows. Supports row-level security impersonation and optional null inclusion.
Instructions
Execute a DAX query against a Power BI dataset and return the result rows.
Uses the Execute Queries REST API (POST executeQueries). Only DAX queries are supported; MDX and DMV are not.
Limitations (enforced by the Power BI service):
One query per call, one table per query.
Max 100,000 rows or 1,000,000 cell values (whichever is hit first).
Max 15 MB per response payload.
120 requests/minute/user rate limit.
Args:
workspace_id: The workspace (group) ID.
dataset_id: The dataset ID.
query: A DAX query string, e.g. EVALUATE SUMMARIZECOLUMNS(...).
impersonated_user: Optional UPN for RLS impersonation (ignored if model has no RLS).
include_nulls: Whether null values are serialised in the response (default True).
Returns: JSON with {rows, row_count} on success, or {error, ...} on failure.
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": {
"workspace_id": "<workspace_id>",
"dataset_id": "<dataset_id>",
"query": "<query>"
},
"name": "pbi_execute_query"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| workspace_id | Yes | ||
| dataset_id | Yes | ||
| query | Yes | ||
| impersonated_user | No | ||
| include_nulls | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |