dashboard.get_widget_script
dashboard_get_widget_scriptRetrieves a widget script from a Sisense dashboard export and wraps it for rendering. Provide dashboard and widget IDs to get the script.
Instructions
Build a formatted widget script helper object. Retrieves a dashboard export payload, selects a widget by index/key, and wraps its script content in a :class:SisenseScript helper for downstream rendering.
Returns: SisenseScript | dict[str, str] A :class:SisenseScript instance when the widget is found and has a script. {"error": "..."} when the export fails (including status_code for HTTP failures such as missing …
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": {
"dashboard_id": "<dashboard_id>",
"widget_id": "<widget_id>"
},
"name": "dashboard_get_widget_script"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| widget_id | Yes | The widget identifier or lookup key used in the exported widget mapping. | |
| dashboard_id | Yes | The dashboard identifier to export. |