Alan Adı Uzantıları
Sattığınız alan adı uzantılarını, fiyatlarını ve kayıt belgelerini yöneten on uç.
Genel Bakış
Bu uçlar sattığınız alan adı uzantılarını yönetir: hangi uzantılar açık, hangi tescil kuruluşuna bağlı, ne kadara satılıyor ve kayıt sırasında hangi belgeler isteniyor.
Uzantı adres içinde kendi adıyla geçer, kimlikle değil. Fiyat tablosu üç kademelidir: önce işlem tipi, sonra yıl, sonra para birimi. Aynı uzantı beş yıllık kayıtta farklı, tek yıllık yenilemede farklı fiyatlanabilir.
Referans
Uzantıları Listeleme
Kurulumdaki alan adı uzantılarını döndürür.
active ya da inactive.none; o hâlde kayıt otomatik yapılamaz.curl -G 'https://panel.ornek.com/api/v1/admin/products/domain/tlds' \
-H "Authorization: Bearer $API_KEY" \
-d limit=100const url = new URL('https://panel.ornek.com/api/v1/admin/products/domain/tlds');
url.searchParams.set('limit', '100');
const res = await fetch(url, { headers: { Authorization: `Bearer ${apiKey}` } });
const body = await res.json();$url = 'https://panel.ornek.com/api/v1/admin/products/domain/tlds?' . http_build_query(['limit' => 100]);
$ch = curl_init($url);
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->GetDomainTlds([], ['limit' => 100]);Uzantı Detayı
Tek bir uzantıyı maliyetleri ve tüm fiyat tablosuyla döndürür.
active ya da inactive.amount, status, promotion ve promotion_status taşır.curl 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/com' \
-H "Authorization: Bearer $API_KEY"const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com', {
headers: { Authorization: `Bearer ${apiKey}` },
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->GetDomainTld(['tld' => 'com']);
// Fiyat tablosu uc kademelidir: tip, yil, para birimi.
$oneYear = $response['data']['pricing']['register']['1']['USD']['amount'] ?? null;{
"data": {
"id": 3,
"extension": "com",
"status": "active",
"module": "Enom",
"auto_pricing": false,
"features": {
"dns_manage": true,
"forwarding": false,
"whois_privacy": true,
"epp_code": true
},
"min_years": 1,
"max_years": 10,
"register_cost": 8.5,
"renewal_cost": 9,
"transfer_cost": 8.5,
"pricing": {
"register": {
"1": {
"USD": {
"amount": 12,
"status": true,
"promotion": 0,
"promotion_status": false
}
}
}
}
}
}Uzantı Ekleme
Yeni bir uzantı ekler. İsterseniz başlangıç fiyatlarını ve logoyu aynı istekte verirsiniz.
active ya da inactive.{register, transfer, renewal} nesnesine eşleme. Burada yıl kırılımı yoktur; ayrıntılı tablo fiyatlama ucundan girilir.pricing boş döner.extension boş.curl -X POST 'https://panel.ornek.com/api/v1/admin/products/domain/tlds' \
-H "Authorization: Bearer $API_KEY" \
-H 'Content-Type: application/json' \
-d '{"extension":"com","registrar":"Enom","status":"active","features":{"dns_manage":true,"whois_privacy":true},"pricing":{"USD":{"register":12,"transfer":12,"renewal":14}}}'const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds', {
method: 'POST',
headers: {
Authorization: `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
extension: 'com',
registrar: 'Enom',
status: 'active',
features: { dns_manage: true, whois_privacy: true },
pricing: { USD: { register: 12, transfer: 12, renewal: 14 } },
}),
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $apiKey,
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'extension' => 'com',
'registrar' => 'Enom',
'status' => 'active',
'features' => ['dns_manage' => true, 'whois_privacy' => true],
'pricing' => ['USD' => ['register' => 12, 'transfer' => 12, 'renewal' => 14]],
]),
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);// Buradaki fiyat tek yillik baslangictir; yil kirilimi icin fiyatlama ucunu kullanin.
$response = Api::Products()->CreateDomainTld([
'extension' => 'com',
'registrar' => 'Enom',
'pricing' => ['USD' => ['register' => 12, 'renewal' => 14]],
]);Uzantıyı Silme
Uzantıyı ve fiyatlarını siler.
gate:domain.tld_delete kancası işlemi veto etti.curl -X DELETE 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/com' \
-H "Authorization: Bearer $API_KEY"const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com', {
method: 'DELETE',
headers: { Authorization: `Bearer ${apiKey}` },
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->DeleteDomainTld(['tld' => 'com']);Toplu İşlem
Birden çok uzantıyı açar, kapatır, siler ya da ayarlarını değiştirir.
enable, disable, delete ya da change.extension ve değiştirilecek alanları taşır: özellikler, modül, durum, sıra. Yalnız change işleminde.curl -X POST 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/bulk' \
-H "Authorization: Bearer $API_KEY" \
-H 'Content-Type: application/json' \
-d '{"action":"disable","extensions":["net","org"]}'const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/bulk', {
method: 'POST',
headers: {
Authorization: `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({ action: 'disable', extensions: ['net', 'org'] }),
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/bulk');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $apiKey,
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'action' => 'disable',
'extensions' => ['net', 'org'],
]),
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);// 'change' islemi uzantilar degil degisiklikler listesi ister.
$response = Api::Products()->BulkDomainTlds([
'action' => 'change',
'changes' => [
['extension' => 'net', 'whois_privacy' => true],
['extension' => 'org', 'status' => 'inactive'],
],
]);Fiyatlamayı Ayarlama
Uzantının kayıt, transfer ve yenileme fiyatlarını yıl ve para birimi kırılımıyla yazar.
register, transfer, renewal), sonra yıl, sonra para birimi kodu. En içteki nesne status, fee, promotion_status ve promotion taşır.pricing eşlemesinin tamamını okuyun.curl -X PUT 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/com/pricing' \
-H "Authorization: Bearer $API_KEY" \
-H 'Content-Type: application/json' \
-d '{"auto_pricing":false,"pricing":{"register":{"1":{"USD":{"status":true,"fee":12,"promotion_status":false,"promotion":0}}}}}'const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com/pricing', {
method: 'PUT',
headers: {
Authorization: `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
auto_pricing: false,
pricing: {
register: {
1: { USD: { status: true, fee: 12, promotion_status: false, promotion: 0 } },
},
},
}),
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/com/pricing');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $apiKey,
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'auto_pricing' => false,
'pricing' => [
'register' => [
1 => ['USD' => ['status' => true, 'fee' => 12]],
],
],
]),
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);// Okurken alan adi 'amount', yazarken 'fee' — ikisi ayni degeri tasir.
$current = Api::Products()->GetDomainTld(['tld' => 'com'])['data']['pricing'];
$amount = $current['register']['1']['USD']['amount'];
Api::Products()->SetDomainTldPricing([
'tld' => 'com',
'pricing' => [
'register' => [1 => ['USD' => ['status' => true, 'fee' => $amount + 1]]],
],
]);Belge Seti Olan Uzantılar
Kayıt sırasında belge isteyen uzantıları döndürür.
curl 'https://panel.ornek.com/api/v1/admin/products/domain/docs' \
-H "Authorization: Bearer $API_KEY"const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/docs', {
headers: { Authorization: `Bearer ${apiKey}` },
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/docs');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->GetDomainDocsList();Belge Setini Okuma
Bir uzantının kayıt sırasında istediği belgeleri döndürür.
text, file ya da select.active ya da inactive.curl 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs' \
-H "Authorization: Bearer $API_KEY"const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs', {
headers: { Authorization: `Bearer ${apiKey}` },
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->GetDomainTldDocs(['tld' => 'us']);Belge Setini Yazma
Belge setini yazar. Gönderdiğiniz set yeni gerçektir; içinde olmayan belge silinir.
curl -X PUT 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs' \
-H "Authorization: Bearer $API_KEY" \
-H 'Content-Type: application/json' \
-d '{"description":{"en":"Provide a valid ID."},"docs":{"n1":{"type":"text","name":{"en":"Registrant ID"}}}}'const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs', {
method: 'PUT',
headers: {
Authorization: `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
body: JSON.stringify({
description: { en: 'Provide a valid ID.' },
docs: {
n1: { type: 'text', name: { en: 'Registrant ID' } },
},
}),
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'PUT',
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $apiKey,
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => json_encode([
'description' => ['en' => 'Provide a valid ID.'],
'docs' => [
'n1' => ['type' => 'text', 'name' => ['en' => 'Registrant ID']],
],
]),
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);// Bir belge EKLEMEK icin mevcut seti de gonderin, yoksa oncekiler silinir.
$existing = Api::Products()->GetDomainTldDocs(['tld' => 'us'])['data']['docs'];
$docs = [];
foreach ($existing as $doc) $docs[$doc['id']] = ['type' => $doc['type'], 'name' => $doc['names']];
$docs['n1'] = ['type' => 'file', 'name' => ['en' => 'Passport scan']];
Api::Products()->SetDomainTldDocs(['tld' => 'us', 'docs' => $docs]);Belge Setini Silme
Uzantının belge setinin tamamını siler.
curl -X DELETE 'https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs' \
-H "Authorization: Bearer $API_KEY"const res = await fetch('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs', {
method: 'DELETE',
headers: { Authorization: `Bearer ${apiKey}` },
});
const body = await res.json();$ch = curl_init('https://panel.ornek.com/api/v1/admin/products/domain/tlds/us/docs');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'DELETE',
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . $apiKey],
]);
$body = json_decode(curl_exec($ch), true);
curl_close($ch);$response = Api::Products()->DeleteDomainTldDocs(['tld' => 'us']);Tuzaklar
Fiyat tablosunda aynı değer okurken amount, yazarken fee adıyla geçer. Detaydan okuduğunuz tabloyu olduğu gibi geri göndermek bu yüzden çalışmaz; alan adını dönüştürmeniz gerekir.
Belge yazma ucu birleştirme yapmaz. Bir belge eklemek için mevcut setin tamamını da göndermeniz gerekir; göndermezseniz eskiler silinir ve o uzantıda kayıt için istenen belgeler kaybolur. Yeni belgeye kendi uydurduğunuz bir anahtar verin, mevcut belgede kaydın kimliğini kullanın.
Açma, kapatma ve silme için uzantı listesi gönderilir; ayar değiştirme için uzantı başına değişiklik listesi. Yanlış alanı göndermek işlemi sessizce boş bırakır: dönen liste boş gelir ama hata da alınmaz. Uygulananları döndüğü listeden doğrulayın.
Tescil modülü bağlı değilse uzantı satılabilir ama kayıt, transfer ve yenileme otomatik çalışmaz; bu işleri operatör elle yapar. Uzantıyı açmadan önce modülün bağlı olduğunu doğrulayın.
İlgili Makaleler
Geri bildiriminiz için teşekkürler!
Yukarıda bulamadığınız her şey için destek ekibimiz her zaman yanınızda.