# Order Info

> Get the full detail of an order by its GHN tracking code.

## Endpoint

| Environment | URL |
| --- | --- |
| Production | `https://online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/detail` |
| Staging | `https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/detail` |

**Method**: `GET`

## Headers

| Header | Required | Description |
| --- | --- | --- |
| `Token` | Yes | Shop token (issued by GHN) — [get a token](https://developer.ghn.vn/en/docs/token/get-token.md) |
| `ShopId` | Yes | Shop ID (int) |

## Parameters

- **order_code** (String): GHN tracking code. The order must belong to a shop your account is a member of

## Request Example

```bash
curl -X GET "https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/detail?order_code=LADH94" \
  -H "Token: 5c1d8a9e-2f4b-11ed-..." \
  -H "ShopId: 92837"
```

## Response

`data` is a **single order object** (not an array). GHN returns ~120 fields; the sample and tables below cover the fields most integrations need — additional operational fields (warehouse routing, proof-of-delivery, extra services, new-format address fields, internal logs) are returned too and can be ignored if you don't need them.

### Success (HTTP 200)

_Captured from a real Staging-environment call (abridged to the commonly used fields)._

```json
{
  "code": 200,
  "message": "Success",
  "data": {
    "order_code": "LADH94",
    "client_order_code": "FINALDOC-DETAIL-001",
    "status": "ready_to_pick",
    "shop_id": 196560,
    "client_id": 2509893,
    "from_name": "GHN Shirt Shop",
    "from_phone": "0395297295",
    "from_address": "7, 28 Đ. Thành Thái, Phường 10 (Quận 10), Quận 10, Thành phố Hồ Chí Minh, Vietnam",
    "to_name": "Tran Minh Anh",
    "to_phone": "0987654321",
    "to_address": "72 Lê Thánh Tôn, P. Bến Nghé, Quận 1, TP. Hồ Chí Minh",
    "return_name": "GHN Shirt Shop",
    "return_phone": "0395297295",
    "weight": 600,
    "length": 25,
    "width": 20,
    "height": 8,
    "converted_weight": 800,
    "calculate_weight": 800,
    "service_type_id": 2,
    "service_id": 53320,
    "payment_type_id": 1,
    "cod_amount": 285000,
    "cod_collect_date": null,
    "cod_transfer_date": null,
    "is_cod_collected": false,
    "is_cod_transferred": false,
    "cod_failed_amount": 0,
    "insurance_value": 285000,
    "order_value": 0,
    "required_note": "KHONGCHOXEMHANG",
    "content": "Áo thun GHN size M [GHN-TS-M-BLK] [2 cái]",
    "note": "",
    "pickup_shift": {},
    "leadtime": "2026-07-16T16:59:59Z",
    "created_date": "2026-07-15T04:49:47.811Z",
    "updated_date": "2026-07-15T04:49:47.811Z",
    "items": [
      {
        "name": "Áo thun GHN size M",
        "code": "GHN-TS-M-BLK",
        "quantity": 2,
        "length": 10,
        "width": 10,
        "height": 10,
        "weight": 300
      }
    ]
  }
}
```

### Response Fields

| Field | Type | Description |
| --- | --- | --- |
| `order_code` | String | GHN tracking code |
| `client_order_code` | String | Your own order code |
| `status` | String | Order status (see the status values below) |
| `shop_id` | Int | Shop that owns the order |
| `client_id` | Int | Account that owns the order |
| `from_name` | String | Sender name |
| `from_phone` | String | Sender phone |
| `from_address` | String | Sender full address |
| `to_name` | String | Receiver name |
| `to_phone` | String | Receiver phone |
| `to_address` | String | Receiver full address |
| `return_name` | String | Return contact name |
| `return_phone` | String | Return contact phone |
| `return_address` | String | Return full address |
| `weight` | Int | Declared weight (gram) |
| `length` | Int | Length (cm) |
| `width` | Int | Width (cm) |
| `height` | Int | Height (cm) |
| `converted_weight` | Int | Volumetric weight (gram) |
| `calculate_weight` | Int | Chargeable weight the fee is based on (gram) — the greater of `weight` and `converted_weight` |
| `service_type_id` | Int | Service type, chosen by weight:<br>`2`: total weight **under 20 kg**<br>`5`: total weight **20 kg or more**, or multi-parcel orders |
| `service_id` | Int | Delivery service ID |
| `payment_type_id` | Int | Who pays the shipping fee: `1` (also `4`, `5`) if the Shop/Seller pays; `2` if the Buyer/Receiver pays |
| `cod_amount` | Int | COD to collect from the receiver (VND) |
| `cod_collect_date` | String/null | When COD was collected (ISO 8601) |
| `cod_transfer_date` | String/null | When COD was transferred to you (ISO 8601) |
| `is_cod_collected` | Bool | COD collected from receiver |
| `is_cod_transferred` | Bool | COD transferred to you |
| `cod_failed_amount` | Int | Amount collected on a failed delivery (VND) |
| `insurance_value` | Int | Declared/insured value (VND) |
| `order_value` | Int | Order value (VND) |
| `required_note` | String | `KHONGCHOXEMHANG` / `CHOXEMHANGKHONGTHU` / `CHOTHUHANG` |
| `content` | String | Goods description |
| `note` | String | Your note to the driver |
| `pickup_shift` | Object | Concrete pickup window; `{}` when the order has no pick shift. Only populated by this endpoint |
| `pickup_shift.from_time` | String | Pickup window start (ISO 8601) |
| `pickup_shift.to_time` | String | Pickup window end (ISO 8601) |
| `leadtime` | String | Expected delivery time (ISO 8601) |
| `created_date` | String | When the order was created in GHN (ISO 8601) |
| `updated_date` | String | Last update time (ISO 8601) |
| `items` | Object[] | Order items |
| `items[].name` | String | Item name |
| `items[].code` | String | Item code |
| `items[].quantity` | Int | Quantity |
| `items[].price` | Int | Unit price (VND) |
| `items[].length` | Int | Item length (cm) |
| `items[].width` | Int | Item width (cm) |
| `items[].height` | Int | Item height (cm) |
| `items[].weight` | Int | Item weight (gram) |

### Status values

| Status | Meaning | Final |
| --- | --- | --- |
| `ready_to_pick` | Order created, waiting for pickup |  |
| `picking` | Driver is on the way to pick up |  |
| `money_collect_picking` | Collecting money at pickup |  |
| `picked` | Picked up from the shop |  |
| `storing` | At a GHN warehouse |  |
| `sorting` | Being sorted |  |
| `transporting` | In transit between warehouses |  |
| `delivering` | Out for delivery to the receiver |  |
| `money_collect_delivering` | Collecting money at delivery |  |
| `delivered` | Delivered successfully | ✓ |
| `delivery_fail` | Delivery attempt failed |  |
| `waiting_to_return` | Awaiting return to sender |  |
| `return` | Return requested |  |
| `return_transporting` | Return in transit |  |
| `return_sorting` | Return being sorted |  |
| `returning` | On the way back to the sender |  |
| `return_fail` | Return attempt failed |  |
| `returned` | Returned to the sender | ✓ |
| `cancel` | Cancelled | ✓ |
| `exception` | Exception — needs manual handling | ✓ |
| `lost` | Lost | ✓ |
| `damage` | Damaged | ✓ |
| `scrap` | Scrapped / disposed | ✓ |

## Error Codes

| Condition | HTTP | Meaning |
| --- | --- | --- |
| Order not found (`Đơn hàng không tồn tại`) | 400 | The order code is unknown |
| `403` | 403 | Your account lacks the order-detail permission — contact GHN |
| `CLIENT_NOT_OWNER_OF_SHOP` | 400 | The order does not belong to a shop your account is a member of |
| `SERVER_ERROR_COMMON` | 500 | Internal error |
