curl -X POST "https://api.scanova.io/qr-assets/template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"name": "Summer Poster",
"template_type": "P",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "data:image/png;base64,iVBORw0KGgo..."
}'
{
"id": 12,
"name": "Summer Poster",
"template_id": "a1b2c3d4e5f6",
"template_type": "P",
"template_type_display": "Poster",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "https://cdn.scanova.io/upload/images/42/template-foo.png"
}
QR-Assets
QR-Code-Designvorlage erstellen
POST /qr-assets/template/
POST
/
qr-assets
/
template
/
curl -X POST "https://api.scanova.io/qr-assets/template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"name": "Summer Poster",
"template_type": "P",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "data:image/png;base64,iVBORw0KGgo..."
}'
{
"id": 12,
"name": "Summer Poster",
"template_id": "a1b2c3d4e5f6",
"template_type": "P",
"template_type_display": "Poster",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "https://cdn.scanova.io/upload/images/42/template-foo.png"
}
Speichert eine neue QR-Designvorlage, auf dem Management-API-Host (
api.scanova.io), authentifiziert mit Ihrem rohen Management-API-Schlüssel.
POST https://api.scanova.io/qr-assets/template/
Authorization: 401f7ac837da42b97f613d789819ff93537bee6a
string
erforderlich
Vorlagenname, max. 150 Zeichen.
string
Standard:"N"
"P" (Poster) oder "N" (Normal). Nur bei Erstellung setzbar — siehe Hinweis unten.string
Design-Musterdaten, typischerweise als JSON-String kodiert (Punktstil, Augenform, Farben, Logo).
string
Ein Base64-kodiertes Bild, oder weglassen, um nur Musterdaten zu speichern.
curl -X POST "https://api.scanova.io/qr-assets/template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"name": "Summer Poster",
"template_type": "P",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "data:image/png;base64,iVBORw0KGgo..."
}'
{
"id": 12,
"name": "Summer Poster",
"template_id": "a1b2c3d4e5f6",
"template_type": "P",
"template_type_display": "Poster",
"pattern_info": "{\"dotStyle\":\"round\"}",
"image": "https://cdn.scanova.io/upload/images/42/template-foo.png"
}
template_id wird serverseitig generiert und ist eindeutig — Sie legen ihn nie selbst fest. 403, wenn dem Konto die Quota SAVE_DESIGN_TEMPLATE fehlt, der Plan inaktiv ist oder die Berechtigung QR_CODE_CAN_ADD/QR_CODE_CAN_EDIT fehlt (relevant für geteilte Nutzer mit eingeschränkten Rollen).
Verwandte Themen
- QR-Code-Designvorlagen auflisten — gespeicherte Vorlagen ansehen.
- QR-Code-Designvorlage aktualisieren — eine bestehende bearbeiten;
template_typekann hier nicht geändert werden. - Übersicht über die Management API — das Authentifizierungsschema und die Quota-Regeln für diesen Endpunkt.
Autorisierungen
Send your Management API key as the raw value of the Authorization header — no "Bearer " or "Token " prefix, and no other characters. Example: Authorization: 401f7ac837da42b97f613d789819ff93537bee6a. A header containing more than one space-separated part is rejected outright. Requests also require the request's Host header to be the management API host (e.g. api.scanova.io) — the same key sent to the regular API host will not authenticate.
Antwort
Template created.
War diese Seite hilfreich?