API النطاق - API تسجيل النطاق - API مسجل ICANN - خدمة النطاق بالعلامة البيضاء

ابدأ البناء مع NiceNIC Domain API v2

الوصول إلى API مجاني لكل مستخدم NiceNIC نشط. لا حاجة للترقية إلى حساب موزع. قم بإعداد بيانات اعتماد API الخاصة بك، وأرسل طلب اختبار آمن، ثم أضف سير عمل المجال، وDNS، والفوترة، والامتثال، أو WHMCS التي يحتاجها تطبيقك.

Setting Auto-Renew

Enable or disable auto-renewal for up to 100 domains. New plans renew for one year at a time.

Content-Type application/json
الفئة domain
action set_auto_renew

معاملات الطلب

اسم المعامل النوع الوصف مثال
domain سلسلة نصية Required. Provide one domain or a comma-separated list of up to 100 domains. example.com,example.net
auto_renew عدد صحيح Required. 1 enables and 0 disables auto-renewal for all entries. 1

معلمات الاستجابة

اسم المعامل النوع الوصف
results Object[] Each result has domain, code, and msg.
A code of 0 also returns the Boolean auto_renew status.
success_count عدد صحيح Number of successful entries, including settings already in effect.
fail_count عدد صحيح Number of entries that failed validation or could not be saved.

مثال على الطلب

                                    
{
    curl -g -X POST 'https://api.nicenic.net/v2/?category=domain&action=set_auto_renew&domain={domain}&auto_renew=1'
      -H "Authorization: username:api_secret"
      -H "Content-Type: application/json"
}

نتيجة الإرجاع

0 OK استجابة ناجحة
                                        
{
    "code": 0,
    "msg" : "success",
    "data" : {
        "results" : [
            {
                "domain" : "example.com",
                "code" : 0,
                "msg" : "success",
                "auto_renew" : true
            },
            {
                "domain" : "example.net",
                "code" : 404,
                "msg" : "Domain not found"
            }
        ],
        "success_count" : 1,
        "fail_count" : 1        
    }
}
400 طلب غير صالح
                                        
{
    "code": 400,
    "msg" : "Request parameter error",
    "data" : []
}
حقوق النشر © 2006–2026 NICENIC INTERNATIONAL GROUP CO., LIMITED. جميع الحقوق محفوظة.