> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dekhq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# getOrderStatusDetails

> Returns the current status of your orders: by purchase order number, by sales order number, changed since a time, or every open order.

Returns the current status of your orders: by purchase order number, by sales order number, changed since a time, or every open order.

## Endpoint

`POST https://partners.dekhq.com/api/promostandards/order-status`

* **WSDL:** [`https://partners.dekhq.com/api/promostandards/order-status?wsdl`](https://partners.dekhq.com/api/promostandards/order-status?wsdl). The schemas it imports are served beside it.
* **Service:** PromoStandards Order Status 1.0.0, SOAP 1.1 (document/literal)
* **Namespace:** `http://www.promostandards.org/WSDL/OrderStatusService/1.0.0/`
* **Request headers:** `Content-Type: text/xml; charset=utf-8`. `SOAPAction: "getOrderStatusDetails"` is accepted but not required; DEKHQ picks the operation from the body element.
* **Responses:** `text/xml; charset=utf-8`, HTTP 200 on success.

## Authentication

Send the `id` and `password` DEKHQ issued you in the request body. Your credential must be enabled for the `order_status` scope. Each credential is limited to 300 requests per minute; above that you get a rate-limit fault with a `Retry-After` header.

## How DEKHQ handles it

* Only orders for the clients your credential is linked to are returned, and only orders that carry a purchase order number.
* At most 5,000 orders per response. There is no paging in Order Status 1.0.0, so poll with queryType 3 for changes.

## Request fields

Element `GetOrderStatusDetailsRequest`.

| Field | Type | Required | Description |
| - | - | - | - |
| `wsVersion` | string (max 64 chars) | Yes | The Standard Version of the Web Service being referenced **DEKHQ:** Accepted; DEKHQ does not check it. Send `1.0.0`. |
| `id` | string (max 64 chars) | Yes | The customerID or any other agreed upon ID. |
| `password` | string (max 64 chars) | No | The password associated with the customerID. |
| `queryType` | int | Yes | The type of query you wish to perform. 1 = PO Number, 2 = Sales Order Number, 3 = Last update, 4 = All Open **DEKHQ:** DEKHQ supports 1 (PO number), 2 (sales order number), 3 (changed since `statusTimeStamp`) and 4 (all open orders). Any other value returns an empty array. |
| `referenceNumber` | string (max 64 chars) | No | The purchase order number associated with the Order. If you pass in a purchaseOrderNumber then you will expect to a response of an array with a SINGLE order status for that purchase order. If this field is left blank it will assume that you are requesting multiple order statuses. **DEKHQ:** Required for queryType 1 and 2. |
| `statusTimeStamp` | dateTime | Yes | Beginning date time since last status change. This field will indicate the change date time for any status change GREATER the date time stamp provided. **DEKHQ:** Read only for queryType 3. The schema marks it required, so send a value for every query type. |

## Response fields

Element `GetOrderStatusDetailsResponse`.

| Field | Type | Required | Description |
| - | - | - | - |
| `OrderStatusArray` | object | Yes | An Array of order status |
| ↳ `OrderStatus` | object\[] | Yes | |
| ↳ ↳ `purchaseOrderNumber` | string (max 64 chars) | Yes | The associated Purchase Order Number from the customer |
| ↳ ↳ `OrderStatusDetailArray` | object | Yes | Array of OrderStatusDetail |
| ↳ ↳ ↳ `OrderStatusDetail` | object\[] | Yes | |
| ↳ ↳ ↳ ↳ `factoryOrderNumber` | string (max 64 chars) | Yes | The associated factory sales order number (This is used in the example of internal PO splitting at the factory level) |
| ↳ ↳ ↳ ↳ `statusID` | integer (one of `10`, `11`, `20`, `30`, `40`, `41`, `42`, `43`, `44`, `60`, `70`, `75`, `80`, `99`) | Yes | Paired standard order status from allowed values **DEKHQ:** DEKHQ returns only 10, 20, 40, 60, 80, 99 (see getOrderStatusTypes). |
| ↳ ↳ ↳ ↳ `statusName` | string (max 256 chars) | No | Textual description of statusID |
| ↳ ↳ ↳ ↳ `expectedShipDate` | dateTime | No | The expected ship date for the purchase order |
| ↳ ↳ ↳ ↳ `expectedDeliveryDate` | dateTime | No | The expected date the order should arrive at customer also known as the “in hands date” |
| ↳ ↳ ↳ ↳ `ResponseToArray` | object | No | An array of human contact information such as email, phone, and rep name so the distributor knows who to get in contact to fix an issue. **DEKHQ:** Not returned by DEKHQ. |
| ↳ ↳ ↳ ↳ ↳ `RespondTo` | object\[] | Yes | |
| ↳ ↳ ↳ ↳ ↳ ↳ `name` | string (max 256 chars) | No | The name of the person to respond to |
| ↳ ↳ ↳ ↳ ↳ ↳ `emailAddress` | string (max 256 chars) | No | A monitored email address that a recipient can send their response to |
| ↳ ↳ ↳ ↳ ↳ ↳ `phoneNumber` | string (max 32 chars) | No | The phone number of the person to respond to |
| ↳ ↳ ↳ ↳ `additionalExplanation` | string (max 1024 chars) | No | This allows further detail about the status **DEKHQ:** Not returned by DEKHQ. |
| ↳ ↳ ↳ ↳ `responseRequired` | boolean | No | True or False to determine if it is necessary to provide information back to the supplier to complete the order |
| ↳ ↳ ↳ ↳ `validTimestamp` | dateTime | Yes | Time of order status |
| `errorMessage` | string (max 256 chars) | No | Response for any error requiring notification to requestor **DEKHQ:** Not used. DEKHQ reports errors as SOAP faults (see Errors). |

## Errors

Errors come back as SOAP 1.1 faults. The schema's `errorMessage` element is not used.

| faultcode | faultstring | HTTP status | When |
| - | - | - | - |
| `soap:Client` | Malformed SOAP request | 500 | The body is not a SOAP envelope with an operation element. |
| `soap:Client` | Invalid id or password | 500 | The `id`/`password` pair is unknown or inactive. |
| `soap:Client` | Credential not permitted for scope: order\_status | 500 | Your credential is not enabled for this service. |
| `soap:Client` | Unsupported operation: \<operation> | 500 | The operation is not one this endpoint serves. |
| `soap:Server` | Rate limit exceeded — retry later | 429 | More than the allowed requests per minute. Wait for the `Retry-After` header (seconds). |
| `soap:Server` | Internal error | 500 | An unexpected error on our side. It is logged; retry later. |

## Example

Sample data is fictional.

<CodeGroup>
  ```xml Request theme={null}
  <?xml version="1.0" encoding="UTF-8"?>
  <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
      <ns:GetOrderStatusDetailsRequest xmlns:ns="http://www.promostandards.org/WSDL/OrderStatusService/1.0.0/">
        <ns:wsVersion>1.0.0</ns:wsVersion>
        <ns:id>example-partner</ns:id>
        <ns:password>example-password</ns:password>
        <ns:queryType>1</ns:queryType>
        <ns:referenceNumber>PO-10042</ns:referenceNumber>
        <ns:statusTimeStamp>2026-01-01T00:00:00Z</ns:statusTimeStamp>
      </ns:GetOrderStatusDetailsRequest>
    </soap:Body>
  </soap:Envelope>
  ```

  ```xml Response theme={null}
  <?xml version="1.0" encoding="UTF-8"?>
  <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
      <ns:GetOrderStatusDetailsResponse xmlns:ns="http://www.promostandards.org/WSDL/OrderStatusService/1.0.0/">
        <ns:OrderStatusArray>
          <ns:OrderStatus>
            <ns:purchaseOrderNumber>PO-10042</ns:purchaseOrderNumber>
            <ns:OrderStatusDetailArray>
              <ns:OrderStatusDetail>
                <ns:factoryOrderNumber>SO-58817</ns:factoryOrderNumber>
                <ns:statusID>60</ns:statusID>
                <ns:statusName>In Production</ns:statusName>
                <ns:expectedShipDate>2026-02-12T00:00:00Z</ns:expectedShipDate>
                <ns:expectedDeliveryDate>2026-02-16T00:00:00Z</ns:expectedDeliveryDate>
                <ns:responseRequired>false</ns:responseRequired>
                <ns:validTimestamp>2026-02-05T15:30:00Z</ns:validTimestamp>
              </ns:OrderStatusDetail>
            </ns:OrderStatusDetailArray>
          </ns:OrderStatus>
        </ns:OrderStatusArray>
      </ns:GetOrderStatusDetailsResponse>
    </soap:Body>
  </soap:Envelope>
  ```

  ```xml Fault theme={null}
  <?xml version="1.0" encoding="UTF-8"?>
  <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
    <soap:Body>
      <soap:Fault>
        <faultcode>soap:Client</faultcode>
        <faultstring>Invalid id or password</faultstring>
      </soap:Fault>
    </soap:Body>
  </soap:Envelope>
  ```
</CodeGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.