주문 Preview API

POST /v1/orders/preview — 생성 전에 라인, 가격, 중국 내 운임을 검증합니다.

관련 문서: Create order · Response model

요청 본문

필드필수설명
channel1688 | taobao
receiver중국 내 입고 주소: name, mobile, province, city, address; 1688에서 address_id가 없으면 district도 필요
lines[]각 라인의 id + spec_id + quantity (offer_id / mi_id still work)
response_format아니요standard(기본값) 또는 upstream

Taobao: Gateway가 mi_id + traffic sku_id를 자동으로 배치 확인한 뒤 upstream render를 호출합니다. lines[].id에는 최신 id / mi_id를 쓰세요. 주기적으로 바뀌므로 장기 캐시하지 마세요.

Line mapping

Prefer lines[].id = search/detail id. offer_id and mi_id remain compatible.

lines[]1688Taobao
id (preferred)search/detail id (offerId)search/detail id (mi_id)
offer_idCompatible alias of idCompatible alias of id
mi_idCompatible Taobao alias of id
spec_idvariants[].sku_idvariants[].sku_id (or mpSkuId)

If both id and offer_id are sent, offer_id wins. Otherwise id (then mi_id) is copied to offer_id. Do not pass Taobao source_product_id. Taobao id / mi_id rotates periodically.

예시

POST /v1/orders/preview
{
  "channel": "1688",
  "receiver": {
    "name": "张三",
    "mobile": "15251667788",
    "province": "浙江省",
    "city": "杭州市",
    "district": "滨江区",
    "address": "网商路699号"
  },
  "lines": [
    {
      "id": "554456348334",
      "spec_id": "b266e0726506185beaf205cbae88530d",
      "quantity": 5
    }
  ]
}

Taobao example

POST /v1/orders/preview
{
  "channel": "taobao",
  "receiver": {
    "name": "张三",
    "mobile": "15251667788",
    "province": "浙江省",
    "city": "杭州市",
    "district": "滨江区",
    "address": "网商路699号"
  },
  "lines": [
    {
      "id": "0000iIpSgysC-ca00kbG-Y-LXZu7WojtOJ5cnKTyzoID9UM",
      "spec_id": "6079564221554",
      "quantity": 5
    }
  ]
}

응답

StandardOrderPreviewResultorder response models를 참고하세요. JSON 예시: Response format.

Get Support

Need integration help? Contact Developer Support at support@hiobuy.com · Response within 1–2 business days

Email support