> For the complete documentation index, see [llms.txt](https://apidocs.akinon.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://apidocs.akinon.com/omnitron/integration/order/get-order-detail-by-order-number.md). Agents can also search and read this documentation through its [MCP server](https://apidocs.akinon.com/~gitbook/mcp).

# Get Order Detail by Order Number

In order to extract specific order details, the user must know the number field of the order.

<table data-header-hidden><thead><tr><th width="140.08203125"></th><th width="104.6953125"></th><th width="93.78515625"></th><th width="94.69140625"></th><th></th></tr></thead><tbody><tr><td><strong>Parameter</strong></td><td><strong>Data Type</strong></td><td><strong>Required</strong></td><td><strong>In</strong></td><td><strong>Description</strong></td></tr><tr><td>api_token</td><td>string</td><td>YES</td><td>header</td><td><a href="https://apidocs.akinon.com/omnitron/getting-started.md">The API key of the customer’s account</a></td></tr><tr><td>{order_number}</td><td>string</td><td>YES</td><td>query</td><td>Order No.</td></tr></tbody></table>

## <mark style="color:red;">`GET`</mark> <mark style="color:red;">Order Detail by Order Number</mark>

**Path:** `/api/i1/orders/`

GET request is used for retrieving order details.

* `content_type` header represents the response type.
* `Authorization` header is a required header for authentication. You can retrieve api\_token with login.

**Example Request**

```python
import requests

url = "https://{customer_api_url}/api/i1/orders/{order_number}"
api_token = "f532eXXXXXXXXXXXXXXXXX201XXXXX9332d"

headers = {
   'content-type': 'application/json',
   'Authorization': 'Token {}'.format(api_token)
}

response = requests.get(url, headers=headers)
print(response.text)
```

**Example Response**

Shows desired order with a given number. All parameters of an order are described in the table below. Resource properties are in Python format.

<table data-header-hidden><thead><tr><th width="162.8359375"></th><th width="139.109375"></th><th></th></tr></thead><tbody><tr><td><strong>Parameter</strong></td><td><strong>Data Type</strong></td><td><strong>Description</strong></td></tr><tr><td>number</td><td>integer</td><td>Order code</td></tr><tr><td>status</td><td>string</td><td>Order status code</td></tr><tr><td>date_placed</td><td>string</td><td>Order date</td></tr><tr><td>customer</td><td>dict</td><td>Customer information</td></tr><tr><td>email</td><td>string</td><td>Customer e-mail</td></tr><tr><td>first_name</td><td>string</td><td>Customer name</td></tr><tr><td>last_name</td><td>string</td><td>Customer surname</td></tr><tr><td>phone_number</td><td>string</td><td>Customer phone</td></tr><tr><td>shipping_address</td><td>dict</td><td>Shipping destination address information</td></tr><tr><td>email</td><td>string</td><td>Ship-to party email</td></tr><tr><td>first_name</td><td>string</td><td>Ship-to party name</td></tr><tr><td>last_name</td><td>string</td><td>Ship-to party surname</td></tr><tr><td>phone_number</td><td>string</td><td>Ship-to party phone number</td></tr><tr><td>country</td><td>dict</td><td>Destination country code</td></tr><tr><td>name</td><td>string</td><td>Destination country name</td></tr><tr><td>code</td><td>string</td><td>Destination country code</td></tr><tr><td>city</td><td>dict</td><td>Order's city details</td></tr><tr><td>id</td><td>string</td><td>City ID</td></tr><tr><td>name</td><td>string</td><td>City name</td></tr><tr><td>line</td><td>string</td><td>Address</td></tr><tr><td>title</td><td>string</td><td>Address title</td></tr><tr><td>township</td><td>dict</td><td>Order's township details</td></tr><tr><td>id</td><td>string</td><td>Township ID</td></tr><tr><td>name</td><td>string</td><td>Township name</td></tr><tr><td>district</td><td>dict</td><td>Order's district details</td></tr><tr><td>id</td><td>string</td><td>District ID</td></tr><tr><td>postcode</td><td>string</td><td>District postcode</td></tr><tr><td>notes</td><td>string</td><td>Address notes</td></tr><tr><td>company_name</td><td>string</td><td>Company name</td></tr><tr><td>tax_office</td><td>string</td><td>Tax office</td></tr><tr><td>tax_no</td><td>string</td><td>Tax no</td></tr><tr><td>e_bill_taxpayer</td><td>boolean</td><td>Is E-bill tax payer or not</td></tr><tr><td>billing_address</td><td>dict</td><td>Billing address</td></tr><tr><td>currency</td><td>string</td><td>Unit of currency</td></tr><tr><td>amount</td><td>float</td><td>Amount</td></tr><tr><td>shipping_amount</td><td>float</td><td>Shipping amount</td></tr><tr><td>shipping_tax_rate</td><td>float</td><td>Shipping tax rate</td></tr><tr><td>extra_field</td><td>dict</td><td>Additional informations about order</td></tr><tr><td>payment_option</td><td>string</td><td>Related Payment Option object id. Check for Payment section for more information.</td></tr><tr><td>payment_option_slug</td><td>string</td><td>Related Payment Option object slug property.</td></tr><tr><td>bin_number</td><td>string</td><td>Bin number</td></tr><tr><td>installment</td><td>string</td><td>Related Installment object id. See the Installment section for more information.</td></tr><tr><td>installment_count</td><td>integer</td><td>Installment count</td></tr><tr><td>installment_interest_amount</td><td>string</td><td>Late charges</td></tr><tr><td>cargo_company</td><td>string</td><td>Cargo company</td></tr><tr><td>invoice_number</td><td>string</td><td>Invoice number</td></tr><tr><td>invoice_date</td><td>iso date str</td><td>Invoice date</td></tr><tr><td>e_archive_url</td><td>string</td><td>E-archive url</td></tr><tr><td>refund_amount</td><td>string</td><td>Refund amount</td></tr><tr><td>discount_refund_amount</td><td>string</td><td>Discount refund amount</td></tr><tr><td>shipping_refund_amount</td><td>string</td><td>Shipping refund amount</td></tr><tr><td>discount_amount</td><td>float</td><td>Total discount amount for the order</td></tr><tr><td>is_send</td><td>boolean</td><td>Shows if the order has been sent to ERP</td></tr><tr><td>net_shipping_amount</td><td>float</td><td>Net shipping amount. (Shipping amount + Shipping Interest Amount)</td></tr><tr><td>shipping_interest_amount</td><td>float</td><td>Shipping Interest amount</td></tr><tr><td>tracking_number</td><td>string</td><td>Tracking number for cargo integration</td></tr><tr><td>carrier_shipping_code</td><td>string</td><td>Shipping code for cargo integration</td></tr><tr><td>remote_addr</td><td>string</td><td>Generic IP address for the orders created.</td></tr><tr><td>has_gift_box</td><td>boolean</td><td>Shows whether it has a gift box</td></tr><tr><td>gift_box_note</td><td>string</td><td>Gift Note</td></tr><tr><td>external_status</td><td>id</td><td>Related Order External Status object id.</td></tr><tr><td>orderitem_set</td><td>array</td><td>List of order items</td></tr><tr><td>id</td><td>string</td><td>Order item ID</td></tr><tr><td>order</td><td>string</td><td>The order of the order item</td></tr><tr><td>product_sku</td><td>string</td><td>Product SKU of order item</td></tr><tr><td>status</td><td>string</td><td>Order status code</td></tr><tr><td>price_currency</td><td>string</td><td>Price currency of the order item</td></tr><tr><td>price</td><td>float</td><td>Price of the order item</td></tr><tr><td>tax_rate</td><td>float</td><td>Tax rate of the order item</td></tr><tr><td>extra_field</td><td>float</td><td>Additional information about the order item</td></tr><tr><td>price_list</td><td>id</td><td>The price list containing the order item</td></tr><tr><td>stock_list</td><td>id</td><td>The stock list containing the order item</td></tr><tr><td>cancel_status</td><td>string</td><td>waiting, confirmation_waiting, confirmed, approved, rejected, waiting_for_payment, manuel_refund_need, completed</td></tr><tr><td>invoice_number</td><td>string</td><td>Invoice number</td></tr><tr><td>invoice_date</td><td>iso date str</td><td>Invoice date</td></tr><tr><td>e_archive_url</td><td>string</td><td>E-archive url</td></tr><tr><td>installment_interest_amount</td><td>float</td><td>Delay interest of installment</td></tr><tr><td>tracking_number</td><td>string</td><td>Shipping tracking number</td></tr><tr><td>carrier_shipping_code</td><td>string</td><td>Shipping code for cargo integration</td></tr><tr><td>shipping_company</td><td>string</td><td>Shipping company</td></tr><tr><td>shipment_code</td><td>string</td><td>Shipment code</td></tr><tr><td>external_status</td><td>id</td><td>Related Order External Status object ID.</td></tr><tr><td>discount_amount</td><td>string</td><td>Total discount applied of order</td></tr><tr><td>retail_price</td><td>float</td><td>Retail price</td></tr><tr><td>attributes</td><td>dict</td><td>Attribute list</td></tr><tr><td>attributes_kwargs</td><td>dict</td><td>Details of the attributes attached to the product</td></tr><tr><td>image</td><td>str(url)</td><td>Product image</td></tr></tbody></table>

```json
{
    "id": 27,
    "number": "bf7b66149236455",
    "status": "400",
    "date_placed": "2017-01-30T08:28:26.158165Z",
    "customer": {
        "id": 1103,
        "email": "test@test.com",
        "first_name": "TEST",
        "last_name": "TEST",
        "phone_number": null
    },
    "shipping_address": {
        "email": "test@test.com",
        "phone_number": "0 (198) 895-4431",
        "first_name": "TEST",
        "last_name": "TEST",
        "country": {
            "name": "Turkey",
            "code": "tr"
        },
        "city": {
            "id": 71,
            "name": "Afyon"
        },
        "line": "test",
        "title": "TEST",
        "township": {
            "id": 853,
            "name": "DİNAR"
        },
        "district": {
            "id": 3679,
            "name": "İNCESU"
        },
        "postcode": "11111",
        "notes": null,
        "company_name": null,
        "tax_office": null,
        "tax_no": null,
        "e_bill_taxpayer": false,
        "identity_number": null,
        "extra_field": {}
    },
    "billing_address": {
        "email": "test@test.com",
        "phone_number": "0 (198) 895-4431",
        "first_name": "TEST",
        "last_name": "TEST",
        "country": {
            "name": "Turkey",
            "code": "tr"
        },
        "city": {
            "id": 71,
            "name": "Afyon"
        },
        "line": "test",
        "title": "TEST",
        "township": {
            "id": 853,
            "name": "DİNAR"
        },
        "district": {
            "id": 3679,
            "name": "İNCESU"
        },
        "postcode": "11111",
        "notes": null,
        "company_name": null,
        "tax_office": null,
        "tax_no": null,
        "e_bill_taxpayer": false,
        "identity_number": null,
        "extra_field": {}
    },
    "currency": "try",
    "amount": "16.40",
    "shipping_amount": "8.50",
    "shipping_tax_rate": null,
    "extra_field": {
        "cargo_line_id": "325a79ac-e251-4285-8a32-a70e0119237e"
    },
    "payment_option": 2,
    "payment_option_slug": "kredi_karti",
    "bin_number": "454360",
    "installment": 22,
    "installment_count": 1,
    "installment_interest_amount": "0.00",
    "cargo_company": 1,
    "invoice_number": "",
    "invoice_date": null,
    "e_archive_url": null,
    "refund_amount": "0.00",
    "discount_refund_amount": "0.00",
    "shipping_refund_amount": "0.00",
    "discount_amount": "0.00",
    "is_send": true,
    "net_shipping_amount": "8.50",
    "shipping_interest_amount": "0.00",
    "tracking_number": null,
    "carrier_shipping_code": null,
    "remote_addr": null,
    "has_gift_box": false,
    "gift_box_note": null,
    "external_status": null,
    "orderitem_set": [
        {
            "id": 113,
            "order": 27,
            "product_sku": "2672881047887",
            "status": "400",
            "price_currency": "try",
            "price": "7.90",
            "tax_rate": "18.00",
            "extra_field": {},
            "price_list": 1,
            "stock_list": 1,
            "cancel_status": null,
            "invoice_number": null,
            "invoice_date": null,
            "e_archive_url": null,
            "installment_interest_amount": "0.00",
            "tracking_number": null,
            "carrier_shipping_code": null,
            "shipping_company": null,
            "shipment_code": null,
            "external_status": null,
            "discount_amount": "0.00",
            "retail_price": null,
            "attributes": {},
            "attributes_kwargs": {},
            "image": null
        }
    ],
    "channel": {
        "name": "Shop",
        "conf": {
            "server": "http://localhost:8080/api/v1/"
        }
    }
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://apidocs.akinon.com/omnitron/integration/order/get-order-detail-by-order-number.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
