Skip to main content
Glama

Generate a QR code as SVG or JSON

qr
Read-only

A QR code for a text of up to 300 characters (a URL, Wi-Fi login or contact card), generated locally. format=svg returns the image itself as image/svg+xml; format=json returns the version, the module count, the SVG and a data URI. Error correction L, M, Q or H (default M); size from 128 to 1024 pixels (default 512). Price: $0.002 per successful call, paid with x402 (USDC on Base, Solana and 10 more networks); failed calls are not charged.

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": {
      "text": "<text>"
    },
    "name": "qr"
  }
}

Input Schema

NameRequiredDescriptionDefault
eccNoL, M, Q or H (default M)
sizeNoPixels, 128 to 1024 (default 512)
textYesUp to 300 characters
formatNosvg (default) or json

Output Schema

NameRequiredDescriptionDefault
eccNo
svgNo
textNo
dataUriNo
modulesNo
versionNo
checkedAtNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "checkedAt": {},
      +    "dataUri": {},
      +    "ecc": {},
      +    "modules": {},
      +    "svg": {},
      +    "text": {},
      +    "version": {}
      +  },
      +  "type": "object"
      +}
  2. Added

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the readOnly/openWorld annotations it discloses several things the agent cannot see elsewhere: generation happens locally, each successful call costs $0.002, failed calls are free, and payment runs through x402 (USDC on Base, Solana and more). That pricing and payment-rail disclosure is exactly the behavioral burden the annotations do not carry.

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

Conciseness5/5

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

Three dense sentences, front-loaded with what is produced, then output modes, then options and cost. No filler and no repetition of the name/title alone.

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

Completeness5/5

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

For a simple 4-parameter generator with an output schema and full schema coverage, everything an agent needs to call it correctly is present: payload limit, defaults, output modes, and the payment/cost model. Return-value detail is partly redundant with the output schema but not harmful.

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

Parameters4/5

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

Schema coverage is already 100%, so the baseline is 3; the description exceeds it by explaining what each format returns (raw image/svg+xml versus version, module count, SVG and data URI) and restating ecc/size defaults. It adds return-shape meaning rather than merely echoing the schema.

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?

States a specific verb+resource: generating a QR code for text up to 300 characters, with concrete examples of payloads (URL, Wi-Fi login, contact card) and the 'generated locally' scope. It does not reference any sibling tool, so an agent must infer on its own that this is not the same as the generic 'image' tool.

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 clear usage context by naming the payload types and spelling out exactly when to pick format=svg versus format=json. There are no explicit exclusions or pointers to alternative tools, which keeps it short of a 5.

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.

Resources