curl -X POST "https://api.scanova.io/qr-assets/conditional-redirect-template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
]
}'
{
"id": 3,
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
],
"created": "2026-09-01T09:00:00Z",
"modified": "2026-09-01T09:00:00Z"
}
أصول QR
إنشاء قالب إعادة توجيه شرطي
POST /qr-assets/conditional-redirect-template/
POST
/
qr-assets
/
conditional-redirect-template
/
curl -X POST "https://api.scanova.io/qr-assets/conditional-redirect-template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
]
}'
{
"id": 3,
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
],
"created": "2026-09-01T09:00:00Z",
"modified": "2026-09-01T09:00:00Z"
}
يحفظ قالب إعادة توجيه شرطي جديدًا، على مضيف Management API (
حفظ قالب لا يُلحقه تلقائيًا بأي رمز QR — طبّقه بشكل منفصل على تهيئة إعادة التوجيه الشرطي لرمز QR ما.
api.scanova.io)، مع المصادقة باستخدام مفتاح Management API الخام الخاص بك.
POST https://api.scanova.io/qr-assets/conditional-redirect-template/
Authorization: 401f7ac837da42b97f613d789819ff93537bee6a
string
مطلوب
اسم القالب، بحد أقصى 100 حرف.
array
مطلوب
مصفوفة من مجموعات الشروط. تحتوي كل مجموعة على عامل منطقي
logic (AND/OR)، ومصفوفة conditions من فحوصات {field, operator, value}، وredirect_url لإرسال عمليات المسح المطابقة إليها.curl -X POST "https://api.scanova.io/qr-assets/conditional-redirect-template/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
]
}'
{
"id": 3,
"template_name": "Location-based redirect",
"data": [
{
"logic": "AND",
"conditions": [{ "field": "country", "operator": "eq", "value": "US" }],
"redirect_url": "https://example.com/us"
}
],
"created": "2026-09-01T09:00:00Z",
"modified": "2026-09-01T09:00:00Z"
}
ذات صلة
- سرد قوالب إعادة التوجيه الشرطي — الاطلاع على القوالب المحفوظة.
- تحديث قالب إعادة توجيه شرطي — تعديل قالب موجود.
- نظرة عامة على Management API — مخطط المصادقة وقواعد الحصة المطبّقة على نقطة النهاية هذه.
التفويضات
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.
الاستجابة
201 - application/json
Template created.
هل كانت هذه الصفحة مفيدة؟