<?php$client = new SoapClient( null, array( "location" => "https://PRODUCTION/cmd.php", "uri" => "http://PRODUCTION/soap" ) );$params = array ( "data" => array ( "login" => "demo", "password" => "password", ));$response = $client->__call("Login",$params);$token = $response["data"]["ssid"];$params = array ( 'data' => array ( 'ssid' => $token, 'domain' => 'exampledomain.com', 'records' => array ( 0 => array ( 'name' => 'sub', 'type' => 'CNAME', 'content' => 'anotherdomain.com', 'prio' => '0', 'ttl' => '1800', ), 1 => array ( 'name' => '@', 'type' => 'A', 'content' => '1.2.3.4', 'prio' => '0', 'ttl' => '900', ), ), ),);$response = $client->__call("Set_DNS_Zone",$params); INPUT: Array ( [data] => Array ( [ssid] => 51aca4e95c12821b56a9045babc943e7 [domain] => exampledomain.com [records] => Array ( [0] => Array ( [name] => sub [type] => CNAME [content] => anotherdomain.com [prio] => 0 [ttl] => 1800 ) [1] => Array ( [name] => @ [type] => A [content] => 1.2.3.4 [prio] => 0 [ttl] => 900 ) ) ) ) OUTPUT: Array ( [status] => ok )
<?php$client = new SoapClient( null, array( "location" => "https://PRODUCTION/cmd.php", "uri" => "http://PRODUCTION/soap" ) );$params = array ( "data" => array ( "login" => "demo", "password" => "password", ));$response = $client->__call("Login",$params);$token = $response["data"]["ssid"];$params = array ( 'data' => array ( 'ssid' => $token, 'domain' => 'exampledomain.com', 'records' => array ( 0 => array ( 'name' => 'sub', 'type' => 'CNAME', 'content' => 'anotherdomain.com', 'prio' => '0', 'ttl' => '1800', ), 1 => array ( 'name' => '@', 'type' => 'A', 'content' => '1.2.3.4', 'prio' => '0', 'ttl' => '900', ), ), ),);$response = $client->__call("Set_DNS_Zone",$params);