使用1688開放平臺API介面獲取商品詳情資訊
摘要:本文將介紹如何使用1688開放平臺的API介面來獲取商品詳情資訊。透過呼叫這些介面,您可以方便地獲取商品的基本資訊、價格、庫存等資料,為您的業務提供強大的支援。
一、API介面簡介
1688開放平臺提供了豐富的API介面,幫助開發者快速實現各種業務需求。其中,商品詳情資訊的獲取是很多業務場景中的基礎功能。透過呼叫相應的API介面,您可以獲取到商品的基本資訊、價格、庫存等資料,為您的業務提供強大的支援。
二、API介面請求方式
1688開放平臺的API介面採用了RESTful設計風格,您可以透過HTTP協議的GET和POST方法來呼叫這些介面。為了確保資料的安全性,建議您使用HTTPS協議進行請求。
三、獲取商品詳情資訊的API介面
要獲取商品詳情資訊,您需要呼叫以下API介面:
- 商品詳細資訊查詢介面(product_get):透過商品ID獲取商品的詳細資訊。
- 商品屬性查詢介面(product_attribute_get):透過商品ID和屬性ID獲取商品的屬性值。
- 商品圖片查詢介面(product_image_get):透過商品ID和圖片型別獲取商品的圖片資訊。
四、API介面引數說明
1688.item_get
公共引數
名稱
|
型別
|
必須
|
描述
|
key
|
String
|
是
|
呼叫key(
,必須以GET方式拼接在URL中)
|
secret
|
String
|
是
|
呼叫金鑰
|
api_name
|
String
|
是
|
API介面名稱(包括在請求地址中)[item_search,item_get,item_search_shop等]
|
cache
|
String
|
否
|
[yes,no]預設yes,將呼叫快取的資料,速度比較快
|
result_type
|
String
|
否
|
[json,jsonu,xml,serialize,var_export]返回資料格式,預設為json,jsonu輸出的內容中文可以直接閱讀
|
lang
|
String
|
否
|
[cn,en,ru]翻譯語言,預設cn簡體中文
|
version
|
String
|
否
|
API版本
|
請求引數
請求引數:num_iid=555696089192
引數說明:num_iid:1688商品ID
sales_data:&sales_data=1 獲取近30天成交資料
agent:&agent=1 獲取1688分銷代發價格資料
響應引數
Version: Date:
名稱
|
型別
|
必須
|
示例值
|
描述
|
item |
item[]
|
0
|
|
寶貝詳情資料
|
num_iid |
String
|
0
|
|
寶貝ID
|
title |
String
|
0
|
|
商品標題
|
desc_short |
String
|
0
|
|
商品簡介
|
price |
Float
|
0
|
|
價格
|
total_price |
Float
|
0
|
|
|
suggestive_price |
Float
|
0
|
|
|
orginal_price |
Float
|
0
|
|
原價
|
nick |
String
|
0
|
|
賣家暱稱
|
num |
Int
|
0
|
|
|
detail_url |
String
|
0
|
|
寶貝連結
|
pic_url |
String
|
0
|
|
寶貝圖片
|
brand |
String
|
0
|
|
品牌
|
brandId |
Int
|
0
|
|
品牌id
|
rootCatId |
Int
|
0
|
|
頂 級分類ID
|
cid |
Int
|
0
|
|
|
desc |
String
|
0
|
|
|
item_imgs |
Mix
|
0
|
|
商品圖片
|
item_weight |
String
|
0
|
|
|
post_fee |
Float
|
0
|
|
郵費
|
express_fee |
Float
|
0
|
|
EMS費用
|
ems_fee |
Float
|
0
|
|
物流費用
|
shipping_to |
String
|
0
|
|
發貨至
|
video |
video[]
|
0
|
|
商品影片
|
sample_id |
String
|
0
|
|
|
props_name |
String
|
0
|
|
商品屬性名
|
prop_imgs |
prop_imgs[]
|
0
|
|
商品屬性圖片列表
|
property_alias |
String
|
0
|
|
屬性別名
|
props |
Mix
|
0
|
|
商品詳情
|
total_sold |
Int
|
0
|
|
|
scale |
Int
|
0
|
|
|
sellUnit |
Int
|
0
|
|
|
skus |
skus[]
|
0
|
|
商品規格資訊列表
|
seller_id |
Int
|
0
|
|
賣家ID
|
sales |
Int
|
0
|
|
銷售額
|
shop_id |
Int
|
0
|
|
店鋪ID
|
props_list |
Mix
|
0
|
|
商品屬性
|
seller_info |
seller_info[]
|
0
|
|
賣家資訊
|
tmall |
Boolean
|
0
|
|
是否天貓
|
data_from |
String
|
0
|
|
錯誤資訊
|
error |
String
|
0
|
|
錯誤資訊
|
unit |
String
|
0
|
|
單位
|
is_support_mix |
Boolean
|
0
|
|
|
mix_amount |
Int
|
0
|
|
|
mix_Begin |
Int
|
0
|
|
|
mix_number |
Int
|
0
|
|
|
sales_data |
Date
|
0
|
|
|
location |
String
|
0
|
|
發貨地
|
props_img |
Mix
|
0
|
|
屬性圖片
|
sales_info |
Mix
|
0
|
|
|
desc_img |
Mix
|
0
|
|
詳情圖片列表
|
shop_item |
Mix
|
0
|
|
|
relate_items |
Mix
|
0
|
|
|
五、API介面返回結果示例
- 商品詳細資訊查詢介面(product_get)返回結果示例:
Result Object: --------------------------------------- { "item": { "num_iid": "555696089192", "title": "秋冬中長款毛衣套頭女韓版寬鬆蝙蝠袖針織衫加厚外套高領冬季女裝", "desc_short": "", "price": "65.00", "total_price": 0, "suggestive_price": 0, "orginal_price": "65.00", "nick": "彤彤毛衫工廠店", "num": "5111", "min_num": "1", "detail_url": "https://detail.1688.com/offer/555696089192.html", "pic_url": " "brand": "", "brandId": "", "rootCatId": "10166", "cid": "127386001", "crumbs": [], "created_time": "", "modified_time": "", "delist_time": "", "desc": "<div id=\"offer-template-0\"></div><p></p>\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td colspan=\"3\">\r\n<div ><strong >店鋪推薦</strong><img src=\"\" width=\"25%\"/></div>\r\n</td>\r\n</tr>\r\n<tr>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥55.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥65.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥55.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n</tr>\r\n<tr>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥68.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥62.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥60.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n</tr>\r\n<tr>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥63.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥62.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n<td >\r\n<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" >\r\n<tbody>\r\n<tr>\r\n<td align=\"center\"><img src=\"!!6000000001413-0-cib.310x310.jpg\" width=\"100%\"/></td>\r\n</tr>\r\n<tr>\r\n<td align=\"center\" ><span >搶購價</span><span >¥63.00</span><img src=\"\" width=\"60%\"/></td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n</td>\r\n</tr>\r\n</tbody>\r\n</table>\r\n<p></p>\r\n<div>\r\n<div >\r\n<div><img src=\"\" alt=\"undefined\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"undefined\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"11802556403_1110747443\" width=\"790\" height=\"790\"/><br/><br/><img src=\"\" alt=\"11766705266_1110747443\"/></div>\r\n</div>\r\n</div><img src=\"\" style=\"display:none\" />", "desc_img": [ "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "!!6000000001413-0-cib.310x310.jpg", "", "", "", "", " "", "", "", "", "", "", "", "", "", "" ], "item_imgs": [ { "url": "" }, { "url": "" }, { "url": "" }, { "url": "" }, { "url": "!!2669477471-0-cib.jpg" } ], "item_weight": "", "item_size": "", "location": "浙江省嘉興市", "post_fee": 4, "express_fee": "", "ems_fee": "", "shipping_to": "", "has_discount": "", "video": " "is_virtual": "", "sample_id": "", "is_promotion": "", "props_name": "0:0:顏色:紅色;0:1:顏色:黑色;1:0:尺碼:一件可拍 均碼", "prop_imgs": { "prop_img": [ { "properties": "0:0", "url": "" }, { "properties": "0:1", "url": "" } ] }, "property_alias": "0:0:紅色;0:1:黑色;1:0:一件可拍 均碼", "props": [ { "name": "貨號", "show": false, "value": "HH-158-100" }, { "name": "面料名稱", "show": false, "value": "針織混紡" }, { "name": "主面料成分2", "show": false, "value": "聚酯纖維(滌綸)" }, { "name": "主面料成分", "show": false, "value": "腈綸" }, { "name": "圖案", "show": false, "value": "純色" }, { "name": "厚薄", "show": false, "value": "厚" }, { "name": "組合形式", "show": false, "value": "單件" }, { "name": "款式", "show": false, "value": "套頭" }, { "name": "版型", "show": false, "value": "寬鬆型" }, { "name": "袖型", "show": false, "value": "常規袖" }, { "name": "上市年份/季節", "show": false, "value": "2023年秋季" }, { "name": "領型", "show": false, "value": "圓領" }, { "name": "袖長", "show": false, "value": "長袖" }, { "name": "流行元素", "show": false, "value": "螺紋" }, { "name": "衣長", "show": false, "value": "中長款(65cm<衣長≤80cm)" }, { "name": "工藝", "show": false, "value": "拼貼/拼接" }, { "name": "顏色", "show": false, "value": "紅色,黑色" }, { "name": "尺碼", "show": false, "value": "一件可拍 均碼" }, { "name": "風格型別", "show": false, "value": "氣質通勤" }, { "name": "穿著方式", "show": false, "value": "套頭" }, { "name": "主面料成分含量", "show": false, "value": "50%(不含)-70%(含)" }, { "name": "門襟", "show": false, "value": "套頭" }, { "name": "風格", "show": false, "value": "英倫風" }, { "name": "是否跨境貨源", "show": false, "value": "否" } ], "total_sold": null, "skus": { "sku": [ { "price": "65.00", "total_price": 0, "sales": "4297", "properties": "0:0;1:0", "properties_name": "0:0:顏色:紅色;1:0:尺碼:一件可拍 均碼", "quantity": "1589", "sku_id": "4730262673752", "spec_id": "5662a10e8283586509b22afca62d332b" }, { "price": "65.00", "total_price": 0, "sales": "2362", "properties": "0:1;1:0", "properties_name": "0:1:顏色:黑色;1:0:尺碼:一件可拍 均碼", "quantity": "3522", "sku_id": "4730262673753", "spec_id": "7cb4420f14f7a9ae00c0255d75ff75b4" } ] }, "seller_id": "2669477471", "sales": 1790, "shop_id": "2669477471", "props_list": { "0:0": "顏色:紅色", "0:1": "顏色:黑色", "1:0": "尺碼:一件可拍 均碼" }, "seller_info": { "nick": "彤彤毛衫工廠店", "user_num_id": "2669477471", "sid": "b2b-266947747195f05", "title": "嘉興市秀洲區洪合鎮美彤服裝廠", "zhuy": "https://winport.m.1688.com/page/index.html?memberId=b2b-266947747195f05", "shop_name": "彤彤毛衫工廠店" }, "tmall": "false", "error": "", "warning": "", "url_log": [], "unit": null, "is_support_mix": "true", "mix_amount": "1", "mix_begin": "0", "mix_number": "2147483647", "scale": "", "sellUnit": "件", "props_img": { "0:0": " "0:1": "" }, "sales_data": null, "priceRange": [ [ "1", "65.00" ], [ "10", "64.00" ], [ "50", "62.00" ] ], "priceRangeOriginal": [], "_ddf": "ti", "sales_info": { "seller_num": "", "repeat_rate_purchase": "", "per_capita_purchases": "", "comment_num": "", "comment_url": "" }, "format_check": "ok", "shop_item": [], "relate_items": [] }, "error": "", "secache": "95fc21debe6c629e941d808b214a3b07", "secache_time": 1700458640, "secache_date": "2023-11-20 13:37:20", "translate_status": "", "translate_time": 0, "language": { "default_lang": "cn", "current_lang": "cn" }, "reason": "", "error_code": "0000",
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/70026910/viewspace-2996163/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 獲取商品詳情資訊API介面:1688開放平臺功能解析API
- 使用商品詳情API介面獲取商品資料API
- 使用API介面獲取拼多多商品詳情API
- 用PHP使用API介面獲取蝦皮商品詳情PHPAPI
- 用Java使用API介面獲取Lazada商品詳情JavaAPI
- 獲取1688商品詳情API:步驟與程式碼示例API
- 如何使用商品詳情API介面來獲取想要的商品資料?API
- 教您如何使用API介面獲取拼多多商品詳情API
- 淘寶詳情API介面:一鍵獲取商品資訊的實踐探索API
- python批次採集1688商品詳情資料介面+1688商品列表資料介面+1688商品API資料介面PythonAPI
- 淘寶開放平臺API - 獲取單筆交易的詳細資訊API
- 1688商品詳情API跨境專用介面php javaAPIPHPJava
- 1688詳情api介面API
- 阿里巴巴國際站API詳情介面獲取商品詳情介面阿里API
- 詳情API介面上貨搬運獲取資訊API介面API
- Lazada詳情API介面:一鍵獲取商品資訊的深度實踐API
- Temu api介面 獲取商品詳情 資料採集API
- 透過1688店鋪所有商品API介面一鍵獲取店鋪所有商品資訊API
- Java語言獲取小紅書商品詳情 API介面(商品ID、商品標題等)JavaAPI
- 如何使用商品詳情API介面獲取商品資料:一篇詳盡的論述API
- 獲取淘寶商品詳情api、介面獲取寶貝詳情、產品詳細屬性示例說明API
- C++語言亞馬遜獲取AMAZON商品詳情 API介面C++亞馬遜API
- 商品詳情API介面API
- 各類電商平臺批次獲取商品資訊 API 詳細操作說明API
- 1688 API分享:抓取1688商品詳情頁資料API
- 獲取拼多多商品詳情api、介面獲取寶貝詳情、產品詳細屬性Java示例說明APIJava
- 開放平臺API介面API
- 1688商品詳情資料介面、商品列表介面,商品屬性介面、商品優惠券介面
- 如何獲得淘寶/天貓淘寶商品詳情 API介面API
- 以程式設計師的身份,教您使用API介面獲取蝦皮商品詳情程式設計師API
- 1688商品詳情APIERP選品專用API介面 Python JavaAPIPythonJava
- 阿里巴巴商品採集介面 商品詳情api 商品主圖介面 商品詳情圖介面阿里API
- Java獲取淘寶/天貓商品詳情 API介面(寶貝詳情資料、寶貝ID、寶貝標題、商品簡介等)JavaAPI
- 拼多多根據ID取商品詳情 API介面(item_get-根據ID取商品詳情)API
- 透過API介面獲取阿里巴巴商品詳情示例說明API阿里
- 使用CURL獲取速賣通詳情的API介面API
- 揭秘微店詳情API介面:引領商品資訊獲取新篇章,賦能開發者無限可能API
- 如何使用1688店鋪所有商品API介面API