update_dashboard
Update dashboard properties: name, description, collection, and filter parameters. Archive or unarchive dashboards to control visibility.
Instructions
Update properties of a dashboard, including its parameter/filter list.
Use parameters to define dashboard-level filters. Each parameter is a dict
with keys like id (string, required — a stable identifier), name,
slug, type (e.g. "date/all-options", "date/single", "date/range",
"category", "string/=", "number/="), and optional default, sectionId,
values_source_type, values_source_config.
Args: dashboard_id: The ID of the dashboard to update. name: New name for the dashboard. description: New description for the dashboard. collection_id: Move the dashboard to a different collection. parameters: Full replacement list of dashboard parameters. archived: Set true to archive, false to unarchive.
Returns: The updated dashboard object.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dashboard_id | Yes | ||
| name | No | ||
| description | No | ||
| collection_id | No | ||
| parameters | No | ||
| archived | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- server.py:949-1005 (handler)Tool handler for update_dashboard. Updates properties of a Metabase dashboard including name, description, collection_id, parameters, and archived status via PUT request to /api/dashboard/{dashboard_id}.
@mcp.tool async def update_dashboard( dashboard_id: int, ctx: Context, name: str | None = None, description: str | None = None, collection_id: int | None = None, parameters: list[dict[str, Any]] | None = None, archived: bool | None = None, ) -> dict[str, Any]: """ Update properties of a dashboard, including its parameter/filter list. Use `parameters` to define dashboard-level filters. Each parameter is a dict with keys like `id` (string, required — a stable identifier), `name`, `slug`, `type` (e.g. "date/all-options", "date/single", "date/range", "category", "string/=", "number/="), and optional `default`, `sectionId`, `values_source_type`, `values_source_config`. Args: dashboard_id: The ID of the dashboard to update. name: New name for the dashboard. description: New description for the dashboard. collection_id: Move the dashboard to a different collection. parameters: Full replacement list of dashboard parameters. archived: Set true to archive, false to unarchive. Returns: The updated dashboard object. """ payload: dict[str, Any] = {} if name is not None: payload["name"] = name if description is not None: payload["description"] = description if collection_id is not None: payload["collection_id"] = collection_id if parameters is not None: payload["parameters"] = parameters if archived is not None: payload["archived"] = archived if not payload: raise ToolError("No update fields provided. Specify at least one field to update.") try: await ctx.info(f"Updating dashboard {dashboard_id}") result = await metabase_client.request( "PUT", f"/dashboard/{dashboard_id}", json=payload ) await ctx.info(f"Successfully updated dashboard {dashboard_id}") return result except Exception as e: error_msg = f"Error updating dashboard {dashboard_id}: {e}" await ctx.error(error_msg) raise ToolError(error_msg) from e - server.py:949-950 (registration)The @mcp.tool decorator registers this async function as an MCP tool named 'update_dashboard'.
@mcp.tool async def update_dashboard(