manage_charts
Manages embedded charts. action=add builds a chart from chart_type (COLUMN/BAR/LINE/AREA/STEPPED_AREA/SCATTER/PIE), domain_range (x-axis labels / pie labels), series_ranges (one grid range per data series; PIE takes exactly one) and optional title/legend_position/header_count (rows of the ranges ...
This record as markdown: /tools/a1-x-tech-mcp-google-sheets/manage-charts.md
What manage_charts does on Mcp Google Sheets
AI agents use manage_charts to create or update resources in Mcp Google Sheets, usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Mcp Google Sheets environment.
| Parameter | Type | Required | Description |
|---|---|---|---|
spec | object | — | Raw Sheets API ChartSpec — full control; overrides the simplified fields above. |
title | string | — | Chart title. |
action | string | Yes | What to do with the charts. |
anchor | object | — | add: place the chart over the grid, top-left at this cell. |
chart_id | integer | — | update/delete: the chartId from get_spreadsheet or the add reply. |
new_sheet | boolean | — | add: put the chart on its own new chart sheet instead. |
chart_type | string | — | add/update: the chart kind (required unless spec is given). |
domain_range | object | — | The x-axis (or pie label) values, incl. header cell. |
header_count | integer | — | How many leading rows of the ranges are headers (default 1). |
series_ranges | array | — | One range per data series, incl. header cells (PIE: exactly one). |
spreadsheet_id | string | Yes | The spreadsheet id — the long id from the URL (docs.google.com/spreadsheets/d/<spreadsheetId>/edit) or from create_spreadsheet / search_spreadsheets output. |
legend_position | string | — | BOTTOM_LEGEND, LEFT_LEGEND, RIGHT_LEGEND, TOP_LEGEND or NO_LEGEND (default: API's choice). |
Parameters from the server's own tool schema.
Why manage_charts is rated Medium
Creates and modifies chart objects in spreadsheets, reversibly. No data deletion or financial operations.
From the tool's definition Manages embedded charts. action=add builds a chart from chart_type, places it with anchor or new_sheet
Risk signalsHigh parameter count (25 properties)
Attacks that exploit this kind of access
The rule that runs manage_charts safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Mcp Google Sheets, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For manage_charts, this is the rule to start with:
manage_charts stays usable, but capped: an agent stuck in a loop can't make hundreds of changes a minute. Everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Mcp Google Sheets, apply this rule, and every manage_charts call is checked against it from then on.
Questions about manage_charts
Manages embedded charts. action=add builds a chart from chart_type (COLUMN/BAR/LINE/AREA/STEPPED_AREA/SCATTER/PIE), domain_range (x-axis labels / pie labels), series_ranges (one grid range per data series; PIE takes exactly one) and optional title/legend_position/header_count (rows of the ranges treated as headers, default 1) — place it with anchor {sheet_id,row_index,column_index} (the cell under the chart's top-left corner) or new_sheet=true for its own chart sheet; the reply carries the new chartId. Ranges should be single columns (or rows) including the header cell. For chart kinds beyond the basic set (combo, waterfall, histogram, org …) pass a raw Sheets API ChartSpec via spec instead — it overrides the simplified fields. action=update REPLACES the whole spec of an existing chart (chart_id + the same spec-building fields; there is no partial chart update). action=delete removes the chart by chart_id. Find chartIds via get_spreadsheet (sheets[].charts). It is categorised as a Write tool in the Mcp Google Sheets MCP Server, which means it can create or modify data. Consider rate limits to prevent runaway writes.
manage_charts accepts 12 parameters: spec, title, action, anchor, chart_id, new_sheet, chart_type, domain_range, header_count, series_ranges, spreadsheet_id, legend_position. Required: action, spreadsheet_id. The full parameter table on this page comes from the server's own tool schema.
Register the Mcp Google Sheets MCP server in PolicyLayer and add a rule for manage_charts: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Mcp Google Sheets. Nothing to install.
manage_charts is a Write tool with medium risk. Write tools should be rate-limited to prevent accidental bulk modifications.
Yes. Add a rate_limit block to the manage_charts rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for manage_charts. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
manage_charts is provided by the Mcp Google Sheets MCP server (@a1-x-tech/mcp-google-sheets). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Mcp Google Sheets, and thousands of servers like it.
This server
Across the catalogue