API Module Tutorial orderTutorialRequest

From Openprovider API documentation

(Difference between revisions)
Jump to: navigation, search
WikiSysop (Talk | contribs)
(Created page with '==Module Tutorials > Order== {| border="1" cellpadding="4" |- style="background-color:#BBBBBB;" |'''Module''' |Tutorials |- style="background-color:#EEEEEE;" |'''Command name''' …')
Newer edit →

Revision as of 09:32, 3 September 2010

Contents

Module Tutorials > Order

Module Tutorials
Command name orderTutorialRequest
Use Orders one or more tutorial series
Input
  • productIds (array)
  • customerName
  • customerCompany
  • customerDomain
  • customerEmail
  • customerLogo (base64-encoded)
Output

-

Examples

Using PHP class

$request = new OP_Request;
$request->setCommand('orderTutorialRequest')
  ->setAuth(array('username' => 'username', 'password' => 'password'))
  ->setArgs(array(
    'productIds' => array(62, 64),
    'customerName' => 'John Jones',
    'customerCompany' => 'End User Ltd',
    'customerDomain' => 'www.end-user.net',
    'customerEmail' => 'support@end-user.net',
    'customerLogo' => base64_encode(file_get_contents('logo.jpg'))
  ));

Raw XML

<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <credentials>
    <username>username</username>
    <password>password</password>
  </credentials>
  <orderTutorialRequest>
    <productIds>
      <array>
        <item>62</item>
        <item>64</item>
      </array>
    </productIds>
    <customerName>John Jones</customerName>
    <customerCompany>End User Ltd</customerCompany>
    <customerDomain>www.end-user.net</customerDomain>
    <customerEmail>support@end-user.net</customerEmail>
    <customerLogo>iVBORw0KG{...}AElFTkSuQmCC</customerLogo>
  </orderTutorialRequest>
</openXML>
<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <reply>
    < code>0</code>
    <desc />
    <data>1</data>
  </reply>
</openXML>
Views
Personal tools