API:addOrder - Place new order

Create new order on customer behalf

Required parameters

client_id
Client ID
confirm
Set to 1 if you wish to notify client about this order
invoice_generate
Set to 1 if you wish to generate invoice for this order
invoice_info
Set to 1 if you wish to send invoice generated for this order

Parameters: Ordering product/service

module
Payment module ID invoice should be generated with
product
Service ID to purchase
domain_name
Domain name
cycle
Billing cycle for product, allowed values: 'm','q','s','a','b','t','d','w','h' or 'Free' or 'Once' where m-monthly, q-quarterly etc.
coupon
Valid promotion code (Optional).

Parameters: Ordering domain registration/transfer

module
Payment module ID invoice should be generated with
domain_action
Type of action: 'register', 'transfer'
domain_sld
Domain name
domain_period
Number of years, integer values
domain_tld
Domain tld, e.g.: '.com', '.org'
product
Domain product ID - id of product from Domains order page type
Note: domain_tld is the prefered value and will be used if specified
domain_dns
Set to 1 if you wish to enable DNS Management
domain_email
Set to 1 if you wish to enable Email Forwarding
domain_idp
Set to 1 if you wish to enable ID Protection
coupon
Valid promotion code (Optional).

Request

GET http://url_to_your_hostbill.com/admin/api.php?api_id=API_ID&api_key=API_KEY&call=addOrder&client_id=CLIENT_ID&product=PRODUCT&cycle=CYCLE&confirm=CONFIRM&invoice_generate=INVOICE_GENERATE&invoice_info=INVOICE_INFO

Response

   {
      "success": true,
      "order_id": "171",
      "call": "addOrder",
      "server_time": 1317726282,
      "info": [
         "New Order created"
      ]
   }