curl -X PATCH "https://api.scanova.io/custom-domain/42/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"root_action": "url_redirect",
"redirect": "https://example.com/landing"
}'
{
"id": 42,
"domain": "https://links.example.com",
"is_default": false,
"disable_slug_case": false,
"txt_value": "scanova-verification=abc123...",
"is_txt_verified": true,
"is_cname_verified": true,
"is_migrated": false,
"dns_provider": { "name": "Cloudflare", "placeholders": { "cname": { "content": { "label": "Target" } } } },
"txt_error": null,
"cname_error": null,
"root_action": "url_redirect",
"redirect": "https://example.com/landing",
"template": null,
"protocol": "https",
"remove_qr_query": false,
"cname_target": "shortcname.scanova.io",
"domain_connect_supported": false,
"domain_connect_checked_at": null,
"created": "2026-09-08T10:00:00Z",
"modified": "2026-09-08T10:00:00Z"
}
النطاقات المخصصة
تحديث نطاق مخصص
PATCH /custom-domain//
PATCH
/
custom-domain
/
{pk}
/
curl -X PATCH "https://api.scanova.io/custom-domain/42/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"root_action": "url_redirect",
"redirect": "https://example.com/landing"
}'
{
"id": 42,
"domain": "https://links.example.com",
"is_default": false,
"disable_slug_case": false,
"txt_value": "scanova-verification=abc123...",
"is_txt_verified": true,
"is_cname_verified": true,
"is_migrated": false,
"dns_provider": { "name": "Cloudflare", "placeholders": { "cname": { "content": { "label": "Target" } } } },
"txt_error": null,
"cname_error": null,
"root_action": "url_redirect",
"redirect": "https://example.com/landing",
"template": null,
"protocol": "https",
"remove_qr_query": false,
"cname_target": "shortcname.scanova.io",
"domain_connect_supported": false,
"domain_connect_checked_at": null,
"created": "2026-09-08T10:00:00Z",
"modified": "2026-09-08T10:00:00Z"
}
يحدّث إعدادات نطاق مخصص، على مضيف Management API (
api.scanova.io)، مع المصادقة باستخدام مفتاح Management API الخام الخاص بك.
PUT https://api.scanova.io/custom-domain/{pk}/
PATCH https://api.scanova.io/custom-domain/{pk}/
Authorization: 401f7ac837da42b97f613d789819ff93537bee6a
integer
مطلوب
معرّف
id الخاص بالنطاق.boolean
ما إذا كانت رموز QR الجديدة تستخدم هذا النطاق افتراضيًا.
string
ما يجب فعله عندما يزور شخص ما النطاق المجرد (بدون slug رمز QR):
no_action (الافتراضي)، أو url_redirect، أو custom_page.string
عنوان URL الذي يُرسَل إليه الزوار عندما تكون
root_action هي url_redirect.integer
معرّف
CustomDomainTemplate يُستخدم كصفحة جذرية عندما تكون root_action هي custom_page — راجع سرد قوالب الصفحة الجذرية للنطاق المخصص.string
none أو http أو https. القيمة الفارغة تُعامَل كـ https افتراضيًا.boolean
يحذف معلمة التتبع
?qr=1 من عناوين URL للروابط القصيرة عند تفعيله.curl -X PATCH "https://api.scanova.io/custom-domain/42/" \
-H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a" \
-H "Content-Type: application/json" \
-d '{
"root_action": "url_redirect",
"redirect": "https://example.com/landing"
}'
{
"id": 42,
"domain": "https://links.example.com",
"is_default": false,
"disable_slug_case": false,
"txt_value": "scanova-verification=abc123...",
"is_txt_verified": true,
"is_cname_verified": true,
"is_migrated": false,
"dns_provider": { "name": "Cloudflare", "placeholders": { "cname": { "content": { "label": "Target" } } } },
"txt_error": null,
"cname_error": null,
"root_action": "url_redirect",
"redirect": "https://example.com/landing",
"template": null,
"protocol": "https",
"remove_qr_query": false,
"cname_target": "shortcname.scanova.io",
"domain_connect_supported": false,
"domain_connect_checked_at": null,
"created": "2026-09-08T10:00:00Z",
"modified": "2026-09-08T10:00:00Z"
}
معظم الحقول للقراءة فقط هنا
يمكن الكتابة عبر نقطة النهاية هذه فقط فيis_default وroot_action وredirect وtemplate وprotocol وremove_qr_query — بينما تظل جميع الحقول الأخرى، بما في ذلك domain نفسه، للقراءة فقط بعد إنشاء النطاق. يُعاد 404 إذا لم يكن pk نطاقًا مملوكًا لهذا الحساب.
ذات صلة
- الحصول على نطاق مخصص — الاطلاع عليه قبل التحديث.
- سرد قوالب الصفحة الجذرية للنطاق المخصص — العثور على معرّف
templateلـcustom_page. - نظرة عامة على 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.
معلمات المسار
الاستجابة
Domain updated.
هل كانت هذه الصفحة مفيدة؟