{"openapi":"3.1.0","info":{"title":"NeverDie QR API","version":"1.0.0","description":"QR codes that never expire. No API key. Dynamic codes return a manage token in manageUrl (?t=); it is the only credential for editing and stats. Creation is capped per IP per hour. MCP endpoint: POST /api/mcp."},"servers":[{"url":"https://neverdieqr.com"}],"paths":{"/api/qr":{"get":{"operationId":"renderStaticQr","summary":"Render a static QR code image (never expires, no server lookup at scan time)","parameters":[{"name":"data","in":"query","required":true,"schema":{"type":"string","maxLength":2000}},{"name":"format","in":"query","schema":{"type":"string","enum":["svg","png"],"default":"svg"}},{"name":"fg","in":"query","schema":{"type":"string","pattern":"^#?[0-9a-fA-F]{6}$"}},{"name":"bg","in":"query","schema":{"type":"string","pattern":"^#?[0-9a-fA-F]{6}$"}},{"name":"size","in":"query","description":"PNG width in px, 128-2048","schema":{"type":"integer"}}],"responses":{"200":{"description":"QR image","content":{"image/svg+xml":{},"image/png":{}}}}}},"/api/codes":{"post":{"operationId":"createDynamicQr","summary":"Create an editable dynamic QR code","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["destination"],"properties":{"destination":{"type":"string","format":"uri"},"fallback":{"type":"string","format":"uri","description":"Used while the destination is down"}}}}}},"responses":{"200":{"description":"Created","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string"},"url":{"type":"string","format":"uri"},"manageUrl":{"type":"string","format":"uri"},"imageUrl":{"type":"string","format":"uri"}}}}}},"429":{"description":"Hourly creation cap reached"}}},"patch":{"operationId":"updateDynamicQr","summary":"Change destination and/or fallback; the printed code is unchanged","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["code","token"],"properties":{"code":{"type":"string"},"token":{"type":"string"},"destination":{"type":"string","format":"uri"},"fallback":{"type":"string","description":"Empty string removes the fallback"}}}}}},"responses":{"200":{"description":"Saved"},"404":{"description":"Unknown code or wrong token"}}}},"/api/codes/{code}":{"get":{"operationId":"getQrCode","summary":"Public liveness check, or full stats with the manage token","parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string"}},{"name":"t","in":"query","description":"Manage token (or send Authorization: Bearer)","schema":{"type":"string"}}],"responses":{"200":{"description":"Status or stats"},"404":{"description":"Not found"}}},"post":{"operationId":"checkDestinationNow","summary":"Run a destination health check now (owner only)","parameters":[{"name":"code","in":"path","required":true,"schema":{"type":"string"}},{"name":"t","in":"query","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Health result"}}}}}}