Questa chiamata consente di interrogare il sistema per ottenere una lista dei soli domini attivi con le relative informazioni. Vengono mostrati solo i domini attivi.
Parametri della richiesta
Nessuno, solo i dati di login sono necessari.
Parametri della risposta
Parametro | Tipo | Descrizione |
---|---|---|
result | stringa | Il risultato dell’operazione: success o error |
count | INT | Numero intero che rappresenta il totale dei domini attivi |
domains | json | Stringa json contenente la lista ed i dettagli di tutti i domini presenti nell’account |
Esempio di richiesta (PHP cUrl)
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://my.supporthost.com/domainapi.php/account/activedomains',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'X-Email: your_email',
'X-Api-Key: your_apikey'
),
));
$response = curl_exec($curl);
curl_close($curl);
Esempio di risposta (JSON)
{
"result": "success",
"count": 36,
"domains": [
{
"supporthost.it": {
"domain": "supporthost.it",
"status": "Active",
"recurringamount": "9.84",
"registrationperiod": 1,
"registrationdate": "2014-02-15",
"expirydate": "2026-07-03",
"nextduedate": "2026-07-03",
"donotrenew": 0
},
"supporthost.com": ...
}
]
}
Risposte di errore
- Connection refused from unauthorized host. IP xxx.xxx.xxx.xxx is NOT allowed to access your account
- Invalid email or not a reseller.
- Invalid API key.