BuyCN Public Freight Quotes API — Integration Guide
Prepared for integration partners · buycn.com
Overview
Public, unauthenticated, read-only endpoint returning current international freight quotes for a destination country and parcel weight. Data is served from the same engine as our customer-facing estimates page and refreshes dynamically as our freight partners update rates. Prices are in USD, sorted ascending.
Endpoint
GET https://buycn.com/api/public/quotes
Parameters (query string)
| Param | Required | Format | Example |
|---|---|---|---|
country | yes | Full country name or ISO 3166 code (e.g. United States, US, GB, DE, FR) | United States |
weight | yes | Parcel weight in grams (integer) — grams, not kg | 1000 = 1 kg |
1000 for 1 kg. Values in kg will be interpreted as grams and misquote.
Example:
https://buycn.com/api/public/quotes?country=United%20States&weight=1000
Response
Success envelope: code: 1, msg: "ok".
{
"code": 1,
"msg": "ok",
"data": {
"country": "US",
"weight_g": 1000,
"rate_usd_per_cny": 0.1407,
"channels": [
{ "channel": 21, "name": "美国商派小包-普货", "days": "8-10d", "freight_usd": 9.28, "freight_cny": 65.95 }
]
}
}
data.country— normalized country code;data.weight_g— echo of the weight in grams.data.rate_usd_per_cny— the settlement rate (USD per 1 CNY) used for this response;freight_usd ≈ freight_cny × rate(reconciliation-friendly).data.channels[]— sorted byfreight_usdascending.
Channel object fields
| Field | Type | Notes |
|---|---|---|
channel | number | Channel id (stable) |
name | string | Channel name (Chinese, as internally named; an English mapping is available on request) |
days | string | Typical transit estimate, e.g. "8-10d"; empty string when the channel publishes no transit time |
freight_usd | number | Freight quote in USD for the requested weight |
freight_cny | number | Freight quote in CNY (origin currency, same source as the user-facing estimates page) — added for CNY-first integrators |
Edge cases
- Unknown or unsupported country → HTTP 200 with an empty
channelsarray (not an error). - Some tax-included channels publish no transit estimate →
days: "". - Malformed or missing params → the endpoint returns its self-describing usage object (
msg: "usage").
Usage probe
Calling the endpoint without params returns a self-describing usage object (params, example, notes) — handy for quick sanity checks.
Rate limits & partner access
| Tier | Limit | How |
|---|---|---|
| Anonymous | 30 requests/min per IP | Default |
| Partner | 120 requests/min per IP | Send us your server egress IP(s); we whitelist them server-side (effective immediately, no redeploy) |
Caching
Rates update dynamically as our freight partners update them — there is no fixed publication schedule. A cache window shorter than 5 days matches the data well; shorter windows (e.g. a few times daily) are fine within the partner rate limit.
Scope notes
- Quotes are freight-only estimates in USD for the given weight: they exclude product price, destination duties/taxes, and any internal pricing fields (the endpoint exposes no internal pricing data by design).
- Final customer-facing totals may add destination taxes/duties estimates on our estimates page; this API intentionally returns the freight layer only.
QC Photo Sharing API
A second public, unauthenticated, read-only endpoint returns anonymized warehouse QC (inspection) photos keyed by the source-site listing (site + goodsId), for QC-aggregation tool integrations (rep.tools / picks.ly style). Photos appear only when the customer explicitly opted in on that order ("share my QC photos anonymously with public QC tools"); orders without consent are never exposed. By design the payload carries no personal data — no user IDs, no order numbers, no amounts, no addresses.
GET https://buycn.com/api/public/qc-photos?site=taobao&goodsId=123456
| Param | Required | Description |
|---|---|---|
site | yes | Source platform, e.g. taobao, 1688, weidian |
goodsId | yes | Source-site goods/listing ID (as used in our product URLs) |
Response (success envelope code: 1):
{
"code": 1,
"msg": "ok",
"data": {
"site": "taobao",
"goods_id": "123456",
"count": 2,
"photos": [
{ "url": "/uploads/xxxx.jpg", "taken_at": "2026-11-16 12:00:00" },
{ "url": "/uploads/yyyy.jpg", "taken_at": "2026-11-16 12:05:00" }
]
}
}
- Unknown listing → HTTP 200 with an empty
photosarray (not an error). - Missing params → self-describing usage object (
msg: "usage"). - Per-photo fields are a strict whitelist:
url+taken_atonly. - Takedown: a photo removed for a DMCA/rights complaint disappears from this endpoint immediately at the origin; CDN caches may hold it up to 300 s (
Cache-Control: public, max-age=300). - Rate limit: 30 requests/min per IP (shared with the freight endpoint's anonymous tier mechanics; HTTP 429 when exceeded).
Contact
Whitelisting, English channel-name mapping, or any integration question: reply in this chat or [email protected].