Create QR code
create_qr_codeCreates a QR code picture for a link or a text, with optional colours, module shapes, border, error correction, a centre logo from an image link and a heart shaped design. Returns permanent links to the PNG and the SVG (no account, no expiry), a download link and a 512 px preview image. Does not create short links or count scans: the code contains exactly the given data.
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": {
"data": "<data>"
},
"name": "create_qr_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| bg | No | Background colour as hex, one of the names listed for fg, or transparent. Default white. | |
| fg | No | Colour of the code as hex, for example #1a2b3c, or one of these names: black, white, red, lime, green, blue, yellow, cyan, aqua, magenta, fuchsia, silver, gray, grey, maroon, olive, purple, teal, navy, orange, pink, gold, eventpics. Other names are not understood. Default black (red for the heart). Keep it dark: light codes on a light background do not scan. | |
| ecl | No | Error correction L, M, Q (default) or H. Higher survives damage and dirt but makes the code denser. The heart always uses H. | |
| data | Yes | The link or text the QR code should contain, for example https://example.com/menu. Pass it as it is, not URL-encoded. Max 1200 characters; shorter content gives a code that is easier to scan. | |
| dots | No | Shape of the small modules. dots: every module a separate circle. square: plain squares. rounded and extra-rounded: neighbouring modules join, outer corners slightly or strongly rounded. classy and classy-rounded: leaf-like, two opposite corners rounded. Default rounded. | |
| eyes | No | Shape of the ring of the three corner markers. dot: one round ring (a circle). dots: a ring made of many small circles. square, rounded, extra-rounded: a square ring with sharp, slightly rounded or strongly rounded corners. Default extra-rounded. | |
| logo | No | Optional https link to a logo image (PNG, JPEG, GIF or SVG, max 1 MB) to place in the centre, for example the company logo of the website the code points to. Use a square logo file, not a banner or a tiny favicon. Error correction is raised to H automatically. Not available for the heart design. If the image cannot be used, the code is created without it and notes say why. | |
| size | No | Width and height in pixels, 100 to 3000. Default 1024 for PNG and 512 for SVG (an SVG scales freely, the number only sets its nominal size). | |
| design | No | standard (default) is a classic square code. heart shapes the whole code like a heart, in red unless fg says otherwise; nice for weddings and invitations. | |
| format | No | png (default) for documents, chats and social media; svg for print and design tools, since it scales without losing sharpness. | |
| margin | No | Empty border around the code, counted in modules (the small squares). Scanners need it to find the code. Default 4; the heart never goes below 2. | |
| eyesInner | No | Shape of the centre of the three corner markers. dot: one round centre. dots: nine small circles. square, rounded, extra-rounded: a square centre with sharp, slightly rounded or strongly rounded corners. Default extra-rounded. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | Permanent link to the picture in the requested format. | |
| size | Yes | ||
| notes | Yes | Values the API adjusted, if any. | |
| design | Yes | ||
| format | Yes | ||
| png_url | Yes | ||
| svg_url | Yes | ||
| download_url | Yes | Same picture, sent as a file download. |