QRMint API Documentation
Generate styled QR codes with custom colors, logos, and professional frames. The API is completely free and open — no API keys, no authentication required. Perfect for marketing materials, product packaging, event tickets, and digital campaigns.
https://qrmint.dev/api/v1
Authentication
No authentication is required. The API is free and open for everyone. Simply make HTTP POST requests to the /generate or /batch endpoints with JSON body.
GET /generate
Generate a QR code via URL parameters. Perfect for embedding directly in HTML <img> tags. Responses are cached for 1 hour.
Query Parameters
| Param | Type | Required | Description |
|---|---|---|---|
data |
string | required | Data to encode (URL-encoded) |
foreground |
string | optional | Foreground color (6-char hex without #). Default: 000000 |
background |
string | optional | Background color (6-char hex without #). Default: ffffff |
size |
number | optional | Size in pixels (64-2048). Default: 512 |
errorCorrectionLevel |
string | optional | L, M, Q, or H. Default: M |
format |
string | optional | png or svg. Default: png |
frameId |
string | optional | Frame template ID. See Frames |
HTML Embed Example
<img src="https://qrmint.dev/api/v1/generate?data=https://example.com" alt="QR Code" /> <!-- With custom styling --> <img src="https://qrmint.dev/api/v1/generate?data=https://example.com&foreground=ff00aa&background=0a0a0f&size=512&frameId=scan-me" alt="Styled QR Code" />
POST /generate
Generate a single styled QR code with custom colors, logo, and optional frame. Returns a PNG or SVG image.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
data |
string | required | Data to encode (URL, text, contact info, etc.) |
foreground |
string | optional | Foreground color (hex). Default: #000000 |
background |
string | optional | Background color (hex). Default: #ffffff |
size |
number | optional | Size in pixels (64-2048). Default: 512 |
margin |
number | optional | Margin in modules (0-10). Default: 4 |
errorCorrectionLevel |
string | optional | Error correction: L, M, Q, or H. Default: M |
logo |
string | optional | Base64 encoded logo image (PNG, JPG, SVG) |
logoSize |
number | optional | Logo size percentage (1-30). Default: 20 |
format |
string | optional | Output format: png or svg. Default: png |
frameId |
string | optional | Frame template ID. See Frame Templates |
Example Request
curl -X POST "https://qrmint.dev/api/v1/generate" \
-H "Content-Type: application/json" \
-d '{
"data": "https://example.com",
"foreground": "#ff00aa",
"background": "#0a0a0f",
"size": 512,
"errorCorrectionLevel": "H",
"frameId": "scan-me"
}' \
--output qrcode.pngResponse
Returns image binary data (PNG or SVG) with appropriate Content-Type header.
POST /batch
Generate multiple QR codes in a single request. Returns a ZIP archive containing all generated images. Maximum 500 items per batch.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
items |
array | required | Array of QR code configurations (max 500) |
items[].data |
string | required | Data to encode in this QR code |
items[].filename |
string | required | Filename for this QR code in the ZIP (e.g., qr1.png) |
All parameters from /generate endpoint are also supported per item
|
|||
Example Request
curl -X POST "https://qrmint.dev/api/v1/batch" \
-H "Content-Type: application/json" \
-d '{
"items": [
{
"data": "https://example.com/product1",
"filename": "product1.png",
"frameId": "scan-me"
},
{
"data": "https://example.com/product2",
"filename": "product2.png",
"foreground": "#ff0000"
}
]
}' \
--output qrcodes.zipResponse
Returns a ZIP archive (application/zip) containing all generated QR codes. If any items fail, an errors.txt file is included in the archive.
GET /frames
List all available frame templates.
Example Request
curl "https://qrmint.dev/api/v1/frames"
Example Response
{
"status": "success",
"data": {
"frames": [
{
"id": "scan-me",
"name": "Scan Me",
"description": "Classic 'Scan Me' call-to-action frame"
},
...
],
"count": 6
}
}Parameters Reference
Error Correction Levels
| Level | Recovery Capacity | Use Case |
|---|---|---|
L | ~7% | Clean environments |
M | ~15% | Standard usage (default) |
Q | ~25% | Industrial environments |
H | ~30% | High risk of damage/dirt |
Color Formats
All color parameters accept hex format (#RRGGBB or #RGB). Examples:
#000000- Black#ffffff- White#ff00aa- Neon pink (cyberpunk)#00f0ff- Electric cyan
Frame Templates
QRMint includes 6 professional frame templates to enhance your QR codes:
| Frame ID | Name | Description |
|---|---|---|
scan-me | Scan Me | Classic "SCAN ME" call-to-action |
menu | Menu | Restaurant menu frame with "VIEW OUR MENU" |
wifi | WiFi | WiFi connection frame with icon |
payment | Payment | Payment/checkout frame "PAY HERE" |
social-instagram | Instagram profile frame "FOLLOW US" | |
social-linkedin | LinkedIn profile frame "CONNECT" |
Note: Frames are only supported for PNG format. If you request a frame with SVG format, the frame will not be applied.
Error Codes
| Status | Meaning |
|---|---|
400 | Bad Request — Missing required field (data) or invalid parameter values |
404 | Not Found — Endpoint does not exist |
429 | Too Many Requests — Rate limit exceeded (30 req/min) |
500 | Internal Server Error — QR generation failed |
Error Response Format
{
"error": "Validation error",
"message": "\"data\" field is required"
}Rate Limits
The API applies rate limiting to protect service quality:
| Limit | Value |
|---|---|
| Requests per minute | 30 per IP address |
| Window | 60 seconds sliding window |
When rate limited, the API returns a 429 status with a Retry-After header.
RateLimit-Limit, RateLimit-Remaining, RateLimit-Reset.
cURL Examples
Basic QR Code
curl -X POST "https://qrmint.dev/api/v1/generate" \
-H "Content-Type: application/json" \
-d '{"data": "https://example.com"}' \
--output qrcode.pngStyled with Frame
curl -X POST "https://qrmint.dev/api/v1/generate" \
-H "Content-Type: application/json" \
-d '{
"data": "https://example.com",
"foreground": "#ff00aa",
"background": "#0a0a0f",
"size": 1024,
"errorCorrectionLevel": "H",
"frameId": "scan-me"
}' \
--output qrcode.pngJavaScript Examples
Browser Usage
// Generate QR code and display in <img> tag
const response = await fetch('https://qrmint.dev/api/v1/generate', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
data: 'https://example.com',
foreground: '#ff00aa',
background: '#0a0a0f',
size: 512,
frameId: 'scan-me'
})
});
const blob = await response.blob();
const url = URL.createObjectURL(blob);
document.getElementById('qr-image').src = url;Node.js with File Save
const fs = require('fs');
const fetch = require('node-fetch');
const response = await fetch('https://qrmint.dev/api/v1/generate', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
data: 'https://example.com',
size: 1024,
errorCorrectionLevel: 'H'
})
});
const buffer = await response.buffer();
fs.writeFileSync('qrcode.png', buffer);Python Examples
Basic Generation
import requests
response = requests.post(
'https://qrmint.dev/api/v1/generate',
json={
'data': 'https://example.com',
'foreground': '#ff00aa',
'background': '#0a0a0f',
'size': 512,
'errorCorrectionLevel': 'H',
'frameId': 'scan-me'
}
)
with open('qrcode.png', 'wb') as f:
f.write(response.content)Batch Generation
import requests
# Generate multiple QR codes
response = requests.post(
'https://qrmint.dev/api/v1/batch',
json={
'items': [
{
'data': 'https://example.com/product1',
'filename': 'product1.png',
'frameId': 'scan-me'
},
{
'data': 'https://example.com/product2',
'filename': 'product2.png',
'foreground': '#00ff00'
}
]
}
)
# Save ZIP archive
with open('qrcodes.zip', 'wb') as f:
f.write(response.content)