1688 Product Details API (V1)
API health status
Healthy Available Limited Mostly unavailable No data
Loading health status...
Retrieves the public product detail for a 1688 wholesale listing by item ID. Use it to review a known offer during product sourcing or catalog research.
Parameters
| Name | In | Type | Required | Default | Description |
|---|---|---|---|---|---|
token | query | string | Yes | - | Access token for this API service. |
itemId | query | string | Yes | - | A unique product identifier on 1688. |
Code Samples
bash
curl --max-time 120 -X GET 'https://api.justoneapi.com/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE'text
I want to use the "Product Details (V1)" API from JustOneAPI.
Base URL: https://api.justoneapi.com.
API Path: /api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE
API Endpoint: BASE_URL + /api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE
HTTP Method: GET
Authentication: Append the "token" query parameter to the URL.
OpenAPI Definition: https://docs.justoneapi.com/openapi/1688/product-details-v1-en.json
Parameters:
- token (query): Access token for this API service. (Required)
- itemId (query): A unique product identifier on 1688. (Required)
Return format: safely handle JSON or text according to the actual Content-Type.
Response Handling & Error Codes:
1. Business results should be determined by the "code" field in the response body (code 0 means success).
2. Timeout Recommendation: Set the request timeout to 120 seconds. If 120 seconds is too long for your use case, use at least 60 seconds, but a small number of requests may time out before receiving a result.
3. Business Code Reference:
- 0: Success
- 100: Invalid or Inactive Token
- 301: Collection Failed. Please Retry.
- 302: Rate Limit Exceeded
- 303: Daily Quota Exceeded
- 400: Invalid Parameters
- 500: Internal Server Error
- 600: Permission Denied
- 601: Insufficient Balance
- 602: Token Budget Exceeded
4. Code 601 means the shared account balance is insufficient. Code 602 means the current API token's own cumulative budget limit has been reached. Token budget limits do not transfer funds out of the shared account balance.
Please help me write a script in my preferred programming language to call this API and handle the response.python
import requests
BASE_URL = "https://api.justoneapi.com" # Provided by OpenAPI servers
url = BASE_URL + "/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE"
response = requests.get(url, timeout=120)
print(response.status_code)
if response.content:
content_type = response.headers.get("content-type", "").lower()
if "json" in content_type:
try:
print(response.json())
except ValueError:
print(response.text)
elif content_type.startswith("text/") or "xml" in content_type or content_type.split(";", 1)[0].strip() in {"application/javascript", "application/x-www-form-urlencoded", "application/graphql"}:
print(response.text)
else:
with open("response.bin", "wb") as output:
output.write(response.content)
print(f"Saved {len(response.content)} bytes to response.bin")js
const BASE_URL = "https://api.justoneapi.com"; // Provided by OpenAPI servers
const url = BASE_URL + "/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE";
const response = await fetch(url, {
method: "GET",
signal: AbortSignal.timeout(120000)
});
console.log(response.status);
const responseBytes = await response.arrayBuffer();
if (responseBytes.byteLength) {
const contentType = (response.headers.get("content-type") || "").toLowerCase();
const mediaType = contentType.split(";", 1)[0].trim();
const textual = contentType.startsWith("text/") || contentType.includes("json") || contentType.includes("xml") || ["application/javascript", "application/x-www-form-urlencoded", "application/graphql"].includes(mediaType);
if (textual) {
const responseText = new TextDecoder().decode(responseBytes);
let data = responseText;
if (contentType.includes("json")) {
try { data = JSON.parse(responseText); } catch { /* Keep the raw body. */ }
}
console.log(data);
} else {
console.log(`Received ${responseBytes.byteLength} binary bytes`);
}
}java
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.time.Duration;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;
public class Main {
public static void main(String[] args) throws Exception {
final String BASE_URL = "https://api.justoneapi.com"; // Provided by OpenAPI servers
final String url = BASE_URL + "/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE";
HttpClient client = HttpClient.newBuilder().connectTimeout(Duration.ofSeconds(120)).build();
HttpRequest.Builder builder = HttpRequest.newBuilder()
.uri(URI.create(url))
.timeout(Duration.ofSeconds(120))
.method("GET", HttpRequest.BodyPublishers.noBody());
HttpRequest request = builder.build();
HttpResponse<byte[]> response = client.send(request, HttpResponse.BodyHandlers.ofByteArray());
System.out.println(response.statusCode());
String contentType = response.headers().firstValue("content-type").orElse("").toLowerCase();
String mediaType = contentType.split(";", 2)[0].trim();
if (contentType.startsWith("text/") || contentType.contains("json") || contentType.contains("xml") || mediaType.equals("application/javascript") || mediaType.equals("application/x-www-form-urlencoded") || mediaType.equals("application/graphql")) {
System.out.println(new String(response.body(), StandardCharsets.UTF_8));
} else {
Files.write(Path.of("response.bin"), response.body());
System.out.println("Saved " + response.body().length + " bytes to response.bin");
}
}
}go
package main
import (
"fmt"
"io"
"os"
"strings"
"net/http"
"time"
)
const BASE_URL = "https://api.justoneapi.com" // Provided by OpenAPI servers
func main() {
client := &http.Client{Timeout: 120 * time.Second}
url := BASE_URL + "/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE"
req, _ := http.NewRequest("GET", url, nil)
resp, _ := client.Do(req)
defer resp.Body.Close()
fmt.Println(resp.StatusCode)
bodyBytes, _ := io.ReadAll(resp.Body)
contentType := strings.ToLower(resp.Header.Get("Content-Type"))
mediaType := strings.TrimSpace(strings.SplitN(contentType, ";", 2)[0])
if strings.HasPrefix(contentType, "text/") || strings.Contains(contentType, "json") || strings.Contains(contentType, "xml") || mediaType == "application/javascript" || mediaType == "application/x-www-form-urlencoded" || mediaType == "application/graphql" {
fmt.Println(string(bodyBytes))
} else {
os.WriteFile("response.bin", bodyBytes, 0600)
fmt.Printf("Saved %d bytes to response.bin\n", len(bodyBytes))
}
}php
<?php
$BASE_URL = 'https://api.justoneapi.com'; // Provided by OpenAPI servers
$url = $BASE_URL . '/api/1688/get-item-detail/v1?token=YOUR_API_KEY&itemId=VALUE';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 120);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
$response = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
$contentType = strtolower((string) curl_getinfo($ch, CURLINFO_CONTENT_TYPE));
curl_close($ch);
echo $status . PHP_EOL;
$mediaType = trim(explode(';', $contentType, 2)[0]);
if (str_starts_with($contentType, 'text/') || str_contains($contentType, 'json') || str_contains($contentType, 'xml') || in_array($mediaType, ['application/javascript', 'application/x-www-form-urlencoded', 'application/graphql'], true)) {
echo $response;
} else {
file_put_contents('response.bin', $response);
echo 'Saved ' . strlen($response) . ' bytes to response.bin' . PHP_EOL;
}Response Fields
Key fields in a successful response (code = 0).
Product and storefront15 fields
data
When data is an object, these fields describe the requested 1688 product. A successful response with no product details can contain an empty string.
| Field | Type | Description |
|---|---|---|
item | object | Basic product information and the merchant’s displayed store details. |
item.offerId | string | 1688 product offer ID, returned as text. |
item.offerTitle | string | Display title of the product offer. |
item.companyName | string | Business name displayed for the merchant. |
item.winportUrl | string | Storefront link displayed for the merchant. |
item.defaultOfferImg | string | Link to the default display image for the product. |
item.offerUnit | string | Sales unit displayed for the product. |
item.saleOut | boolean | Whether the product is marked as sold out. |
item.price | string | Price display text reported with the product summary. |
item.saledCount | integer | Sales quantity reported in the product information. |
item.saledCountStr | string | Sales quantity display text reported for the product. |
item.topCategoryId | string | Top-level category ID reported for the product, returned as text. |
item.postCategoryId | string | Listing category ID reported for the product, returned as text. |
item.businessType | string | Business type label reported for this listing. |
item.consignOffer | boolean | Whether the listing is marked as a consignment offer. |
Product images and video45 fields
data
| Field | Type | Description |
|---|---|---|
mainPic | object | Product picture group returned for listings using this media layout. |
mainPic.offerId | string | 1688 product offer ID, returned as text. |
mainPic.isPrivacy | boolean | Whether the media group is marked as private. |
mainPic.videoUrl | string | Video link reported for the media group. The string can be empty. |
mainPic.videoId | integer | Numeric video ID returned for the media group. |
mainPic.offerImgList | array | Product image links within this media group. |
mainPic.offerImgList[] | string | Link to one product image in the media group. |
mainPic.offerImages | array | Product images with their type labels. |
mainPic.offerImages[] | object | One image in this product media group. |
mainPic.offerImages[].imgUrl | string | Link to the product image. |
mainPic.offerImages[].type | string | Product image type code returned as text. |
mainPic.offerImages[].typeDes | string | Display description of the product image type. |
mainPic.offerInfoModel | object | Product summary included with this media group. |
mainPic.offerInfoModel.offerId | integer | 1688 product offer ID, returned as an integer. |
mainPic.offerInfoModel.title | string | Product title reported in the media group. |
mainPic.offerInfoModel.price | string | Price display text reported in the media group. |
mainPic.skuImages | array | Images associated with SKU option names. |
mainPic.skuImages[] | object | One SKU option image. |
mainPic.skuImages[].imgUrl | string | Link to the SKU option image. |
mainPic.skuImages[].name | string | Display name of the SKU option associated with this image. |
mainPic.skuImages[].type | string | Type code reported for the SKU option image. |
video | object | Video media group. It can be an empty object when product media is returned in mainPic. |
video.offerId | string | 1688 product offer ID, returned as text. |
video.isPrivacy | boolean | Whether the media group is marked as private. |
video.videoUrl | string | Video link reported for the media group. The string can be empty. |
video.videoId | integer | Numeric video ID returned for the media group. |
video.offerImgList | array | Product image links within this media group. |
video.offerImgList[] | string | Link to one product image in the media group. |
video.offerImages | array | Product images with their type labels. |
video.offerImages[] | object | One image in this product media group. |
video.offerImages[].imgUrl | string | Link to the product image. |
video.offerImages[].type | string | Product image type code returned as text. |
video.offerImages[].typeDes | string | Display description of the product image type. |
video.offerInfoModel | object | Product summary included with this media group. |
video.offerInfoModel.offerId | integer | 1688 product offer ID, returned as an integer. |
video.offerInfoModel.title | string | Product title reported in the media group. |
video.offerInfoModel.price | string | Price display text reported in the media group. |
images | array | Product image entries with reported URL variants. |
images[] | object | One product image entry. |
images[].imageURI | string | Main URI reported for the product image. |
images[].fullPathImageURI | string | Full image URI reported for the product image. |
images[].size220x220ImageURI | string | Image URI reported for the 220×220 variant field. |
images[].size310x310ImageURI | string | Image URI reported for the 310×310 variant field. |
images[].searchImageURI | string | Image URI reported for use in search displays. |
images[].summImageURI | string | Summary-size image URI returned for the product. |
Description and attributes23 fields
data
| Field | Type | Description |
|---|---|---|
title | object | Heading text and display badges for the product. |
title.offerId | integer | 1688 product offer ID, returned as an integer. |
title.title | string | Title displayed in the product heading. |
title.selledNumber | string | Sales display text shown near the title. |
title.wantBuy | string | Purchase-interest text shown near the title, when returned. |
title.tagList | array | Tags displayed near the title. The array can be empty. |
title.tagList[] | string | Text of a displayed product tag. |
title.scrollList | array | Scrolling display text returned for the product heading. |
title.scrollList[] | object | One displayed text entry in the heading. |
title.scrollList[].prefix | string | Text shown before the main label. |
title.scrollList[].text | string | Main text of the displayed heading entry. |
title.scrollList[].suffix | string | Text shown after the main label. |
description | object | Extended product description information. |
description.detailUrl | string | Platform link to the extended product description. |
description.isUseNewDetail | boolean | Whether the product description uses the newer detail format. |
attribute | object | Product attribute information and displayed values. |
attribute.offerId | integer | 1688 product offer ID, returned as an integer. |
attribute.title | string | Heading displayed for the product attributes. |
attribute.propsList | array | Attribute names and values shown for the product. |
attribute.propsList[] | object | One displayed product attribute. |
attribute.propsList[].name | string | Display name of the product attribute. |
attribute.propsList[].value | string | Display value of the product attribute. |
attribute.propsList[].show | boolean | Whether the attribute is marked for display. |
Pricing and quantity tiers18 fields
data
| Field | Type | Description |
|---|---|---|
price | object | Product pricing, display units, and quantity tiers. |
price.displayType | string | Price display type label returned for the product. |
price.unit | string | Unit displayed next to the product price. |
price.priceModel | object | Price tiers reported by quantity for the product. |
price.priceModel.priceDisplayType | string | Display type code in the price model. |
price.priceModel.currentPrices | array | Current price tiers by order quantity. |
price.priceModel.currentPrices[] | object | One price tier for a starting order quantity. |
price.priceModel.currentPrices[].price | string | Price for this quantity tier, returned as display text. |
price.priceModel.currentPrices[].beginAmount | integer | Starting order quantity for the price tier. |
price.priceModel.originalPrices | array | Original price tiers by order quantity, when present. |
price.priceModel.originalPrices[] | object | One price tier for a starting order quantity. |
price.priceModel.originalPrices[].price | string | Price for this quantity tier, returned as display text. |
price.priceModel.originalPrices[].beginAmount | integer | Starting order quantity for the price tier. |
price.priceModel.originalPriceDisplay | string | Original price display text, when present. |
price.priceModel.currentPricesWithOnePiece | array | Current quantity tiers that include one-piece pricing, when present. |
price.priceModel.currentPricesWithOnePiece[] | object | One price tier for a starting order quantity. |
price.priceModel.currentPricesWithOnePiece[].price | string | Price for this quantity tier, returned as display text. |
price.priceModel.currentPricesWithOnePiece[].beginAmount | integer | Starting order quantity for the price tier. |
Coupons and promotions27 fields
data
| Field | Type | Description |
|---|---|---|
coupon | object | array | Coupon information when available. Responses can also return an empty array here. |
coupon.offerId | integer | 1688 product offer ID, returned as an integer. |
coupon.buttonName | string | Label of the coupon action button. |
coupon.pageName | string | Display name of the coupon section. |
coupon.couponRuleLinkText | string | Display text for the coupon rules link. |
coupon.couponList | array | Coupon labels included in the listing. |
coupon.couponList[] | object | One coupon display label. |
coupon.couponList[].couponType | string | Type code reported for this coupon. |
coupon.couponList[].couponContent | string | Text displayed for this coupon. |
coupon.couponInfoList | array | Detailed coupon display groups, when returned. |
coupon.couponInfoList[] | object | One detailed coupon display group. |
coupon.couponInfoList[].name | string | Display name of the coupon group. |
coupon.couponInfoList[].summary | string | Display summary of the coupon group. |
coupon.couponInfoList[].buttonName | string | Label of the coupon group action button. |
coupon.couponInfoList[].type | string | Type code reported for the coupon group. |
coupon.couponInfoList[].promotionItems | array | Promotion entries included in this coupon display group. |
coupon.couponInfoList[].promotionItems[] | object | One coupon promotion entry. |
coupon.couponInfoList[].promotionItems[].summary | string | Summary text displayed for the promotion. |
coupon.couponInfoList[].promotionItems[].label | string | Display label reported for the promotion. |
coupon.couponInfoList[].promotionItems[].promotionDisplayName | string | Promotion name shown in the coupon display. |
coupon.couponInfoList[].promotionItems[].availablePeriod | string | Availability period shown for the promotion. |
coupon.couponInfoList[].promotionItems[].startTime | string | Promotion start time returned as text. |
coupon.couponInfoList[].promotionItems[].endTime | string | Promotion end time returned as text. |
coupon.couponInfoList[].promotionItems[].detail | string | Detailed display text for the promotion. |
coupon.couponInfoList[].promotionItems[].discountFee | string | Discount amount reported as display text. |
coupon.couponInfoList[].promotionItems[].applied | boolean | Whether the promotion is marked as applied. |
coupon.couponInfoList[].promotionItems[].canApply | boolean | Whether the promotion is marked as available to apply. |
Shipping and protection30 fields
data
| Field | Type | Description |
|---|---|---|
delivery | object | Shipping and buyer protection information reported for the listing. |
delivery.offerId | integer | 1688 product offer ID, returned as an integer. |
delivery.location | string | Shipping origin displayed for the product. |
delivery.logistics | string | Logistics display text returned for the product. |
delivery.deliveryLimitTxt | string | Display text for the reported delivery or dispatch commitment. |
delivery.postFree | boolean | Whether shipping is marked as free in this response. |
delivery.postFeeValue | integer | Numeric shipping fee value reported for this listing. |
delivery.templateId | integer | Identifier of the reported shipping template. |
delivery.unitWeight | integer | Unit weight value reported for shipping. |
delivery.skuWeight | object | Weight values keyed by the reported SKU identifiers. |
delivery.skuWeight.{key} | number | Weight value reported for this SKU key. |
delivery.deliveryLimitTimeModel | object | Details of the delivery-time commitment returned for the listing. |
delivery.deliveryLimitTimeModel.limitTimeDay | integer | Day count reported for the delivery-time limit. |
delivery.deliveryLimitTimeModel.limitTimeDesc | string | Display description of the delivery-time limit. |
delivery.deliveryLimitTimeModel.expectTimeDesc | string | Display description of the expected dispatch time. |
delivery.protectionInfos | array | Protection services included in the delivery information. |
delivery.protectionInfos[] | object | One displayed service or protection entry. |
delivery.protectionInfos[].serviceName | string | Display name of the service. |
delivery.protectionInfos[].serviceCode | string | Code reported for the service. |
delivery.protectionInfos[].description | string | Display description of the protection service. |
delivery.protectionInfos[].longDescription | string | Longer description of the protection service. |
delivery.protectionInfos[].buyerDescription | string | Buyer-facing description of the protection service. |
delivery.protectionInfos[].agreeDeliveryHours | integer | Agreed delivery time reported in hours, when returned. |
delivery.buyerProtectionModel | array | Additional buyer protection entries displayed with delivery. |
delivery.buyerProtectionModel[] | object | One displayed service or protection entry. |
delivery.buyerProtectionModel[].serviceName | string | Display name of the service. |
delivery.buyerProtectionModel[].serviceCode | string | Code reported for the service. |
delivery.buyerProtectionModel[].enabled | boolean | Whether the buyer protection entry is marked enabled. |
delivery.buyerProtectionModel[].shortBuyerDesc | string | Short description displayed to the buyer. |
delivery.buyerProtectionModel[].textDesc | string | Display description for the buyer protection entry. |
Services and purchase options21 fields
data
| Field | Type | Description |
|---|---|---|
service | object | Services and descriptions displayed for the product. |
service.offerId | integer | 1688 product offer ID, returned as an integer. |
service.service1 | string | First service display label returned for the product. |
service.service2 | string | Second service display label, when returned. |
service.service3 | string | Third service display label, when returned. |
service.serviceDetail | array | Detailed information about displayed services. |
service.serviceDetail[] | object | One displayed service or protection entry. |
service.serviceDetail[].serviceName | string | Display name of the service. |
service.serviceDetail[].serviceCode | string | Code reported for the service. |
service.serviceDetail[].description | string | Description displayed for the service. |
service.serviceDesc | array | Service descriptor entries included in the listing. |
service.serviceDesc[] | object | One displayed service or protection entry. |
service.serviceDesc[].serviceName | string | Display name of the service. |
service.serviceDesc[].serviceCode | string | Code reported for the service. |
service.serviceDesc[].type | string | Type label reported for this service descriptor. |
order | object | Displayed purchase modes for the listing. |
order.sceneList | array | Purchase modes displayed for the product. |
order.sceneList[] | object | One displayed purchase option. |
order.sceneList[].sceneName | string | Display name of the purchase mode. |
order.selectedScene | object | Purchase mode marked as selected in the listing. |
order.selectedScene.sceneName | string | Display name of the selected purchase mode. |
Response Example
Loading the response example...