Go to Dashboard → API Tokens and create a new token
Include token in Authorization header as Bearer token
Start generating codes using the API endpoints
All API requests require authentication using a Personal Access Token (PAT). Include your token in the Authorization header:
Authorization: Bearer qre_your_token_here💡 Tokens start with qre_ prefix. Keep your tokens secure and never expose them in client-side code.
https://api.qrengine.siteAll endpoints are relative to this base URL.
curl -X POST https://api.qrengine.site/api/codes/generate \
-H "Authorization: Bearer qre_your_token" \
-H "Content-Type: application/json" \
-d '{
"type": "qr",
"data": "https://example.com",
"name": "My Website QR",
"customization": {
"color": "#8B5CF6",
"size": 400
}
}'/api/codes/generateAuth RequiredGenerate a new QR code or barcode
{
"type": "qr", // "qr" or "barcode"
"data": "https://example.com",
"name": "My Code", // optional
"barcodeFormat": "CODE128", // required for barcode
"format": "png", // "png" or "svg" (QR only)
"saveToLibrary": true, // optional
"customization": { // optional
"color": "#000000",
"backgroundColor": "#FFFFFF",
"size": 300,
"errorCorrection": "M" // L, M, Q, H (QR only)
}
}{
"success": true,
"data": {
"id": "abc123",
"imageBase64": "data:image/png;base64,..."
}
}/api/codesAuth RequiredGet all your saved codes
type (optional): "qr" | "barcode" limit (optional): number offset (optional): number
{
"success": true,
"data": {
"codes": [...],
"total": 10
}
}/api/codes/:idAuth RequiredGet a specific code by ID
{
"success": true,
"data": {
"id": "abc123",
"name": "My Code",
"type": "qr",
"data": "https://example.com",
"imageBase64": "...",
"scans": 42,
"createdAt": "2024-01-01T00:00:00Z"
}
}/api/codes/:idAuth RequiredUpdate a code (name, data, or active status)
{
"name": "Updated Name", // optional
"data": "new data", // optional - regenerates code
"isActive": true // optional
}{
"success": true,
"data": { ... }
}/api/codes/:idAuth RequiredDelete a code
{
"success": true,
"message": "Code deleted"
}/api/tokensAuth RequiredCreate a new API token
{
"name": "Production API"
}{
"success": true,
"data": {
"token": "qre_xxxx...", // Only shown once!
"name": "Production API"
}
}/api/tokensAuth RequiredList all your API tokens
{
"success": true,
"data": {
"tokens": [
{ "name": "...", "createdAt": "...", "lastUsed": "..." }
]
}
}/api/tokens/:nameAuth RequiredRevoke a specific token
{
"success": true,
"message": "Token revoked"
}| Plan | Codes | API Calls/Day |
|---|---|---|
| Free | 5 | 100 |
| Pro | 50 | 5,000 |
| Enterprise | Unlimited | Unlimited |