getOrder()

OrderDetails getOrder(string orderNumber)

This method searches for an order by order number, and returns an XML document that contains the completed order form and status information about the order components.

This method retrieves orders in any stage of the order process, including completed orders. However, you may not be able to retrieve orders that:
  • are archived or cancelled
  • contain a deleted subscription
  • were created in a previous version of Smile
  • the caller does not have permission to access

Parameters

orderNumber
Format: string
Purpose: Specifies the number or other ID of the order to retrieve. Smile returns the <OrderNumber> element in the OrderDetails XML document that is returned when you place an order in the API.

Results

This method returns an OrderDetails XML document that contains the completed order form, and status information for the accounts and subscriptions in the order.

There are no messages defined by this method.

Example: A returned OrderDetails XML document

This example shows an OrderDetails XML document for an account and two subscriptions. The document contains the order number (O12492318), specifies that the order has been approved (RequiresApproval is false), and contains the USN, SID and status information (provisioned, activated and enabled) for the account and subscriptions.

<OrderDetails xmlns="http://xml.inomial.com/smile/2.xsd">
  <OrderNumber>O12492318</OrderNumber>
  <Order>
    <Package>192</Package>
    <RequiresApproval>false</RequiresApproval>
    <AccountUSN>1204921324</AccountUSN>
    <PackagePlan>812</PackagePlan>
    <OrderForm>
      <Object>
        <String name="username">+61355501256</String>
        <String name="contactGiven">Joe</String>
        <String name="contactFamily">Smith</String>
        <String name="emailAddress">joe@example.com</String>
        <String name="companyName">Example Telecom Ltd</String>
        <Integer name="phoneLines">12</Integer>
      </Object>
    </OrderForm>
  </Order>
  <OrderedComponents>
    <Account>
      <USN>1204921324</USN>
      <ProvisionStatus>Provisioned</ProvisionStatus>
      <ActivateStatus>Activated</ActivateStatus>
      <EnableStatus>Enabled</EnableStatus>
    </Account>
    <Subscription>
      <USN>120398123</USN>
      <ProvisionStatus>Provisioned</ProvisionStatus>
      <ActivateStatus>Activated</ActivateStatus>
      <EnableStatus>Enabled</EnableStatus>
      <SID>15</SID>
    </Subscription>
    <Subscription>
      <USN>120398131</USN>
      <ProvisionStatus>Provisioned</ProvisionStatus>
      <ActivateStatus>Activated</ActivateStatus>
      <EnableStatus>Enabled</EnableStatus>
      <SID>1</SID>
    </Subscription>
  </OrderedComponents>
</OrderDetails>

Faults

OrderException

This fault is returned when the order does not exist or the caller does not have permission to access the order.

Java client syntax

java -cp build/smilewsv2-client.jar [options] com.inomial.smile.client.v2.examples.GetOrder orderNumber
orderNumber
Purpose: Specifies the number or other ID of the order to retrieve.
Note: For more information about the Java client and the options it accepts, see Java client syntax.