Generate a QR code as SVG or JSON
qrA 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
| Name | Required | Description | Default |
|---|---|---|---|
| ecc | No | L, M, Q or H (default M) | |
| size | No | Pixels, 128 to 1024 (default 512) | |
| text | Yes | Up to 300 characters | |
| format | No | svg (default) or json |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ecc | No | ||
| svg | No | ||
| text | No | ||
| dataUri | No | ||
| modules | No | ||
| version | No | ||
| checkedAt | No |