Supplier inquiry API
Estimate international shipping before the customer buys
For a sofa, a floor lamp, a treadmill or a large pet crate, the international shipping cost is driven almost entirely by how the item is actually packed: its packed weight, its box dimensions, and how many packages it ships in.
That data is routinely missing or unreliable on 1688 and Taobao product pages. Which leaves your customer with a very practical problem:
They know what the product costs. They have no idea what it costs to get it to their country.
The Supplier inquiry API closes that gap. HIOBuy’s supplier communication service contacts the real supplier before the purchase, confirms packed weight, package dimensions and carton details, and returns the answers to your application as structured data — ready to feed into a shipping estimate.
Why the Product API isn’t enough
The product APIs reliably give you what the marketplace itself knows: title, images, price, SKUs, attributes, shop information. Logistics data is a different story:
- no weight is published at all;
- the weight shown is the net product weight, not the packed weight;
- product dimensions exist, but not the dimensions after packing;
- the weight was typed in by the seller and is only indicative;
- different SKUs pack to different weights;
- a large item ships split across several packages;
- carton quantity, carton weight and carton size are nowhere on the page.
The Product API tells you what the marketplace knows. A supplier inquiry gets you what only the supplier can confirm.
Example: estimating shipping for a sofa
A customer in the United States is looking at a 1688 sofa in your app, priced at ¥800. The product API has already returned the product, price, images, SKUs and attributes — but no reliable packed weight or package dimensions.
So your app cannot answer the only question that matters next:
Product price ¥800
International shipping ???On a bulky item, that unknown can easily exceed the price of the product itself.
Your app raises an inquiry:
POST /v1/supplier-inquiries
{
"product_url": "https://detail.1688.com/offer/554456348334.html",
"questions": [
{ "type": "packed_weight" },
{ "type": "package_dimensions" },
{ "type": "carton_info" }
]
}HIOBuy hands the task to the supplier communication service, and a China-based operator contacts the actual supplier of that listing. The supplier replies that the sofa ships as two packages:
Package 1 32 kg 110 × 75 × 55 cm
Package 2 18 kg 90 × 60 × 40 cmThose answers come back to your application as structured JSON, and the whole path looks like this:
1688 product
↓ Product API
Price: ¥800
↓ reliable logistics data missing
Supplier inquiry
↓ HIOBuy contacts the real supplier
Supplier confirms: 2 packages, 32 kg + 18 kg, box dimensions
↓ structured logistics data
International shipping estimate (China → United States)
↓
The customer sees an approximate total cost before buyingWhich is the point of the whole exercise:
Product cost
+ estimated international shipping
= a realistic pre-purchase costWhere it sits in the HIOBuy APIs
Product API "What is the product, and what does it cost?"
↓
Supplier inquiry API "How will the supplier actually pack it?"
↓
Shipping quote "Roughly what will it cost to ship internationally?"Supplier inquiry is the missing layer between product data and a shipping quote.
Supplier-confirmed data is an estimate
What you get back is supplier-confirmed data. For a pre-purchase estimate that is far better than having no logistics data, using the net product weight, guessing from photos, or trusting a marketplace field that was never meant to be accurate.
But supplier-confirmed is not warehouse-measured. Once the goods physically arrive, the packing may differ, the warehouse may repack, and the real weight, dimensions and package count may all change.
Use these answers for pre-purchase international shipping estimation. Do not treat them as the final billable shipping weight — that always comes from what the warehouse actually packs and measures.
More than shipping data
Packaging data for shipping estimation is the first and most concrete use of this API, but the same supplier communication channel answers anything only the supplier knows:
MOQ · stock · lead time · neutral packaging · customization · carton information · product details · anything else, via the other type.
So today it gives you packaging data → shipping estimate, and the same call can equally serve supplier information → purchasing decision. See question types for all ten and their answer schemas.
How it works
- Your app calls
POST /v1/supplier-inquirieswith a product URL, an optional SKU, and one or more typed questions. - HIOBuy creates the inquiry and hands it to the supplier communication service.
- A China-based operator contacts the supplier of that listing.
- The supplier replies.
- The reply is normalized into structured data against the schema of each question type.
- Your endpoint receives the
supplier_inquiry.message_answeredwebhook, or you pollGET /v1/supplier-inquiries/{id}.
An inquiry is a conversation, not a one-shot request. Once it exists you keep adding follow-up messages to the same thread rather than opening a second one.
This is a human service, not a real-time API
A real person contacts a real supplier, so response time depends on the supplier being online, how fast they reply, how complex the question is, and whether a follow-up is needed. Treat it as an asynchronous task measured in hours, occasionally longer. Some questions will legitimately come back as unavailable or refused.
In practice: never let a customer-facing page wait synchronously on a result, return as soon as the inquiry is created, receive answers by webhook, and show a processing or waiting_supplier state in your UI meanwhile.
Attachments
Some questions are much easier to ask with a picture. A packaging reference, a SKU screenshot, a dimension drawing, a specification sheet — and in the other direction, the supplier’s own packaging photo, a carton photo or a quotation PDF.
Every message, yours and the supplier’s, can carry up to five attachments:
{
"message": "Please ask the supplier whether they can use packaging similar to this.",
"attachments": [
{
"type": "image",
"url": "https://example.com/reference-packaging.jpg",
"filename": "reference-packaging.jpg",
"mime_type": "image/jpeg"
}
]
}type is image, document or other. The URL must be https://; anything else is rejected with INVALID_ATTACHMENT_URL.
HIOBuy does not host attachment files
Attachments are references. You host your own files; the supplier’s files are hosted by the inquiry service. HIOBuy stores the metadata and the URL, and never uploads, downloads, copies or proxies the file itself. There is no file upload endpoint, and none is planned.
The practical consequence is that attachment URLs are managed by whoever provides them, and some of them expire. When a response carries expires_at, treat it as the deadline for fetching that file into your own storage; null means the provider states the URL does not expire. Do not build on the assumption that a URL returned today still resolves next month.
Supplier replies may include attachments too. They arrive in the message’s attachments array and in the supplier_inquiry.message_answered webhook, alongside the structured answers. You only ever see attachments the inquiry service marked as yours to see — operator working files and supplier chat screenshots stay internal to the service and never reach the API.
Access
Supplier inquiry is off by default. HIOBuy enables it per application after commercial onboarding — contact HIOBuy support to request access.
| Requirement | Value |
|---|---|
| Capability | Supplier inquiry, enabled per application |
| Scopes | supplier_inquiry:read, supplier_inquiry:write |
| Auth | Live API key (Authorization: Bearer hio_live_...) |
If the capability is missing or suspended, every endpoint returns 403 SUPPLIER_INQUIRY_NOT_ENABLED.
Supported marketplaces
| Channel | Detected from |
|---|---|
1688 | detail.1688.com/offer/{id}.html and equivalent links |
taobao | item.taobao.com / detail.tmall.com item links |
Anything else fails with UNSUPPORTED_MARKETPLACE. A product is identified by channel + source_product_id, never by the raw URL string, so different link shapes for the same offer resolve to the same product.
Inquiry statuses
| Status | Meaning |
|---|---|
pending | Accepted, not yet picked up by the provider |
processing | An operator is working on it |
waiting_supplier | The question was sent; waiting for the supplier to reply |
answered | The latest message has answers — the thread stays open for follow-ups |
completed | The conversation is closed |
failed | The message could not be delivered or the provider rejected it |
cancelled | Cancelled; no further messages accepted |
pending, processing, waiting_supplier and answered count as active. An application may hold only one active inquiry per product — that is what keeps a single supplier thread per offer. Sending a create request for a product with a completed or failed inquiry reopens that conversation instead of creating a new one.
Webhooks
Register an endpoint in the developer portal and subscribe to the supplier_inquiry category. Signing and retries follow the standard webhook rules.
| Event | Fired when |
|---|---|
supplier_inquiry.created | An inquiry is created |
supplier_inquiry.processing | An operator picked up the message |
supplier_inquiry.waiting_supplier | The question reached the supplier |
supplier_inquiry.message_answered | Answers arrived — payload carries the full answers array and any attachments |
supplier_inquiry.completed | The conversation was closed |
supplier_inquiry.failed | The message failed |
Every payload carries inquiry_id and product.{channel,source_product_id}.
Error codes
| Code | HTTP | Meaning |
|---|---|---|
SUPPLIER_INQUIRY_NOT_ENABLED | 403 | Capability not granted, or suspended |
INVALID_PRODUCT_URL | 400 | Not an absolute http(s) URL, or no product id in it |
UNSUPPORTED_MARKETPLACE | 400 | Channel is not 1688 or Taobao |
INVALID_QUESTION_TYPE | 400 | Unknown questions[].type |
INVALID_QUESTION_SCHEMA | 400 | Empty, oversized, or duplicated questions |
INVALID_ATTACHMENT_URL | 400 | Attachment URL is missing, not absolute, or not https:// |
INVALID_ATTACHMENT_TYPE | 400 | attachments[].type is not image, document or other |
TOO_MANY_ATTACHMENTS | 400 | More than five attachments on one message |
ACTIVE_INQUIRY_EXISTS | 409 | An active inquiry already exists — add a message to it instead |
INQUIRY_NOT_FOUND | 404 | Unknown inquiry, or it belongs to another application |
INQUIRY_NOT_ACTIVE | 409 | The inquiry is cancelled |
SUPPLIER_INQUIRY_SERVICE_UNAVAILABLE | 503 | The inquiry service is down or rejected the task |
SUPPLIER_INQUIRY_SERVICE_UNAVAILABLE is deliberately generic: provider-side reasons such as balance or account state are not exposed. Quote the request_id when contacting support.
Endpoints
| Endpoint | Purpose |
|---|---|
POST /v1/supplier-inquiries | Create an inquiry |
POST /v1/supplier-inquiries/{id}/messages | Ask a follow-up |
GET /v1/supplier-inquiries | List inquiries |
GET /v1/supplier-inquiries/{id} | Inquiry detail with all messages |
GET /v1/supplier-inquiries/{id}/messages | Messages with questions and answers |
Get Support
Need integration help? Contact Developer Support at support@hiobuy.com · Response within 1–2 business days