Skip to main content
Glama

URLinks

get_qr_image

Read-only

Generate a QR code image (SVG or PNG) for a shortlink. The QR encodes the urlinks.me redirect URL (NOT the bare destination) so scans count as clicks: my/foo → urlinks.me/{alias}/foo, yt/foo → urlinks.me/yt/foo. Personal (my/) shortlinks therefore require the user to have an alias set — call get_alias to check, create_alias to set one. Renders the link's saved QR Studio styling (dot/corner shapes, colors, gradient, logo) with the same engine as the dashboard, so the image is identical to what QR Studio shows. Override colors with fg/bg if needed.

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": {
      "shortlink": "<shortlink>"
    },
    "name": "get_qr_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
bgNoBackground color as hex (overrides saved config)
ecNoError correction level (default: M)
fgNoForeground color as hex (overrides saved config)
sizeNoBox size in pixels per module (1-40, default: 10)
formatNoImage format (default: svg)
shortlinkYesThe shortlink to generate a QR code for (e.g., 'my/docs')

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

With readOnlyHint=true already covering safety, the description still adds valuable behavior: the encoded URL is the redirect (so scans count as clicks), saved QR Studio styling is applied via the same engine as the dashboard, and fg/bg can override it. It does not describe the return payload shape (raw SVG string, data URI, or URL), which is the main remaining unknown.

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?

Front-loads purpose and the non-obvious URL-encoding rule before prerequisites and styling behavior. The alias mapping examples earn their space by disambiguating my/ handling, though the paragraph is denser than strictly necessary.

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?

Covers the tricky domain rule (redirect URL, alias prerequisite) and styling behavior well for a tool with no output schema. The one real gap is that with no output schema, the description should say what the agent receives back from an image-generation call.

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 coverage is 100%, including enum values and defaults for format, ec, and size, so the schema carries parameter meaning. The description only adds that fg/bg override the saved config, which the schema already states. Baseline 3 is appropriate.

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 concrete verb and resource ("Generate a QR code image (SVG or PNG) for a shortlink") and immediately clarifies the non-obvious semantic that the QR encodes the urlinks.me redirect URL rather than the destination. This distinguishes it clearly from siblings like get_qr_config, save_qr_config, and apply_qr_template.

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

Usage Guidelines4/5

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

Gives an explicit prerequisite path: personal (my/) shortlinks require an alias, so call get_alias to check and create_alias to set one. That is real when-to-use routing with named siblings. It stops short of saying how it relates to styling siblings (save_qr_config/apply_qr_template) when the user wants to change the design first.

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.