Get Kpi
get_kpiExecute a JSON-configured KPI query and return one computed value for dashboard reporting.
Instructions
Execute a KPI query and return a single value.
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": {
"kpi_json": "<kpi_json>"
},
"name": "get_kpi"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| kpi_json | Yes | JSON string with KPI config, e.g.: { "sql": "SELECT COALESCE(SUM(total_usd), 0) AS v FROM sales", "label": "Total Sales", "formato": "money" } |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |