Get quote (get_quote)
About 487 words
Gets the current unit price by goods (with level discounts applied). A quote is a unit price: there are no quantity-based tiers, so you do not need to send a quantity.
- Permission:
quote.read - Method:
POST - Idempotency: read-only, changes no state
v1 draft
This page is part of the draft v1 integration contract; details may change along with the integration checklist, so rely on the official checklist published in the portal.
点开字段可查看类型与说明
正在加载交互式结构…
Lookup rules
Same as the availability query:
- Goods: provide at least one of
goods_idandguid; when both are given,guidwins. - SKUs (optional): each SKU in
skusis identified bysku_idorguid, withguidtaking precedence; omit it to quote all SKUs of the good.
Request example
{
"id": "shop-a-20261127-quote-001",
"cmd": "get_quote",
"data": {
"items": [
{
"goods_id": 501,
"guid": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"default_ccy": "CNY",
"skus": [
{ "sku_id": 1001, "guid": "5d8f2a6c9e1b4d3f8a7c0e2b5d9f1a3c" }
]
},
{
"guid": "4c7e1a9d2b5f4e8a9c3d6b1e7f2a5c8d"
}
]
},
"stamp": 1795000000
}Response example
{
"id": "shop-a-20261127-quote-001",
"cmd": "get_quote",
"code": 0,
"msg": "",
"data": {
"quote_id": "q_8f21c0",
"checked_at": "2026-11-27T01:10:00Z",
"items": [
{
"goods_id": 501,
"guid": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"default_ccy": "CNY",
"base_prices": [
{ "amt": "1.00", "ccy": "USD" },
{ "amt": "6.66", "ccy": "CNY" },
{ "amt": "1.10", "ccy": "USDT" }
],
"prices": [
{ "amt": "1.00", "ccy": "USD" },
{ "amt": "6.66", "ccy": "CNY" },
{ "amt": "1.10", "ccy": "USDT" }
],
"checked_at": "2026-11-27T01:10:00Z",
"skus": [
{
"sku_id": 1001,
"guid": "5d8f2a6c9e1b4d3f8a7c0e2b5d9f1a3c",
"default_ccy": "CNY",
"base_prices": [
{ "amt": "1.00", "ccy": "USD" },
{ "amt": "6.66", "ccy": "CNY" },
{ "amt": "1.10", "ccy": "USDT" }
],
"prices": [
{ "amt": "1.00", "ccy": "USD" },
{ "amt": "6.66", "ccy": "CNY" },
{ "amt": "1.10", "ccy": "USDT" }
],
"checked_at": "2026-11-27T01:10:00Z"
}
]
}
]
},
"stamp": 1795000001
}| Field | Description |
|---|---|
quote_id | Quote identifier; pass it when ordering to lock this unit price |
base_prices | Goods-level multi-currency base unit price; goods without SKUs transact at this price |
prices | Goods-level multi-currency transacted unit price (with level discounts applied) |
default_ccy | Default currency, one per good and per SKU; prices always includes it |
skus[] | Per-SKU base_prices / prices; an empty array when there are no SKUs |
checked_at | Price collection time; present at top level, goods level, and SKU level |
Usage rules
- A quote neither holds balance nor locks stock; the transacted amount is the actual order quantity × the quoted unit price.
- A quote has no fixed expiry; re-quote after a price adjustment. The order amount follows the quote or goods list in effect at that moment.
- Level changes only affect new quotes; completed orders are not affected by later level or price changes.
- Order quantities must still satisfy the SKU's
min_qty/max_qty/per; see Query available quantity.
Errors
| code | Scenario | Action |
|---|---|---|
2001 | SKU does not exist or is delisted | Refresh the goods list |
2002 | Goods suspended from sale | Stop selling this SKU |
1003 | quote.read not enabled | Enable the permission in the portal |
3002 | The same good appears more than once in items | Merge them into one entry |
4001 | Rate limit exceeded | Back off per retry_after |