Jump to content

Add order using API


winten

Recommended Posts

I was testing API to add order and noticed it fails to do so:

I used the following code:

 

  $command = "addorder";
$adminuser = "admin";
$values["clientid"] = "1";
$values["domaintype"] = array("register");
$values["domain"] = array("supernicedom.com");
$values["regperiod"] = array(1);
$values["dnsmanagement"] = array("on");
$values["idprotection"] = array("on");
$values["nameserver1"] = "ns1.demo.com";
$values["nameserver2"] = "ns2.demo.com";
$values["nameserver3"] = "ns3.demo.com";
$values["nameserver4"] = "ns4.demo.com";
$values["paymentmethod"] = "paypal";

$results = localAPI($command,$values,$adminuser);
print_r($results);

 

and obtained result:

Array ( [result] => success [orderid] => 0 [productids] => [addonids] => [domainids] => 0 [invoiceid] => ) 

 

However the domain was not registered for the client.

 

Any ideas what may be wrong?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated