Jump to content

API - Add Order Questions


bryyyon

Recommended Posts

I am attempting to create an order form that is completely external from a WHMCS installation, using the API.

 

Is it possible to specify a hosting account's cPanel username and/or password during the `addorder' API call?

 

Also, I cannot find any documentation on how the call's `configoptions' attribute should be structured. I understand the base64 encoded / serialized array, but what should the array contain? Is this documented anywhere?

 

http://wiki.whmcs.com/API:Add_Order

 

Thank you for any provided insight regarding this.

Link to comment
Share on other sites

  • 3 months later...

I'm stuck at this place as well and was wondering if you ever managed to solve this problem?

 

 

I would imagine it should contain the configurable option id and the value. Something like:

 

$postfields["configoptions"] = base64_encode(serialize(array("4"=>"value", "5"=>"test")));

Link to comment
Share on other sites

  • 1 year later...
Guest benpotter1991
I am attempting to create an order form that is completely external from a WHMCS installation, using the API.

 

Is it possible to specify a hosting account's cPanel username and/or password during the `addorder' API call?

 

Also, I cannot find any documentation on how the call's `configoptions' attribute should be structured. I understand the base64 encoded / serialized array, but what should the array contain? Is this documented anywhere?

 

http://wiki.whmcs.com/API:Add_Order

 

Thank you for any provided insight regarding this.

 

Did you have any success with this? I could do with knowing if you can and how you would do it!

Link to comment
Share on other sites

  • 7 months later...

That worked great BTW !

 

Here was mine (Config options 9 and 10):

$options = base64_encode(serialize(array("9"=>$number1, "10"=>$number2)));

$values = array('clientid' => $uid, 'pid' => "50",'configoptions' => $options,'paymentmethod' => "paypal");

$results = localAPI('addorder',$values,'adminuser');

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