Jump to content

Action hook or module?

Recommended Posts

So Im working on a quick script to auto create a sub account, corresponding domain, and admin login credentials in Rackspace's email reselling API. Here's what I have so far (tested, and works when called directly):


$client = new SoapClient('https://admin.webmail.us/excedentsoap/excedentsoap.wsdl');
$res = $client->__soapCall('AddDomain',
                   array('ResellerUsername' => 'USERNAME',
                         'ResellerPassword' => 'PASSWORD',
                         'HostName' => 'domain.com', // primary domain
                         'Aliases' => '', // Domain aliases only
                         'MaxMbxSize' => 10240, // size in megabytes
                         'MaxNumUsers' => 10, // 0 for unlimited email accounts
                         'AllowWirelessAccess' => 1, // Set 0 to dissallow or 1 to allow comments
                         'AdminUsername' => 'username', // 1st admin login name
                         'AdminPassword' => 'password', // 1st admin password
                         'MxRecordArray' => $test));




My question is this: I'd like to have the above code run when an order is accepted through WHMCS for email services... do I create an action hook for this or is this something that needs a module written for?

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.

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