Skip to main content
Glama
suthio

Redash MCP Server

by suthio

update_dashboard

Update a Redash dashboard by modifying its name, tags, archive status, draft status, or filter settings.

Instructions

Update an existing dashboard in Redash

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dashboardIdYesID of the dashboard to update
nameNoNew name of the dashboard
tagsNoTags for the dashboard
is_archivedNoWhether the dashboard is archived
is_draftNoWhether the dashboard is a draft
dashboard_filters_enabledNoWhether dashboard filters are enabled

Implementation Reference

  • The main handler function for the 'update_dashboard' MCP tool. It parses the incoming parameters (dashboardId and optional fields), builds an UpdateDashboardRequest object with only the fields that are provided, calls redashClient.updateDashboard(), and returns the result or an error.
    async function updateDashboard(params: z.infer<typeof updateDashboardSchema>) {
      try {
        const { dashboardId, ...updateData } = params;
        const dashboardData: UpdateDashboardRequest = {};
        if (updateData.name !== undefined) dashboardData.name = updateData.name;
        if (updateData.tags !== undefined) dashboardData.tags = updateData.tags;
        if (updateData.is_archived !== undefined) dashboardData.is_archived = updateData.is_archived;
        if (updateData.is_draft !== undefined) dashboardData.is_draft = updateData.is_draft;
        if (updateData.dashboard_filters_enabled !== undefined) dashboardData.dashboard_filters_enabled = updateData.dashboard_filters_enabled;
    
        const result = await redashClient.updateDashboard(dashboardId, dashboardData);
        return {
          content: [{ type: "text", text: JSON.stringify(result, null, 2) }]
        };
      } catch (error) {
        logger.error(`Error updating dashboard ${params.dashboardId}: ${error}`);
        return {
          isError: true,
          content: [{ type: "text", text: `Error updating dashboard ${params.dashboardId}: ${error instanceof Error ? error.message : String(error)}` }]
        };
      }
    }
  • Zod schema for validating input parameters to the 'update_dashboard' tool. Defines dashboardId (required), and optional fields: name, tags, is_archived, is_draft, dashboard_filters_enabled.
    const updateDashboardSchema = z.object({
      dashboardId: z.coerce.number(),
      name: z.string().optional(),
      tags: z.array(z.string()).optional(),
      is_archived: z.boolean().optional(),
      is_draft: z.boolean().optional(),
      dashboard_filters_enabled: z.boolean().optional()
    });
  • src/index.ts:1836-1851 (registration)
    Registration of the 'update_dashboard' tool in the ListToolsRequestSchema handler, defining the tool name, description, and input JSON schema for the MCP protocol.
    {
      name: "update_dashboard",
      description: "Update an existing dashboard in Redash",
      inputSchema: {
        type: "object",
        properties: {
          dashboardId: { type: "number", description: "ID of the dashboard to update" },
          name: { type: "string", description: "New name of the dashboard" },
          tags: { type: "array", items: { type: "string" }, description: "Tags for the dashboard" },
          is_archived: { type: "boolean", description: "Whether the dashboard is archived" },
          is_draft: { type: "boolean", description: "Whether the dashboard is a draft" },
          dashboard_filters_enabled: { type: "boolean", description: "Whether dashboard filters are enabled" }
        },
        required: ["dashboardId"]
      }
    },
  • src/index.ts:2402-2404 (registration)
    Registration of the 'update_dashboard' case in the CallToolRequestSchema switch statement, which routes incoming tool calls to the updateDashboard handler.
    case "update_dashboard":
      logger.debug(`Handling update_dashboard`);
      return await updateDashboard(updateDashboardSchema.parse(args));
  • Client-side helper method that makes the actual HTTP POST request to the Redash API to update a dashboard. Called by the handler function.
    // Update an existing dashboard
    async updateDashboard(dashboardId: number, data: UpdateDashboardRequest): Promise<RedashDashboard> {
      try {
        const response = await this.client.post(`/api/dashboards/${dashboardId}`, data);
        return response.data;
      } catch (error) {
        logger.error(`Error updating dashboard ${dashboardId}: ${error}`);
        throw new Error(`Failed to update dashboard ${dashboardId}: ${error instanceof Error ? error.message : String(error)}`);
      }
    }
  • TypeScript interface defining the shape of the UpdateDashboardRequest payload sent to the Redash API.
    export interface UpdateDashboardRequest {
      name?: string;
      tags?: string[];
      is_archived?: boolean;
      is_draft?: boolean;
      dashboard_filters_enabled?: boolean;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden for behavioral traits. It only states 'update', implying mutation, but omits details about side effects, permissions required, reversibility, or any consequences of the update.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence, which is concise but lacks structure. It could include more context (e.g., that updates are partial or full) without becoming verbose, achieving a middle ground.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 6 parameters, no output schema, and no annotations, the description fails to explain the return value (e.g., updated dashboard object), prerequisites, or the scope of the update. It is incomplete for effective tool selection.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the input schema already documents all parameters. The description adds no additional meaning beyond the schema, meeting the baseline expectation for high coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Update' and resource 'existing dashboard'. It specifies the tool's purpose but does not differentiate it from sibling tools like archive_dashboard or fork_dashboard, which also modify dashboards in specific ways.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives such as archive_dashboard (for archival) or create_dashboard (for new ones). The description lacks any context about appropriate scenarios or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/suthio/redash-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server