PHP code example of cloudxns / cloud-xns-api-sdk-php
1. Go to this page and download the library: Download cloudxns/cloud-xns-api-sdk-php library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cloudxns / cloud-xns-api-sdk-php example snippets
$api->setApiKey('xxxxxxxxxx');//修改成自己API KEY
$api->setSecretKey('xxxxxxxxxx');//修改成自己的SECERET KEY
$api = new \CloudXNS\Api();
$api->setApiKey('xxxxxxxxxx');//修改成自己API KEY
$api->setSecretKey('xxxxxxxxxx');//修改成自己的SECERET KEY
//获取域名列表
$api->domain->domainList();
//添加域名
$arr = array("domain"=>"cloudxns.net");
$api->domain->domainAdd($arr);
//删除域名
$api->domain->domainDelete('5568');