Skip to main content
Glama

UrlChart

Build a chart URL

build_chart_url

Build a well-formed UrlChart chart URL from a small, LLM-friendly chart spec. No render, no network, no key. Returns the URL as text; pass it to generate_chart_image (or embed it) to get the PNG. For chart types or parameters outside this spec, use generate_chart_image with raw legacy parameters.

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": {
      "values": "<values>"
    },
    "name": "build_chart_url"
  }
}

Input Schema

NameRequiredDescriptionDefault
titleNoChart title (chtt).
widthNo
y_maxNoY axis maximum (chxr). Requires y_min.
y_minNoY axis minimum (chxr). Requires y_max.
colorsNoSeries colours as hex (with or without #) or legacy colour names (chco).
heightNo
labelsNoCategory labels (chl): one per value for a single series. Omit for no labels. For scatter, labels are not used.
valuesYesData. For bar/line/pie/doughnut: one series (number[]) or several series (number[][]). For scatter: number[][] where the FIRST row is the x series and each further row a y series.
backgroundNoBackground colour (chf=bg,s,…), hex or legacy name.
chart_typeNoChart family. Default bar (cht=bvg).bar

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/5

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

No annotations exist, so the description carries the burden; it usefully discloses that there is no render, no network call, and no key required, and that the return value is plain text. It stops short of describing validation failures or URL-length limits, but the core behavioral profile is clear.

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

Conciseness4/5

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

Three tight sentences with the capability stated first, then the output/routing guidance, then the fallback case. No filler, though the middle sentence slightly overlaps with the purpose statement.

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

Completeness4/5

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

For a 10-parameter, no-output-schema tool the definition covers what the tool produces (a text URL) and how to consume it downstream, which is the key missing piece. Minor gaps remain around error behavior and constraints on series count.

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 80% and the schema already documents each parameter including chart-encoding hints (chtt, chco, chxr) and the scatter row-ordering rule. The description adds only the general notion of a "small, LLM-friendly chart spec" and no parameter-level meaning beyond what the schema provides.

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

Purpose5/5

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

States a specific verb and resource (build a chart URL from a chart spec) and immediately scopes it as a pure URL builder rather than a renderer, which cleanly separates it from generate_chart_image.

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

Usage Guidelines5/5

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

Explicitly says to pass the returned URL to generate_chart_image (or embed it) to get the PNG, and directs agents to generate_chart_image with raw legacy parameters when the chart type or parameters fall outside this spec.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.