TrackQR API reference
Create and update dynamic QR codes from your own systems, read their scan analytics, and get a signed webhook when a code is scanned. API keys are available on the Growth plan and up.
https://www.track-qr.comAuthentication
Create a key under Dashboard → API keys. Keys start with tqr_. Send it in either header:
Authorization: Bearer tqr_your_key # or X-API-Key: tqr_your_key
Responses are JSON in this shape:
{ "success": true, "data": { ... }, "message": "..." }Example: create a website QR code.
curl -X POST https://www.track-qr.com/api/qr \
-H "Authorization: Bearer tqr_your_key" \
-H "Content-Type: application/json" \
-d '{"title":"Spring flyer","type":"url","content":"https://example.com/spring"}'Rate limits
Each key has an hourly request budget (100 requests per hour unless your key says otherwise). Over the budget you get HTTP 429 with Retry-After, X-RateLimit-Limit and X-RateLimit-Remaining headers.
QR codes
Create, list, update, clone, pin, download and delete your dynamic QR codes.
POST
/api/qrCreate a QR code. The response includes its shortCode and the redirect URL the printed code encodes.JSON body
titlestringrequired — Name shown in your dashboardtypestringrequired — QR code type: url, text, email, wifi, sms, phone, vcard, apps, menu, links, pdf, images, video, mp3, coupon, business, event, location, google_forms, youtube, pinterest, twittercontentstringrequired — Destination URL, or the type's encoded contentsettingsobject — Design: colours, pattern, logo, frame, error correctionmetadataobject — Type-specific data (app store links, vCard fields, menu…)
GET
/api/qrList your QR codes, newest first.Query parameters
pagenumber — Page number (default 1)limitnumber — Items per page (default 10, max 100)typestring — Only this QR code typesearchstring — Search by titlestatusstring — all (default), active or inactivefolderIdstring — Only codes in this foldercampaignIdstring — Only codes in this campaign
- GET
/api/qr/:qrIdGet one QR code. PATCH
/api/qr/:qrIdUpdate a code. Changing content changes where the printed code goes; the code itself stays the same.JSON body
titlestring — New namecontentstring — New destinationsettingsobject — New design settingsmetadataobject — New type-specific dataisActiveboolean — Turn the code on or offfolderIdstring — Move to a folder
- DELETE
/api/qr/:qrIdDelete a code permanently. A printed copy stops working. - POST
/api/qr/:qrId/cloneCopy a code's content and design to a new code with its own shortCode. PATCH
/api/qr/:qrId/pinPin or unpin a code (pinned codes stay editable first when you are over your plan's code limit).JSON body
pinnedbooleanrequired — true to pin, false to unpin
GET
/api/qr/:qrId/downloadDownload the QR code image.Query parameters
formatstring — png (default) or svgsizenumber — Size in pixels (capped by the server)
Analytics
Per code: scans per day, scans per placement and an estimated count of unique IP addresses. Across all your codes: breakdowns by country, city, device, operating system and browser.
GET
/api/qr/:qrId/analyticsAnalytics for one code: totals, scans per day, per placement and per branch.Query parameters
periodstring — 7d, 30d (default), 90d, 1y or all
GET
/api/qr/analytics/overallTotals across all your codes, with country, city, device, OS and browser breakdowns.Query parameters
periodstring — 7d, 30d (default), 90d, 1y or all
Placements
A placement is one printed version of a code (a table, a billboard, a flyer batch). Scans of the version carry its key, so you can compare them. Placement limits depend on your plan.
- GET
/api/qr/:qrId/placementsList a code's placements. - PUT
/api/qr/:qrId/placementsReplace a code's placements with the given list. - POST
/api/qr/:qrId/placements/bulkAdd several placements at once.
Webhooks
Add an HTTPS endpoint under Dashboard → Webhooks and choose events. Each delivery is a JSON POST of { event, timestamp, data } with the headers X-TrackQR-Event, X-TrackQR-Delivery and X-TrackQR-Signature (sha256= + an HMAC-SHA256 of the body with your webhook secret).
qr.scannedA code was scanned (with approximate location, device and browser).qr.createdA code was created.qr.updatedA code was updated.qr.deletedA code was deleted.
// Verify a webhook (Node.js / Bun). rawBody is the exact request body.
import { createHmac, timingSafeEqual } from "node:crypto";
const expected = "sha256=" + createHmac("sha256", WEBHOOK_SECRET).update(rawBody).digest("hex");
const received = request.headers.get("x-trackqr-signature") ?? "";
const valid =
received.length === expected.length &&
timingSafeEqual(Buffer.from(received), Buffer.from(expected));Dashboard-only features
API keys cover the endpoints above. Campaigns, AI flyers, folders, templates, landing pages, events, webhook settings, team and billing are managed in the dashboard.