POST /api/v1/tools/qrcode
{ "input": "https://example.com", "options": { "size": 256 } }Returns raw image/png bytes directly — not the shared JSON envelope. Content-Type: image/png, Content-Disposition: inline; filename="qrcode.png". This is the one deliberate deviation from the envelope, since a JSON-wrapped base64 payload would prevent direct <img src> embedding and complicate downloading.
{ "success": false, "error": { "code": "EMPTY_INPUT", "message": "text must not be empty" } }Error codes: EMPTY_INPUT, INPUT_TOO_LARGE (over ~2900 bytes), QR_ENCODE_FAILED.
flowchart LR
A[Client: CLI / Web / REST] -->|input text, size| B[qrCodeHandler bespoke]
B --> C[qrcode.Generate]
C -->|valid| D[skip2/go-qrcode Encode]
D --> E["image/png bytes (no JSON envelope)"]
C -->|empty/too large| F[apperr.Error 400] --> G[shared JSON error envelope]