delete_template_measure
Delete a measure from a table in a .pbit template by editing its DataModelSchema JSON directly, without opening Power BI Desktop. Returns an error if the measure does not exist.
Instructions
Delete a measure from a table in a closed .pbit template's model, editing the DataModelSchema JSON on disk with no Power BI Desktop. Fails if the measure does not exist. Written back in place (with a .bak guard).
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": {
"pbitPath": "<pbitPath>",
"table": "<table>",
"name": "<name>"
},
"name": "delete_template_measure"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | measure name | |
| table | Yes | home table of the measure | |
| pbitPath | Yes | path to the closed .pbit template |