QR code generator (SVG + GIF data URI)
util_qrTurn any text or URL (max 2000 chars, full Unicode) into a QR code. Returns a ready-to-embed SVG string, an SVG data URI and a GIF data URI (works in , Markdown, email HTML), plus QR version and module count. Options: ecc error-correction level L/M/Q/H (default M; H survives a logo over the centre), size in pixels per module (1–20, default 8), margin in modules (default 4), matrix=true adds the raw 0/1 grid. Verified decodable. Use for payment links, wallet addresses, Wi-Fi, tickets, vCards, links on printed material. Price: $0.001 per call (USDC on Base via x402); the first 10 calls per day are free.
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": "util_qr"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ecc | No | Error correction: L, M (default), Q or H | |
| size | No | Pixels per module 1–20 (default 8) | |
| text | Yes | Text or URL to encode (max 2000 characters) | |
| margin | No | Quiet zone in modules 0–10 (default 4) | |
| matrix | No | true to also return the 0/1 module grid |