AliExpress
AliExpress 商品详情
单个 AliExpress 商品:各 SKU 价格和库存、规格参数、运费和送达天数、销量、心愿单数和卖家评分。
API 数据样例
直接查看该接口实际使用的请求体和完整响应结构。
{
"productId": "3256813302984638"
}{
"request_id": "d08e8a35-4e1b-4c9e-bb54-9aba2deaa96d",
"data": {
"url": "https://www.aliexpress.com/item/3256813302984638.html",
"price": 241.64,
"title": "24 Pieces 0.4 in Thick Interlocking Floor Mats, 23.6x23.6 in EVA Foam Fitness Tiles – Non-Slip Home Gym Mats with Rubber Top for Workout, Yoga, Playroom, Office",
"video": null,
"images": [
"https://ae-pic-a1.aliexpress-media.com/kf/S2d09e0fb6f454e61a5757b412a587933G.jpg_960x960.jpg",
"https://ae-pic-a1.aliexpress-media.com/kf/S3ef95b419e8243cfb5e1d91a598af81ea.jpg_960x960.jpg"
],
"rating": null,
"options": [
{
"name": "Ships From",
"values": [
"United States"
]
}
],
"store_id": "1104265660",
"currency": "USD",
"ship_from": "United States",
"variants": [
{
"image": null,
"price": 241.64,
"sku_id": "12000061321190160",
"in_stock": true,
"attributes": {
"Ships From": "United States"
},
"original_price": 891.55,
"quantity_available": 9
}
],
"product_id": "3256813302984638",
"sold_count": 1,
"store_name": "LuxMark Department Stores Store",
"seller_level": "14-s",
"seller_score": 176,
"free_shipping": true,
"return_policy": null,
"reviews_count": 0,
"shipping_cost": 0,
"original_price": 891.55,
"seller_country": "China",
"wishlist_count": 4,
"specifications": [
{
"name": "High-concerned chemical",
"value": "None"
},
{
"name": "Origin",
"value": "Mainland China"
}
],
"delivery_days_max": 8,
"delivery_days_min": 2,
"seller_opened_at": "2024-11-01T00:00:00.000Z",
"is_top_rated_seller": false,
"quantity_available": 9,
"seller_feedback_count": 244,
"seller_feedback_percent": 88.2
}
}可用状态:已开放
该接口已进入 v1 网关、OpenAPI 和订阅权限目录,每次调用消耗 1 个计费单位,查不到数据(
RESULT_NOT_FOUND)也照常计费。
POST /v1/aliexpress/products/detail
下方请求和响应字段已与当前公开契约核对。
MCP 调用
| 项目 | 内容 |
|---|---|
| MCP Code | aliexpress_products_detail |
快速调用
先创建 API 密钥,再将密钥写入服务端环境变量:
export ECOMMERCE_DATA_API_KEY="your_api_key"curl --request POST \
--url https://ecommercedataapi.com/v1/aliexpress/products/detail \
--header "Content-Type: application/json" \
--header "X-API-Key: ${ECOMMERCE_DATA_API_KEY}" \
--data '{
"productId": "3256813302984638"
}'使用 AI CLI 接入
复制给 AI CLI
粘贴到 Codex、Claude Code、Gemini CLI 或其他编程智能体中直接完成接入。
请直接在当前代码库中接入 Ecommerce Data API 的「AliExpress 商品详情」接口,不要只给示例代码。
接口文档:https://ecommercedataapi.com/zh/docs/aliexpress/detail
请求接口:POST https://ecommercedataapi.com/v1/aliexpress/products/detail
API 密钥环境变量:ECOMMERCE_DATA_API_KEY
请求示例:
{
"productId": "3256813302984638"
}
请按以下要求执行:
1. 先阅读接口文档,并检查当前项目使用的语言、框架、HTTP 客户端、目录结构和环境变量约定。
2. 优先复用项目现有的 API 客户端和错误处理方式;如果没有,再创建最小可复用的 Ecommerce Data API 客户端与该接口调用封装。
3. 从服务端环境变量 ECOMMERCE_DATA_API_KEY 读取密钥,发送 Content-Type: application/json 和 X-API-Key 请求头。绝不能把真实密钥写入源码、前端代码、日志、测试快照或 Git。
4. 如果环境变量不存在,提示我自行设置 ECOMMERCE_DATA_API_KEY;不要索取、输出或猜测真实密钥,并继续完成不依赖真实请求的代码与测试。
5. 根据接口文档实现请求与响应类型,处理非 2xx 响应、request_id、error.code、error.message 和 429 限流。
6. 添加一个符合当前项目习惯的最小调用示例或测试。如果密钥已配置且当前环境允许外部请求,再执行一次最小真实调用;否则使用 mock 或静态验证。
7. 运行相关格式化、类型检查和测试,最后汇报修改文件、调用方法、验证结果以及仍需我配置的环境变量。还没有 API 密钥?创建 API 密钥
在 Postman 中打开当前请求
下载当前接口的预配置 Collection,再通过 Postman Import 导入。
导入后在 Collection Variables 中填写 apiKey。创建 API 密钥
Node.js 示例
const response = await fetch(
'https://ecommercedataapi.com/v1/aliexpress/products/detail',
{
method: 'POST',
headers: {
'Content-Type': 'application/json',
'X-API-Key': process.env.ECOMMERCE_DATA_API_KEY,
},
body: JSON.stringify({
productId: '3256813302984638',
}),
}
);
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.error?.code}: ${result.error?.message}`);
}
console.log(result.data);Python 示例
import os
import requests
response = requests.post(
"https://ecommercedataapi.com/v1/aliexpress/products/detail",
headers={
"Content-Type": "application/json",
"X-API-Key": os.environ["ECOMMERCE_DATA_API_KEY"],
},
json={
"productId": "3256813302984638",
},
timeout=30,
)
response.raise_for_status()
print(response.json()["data"])请求参数
请求体直接发送下表字段,不要再包裹额外对象;未定义字段会被拒绝。
| 字段 | 类型 | 必填 | 说明 | 示例 |
|---|---|---|---|---|
productId | 字符串 | 是 | AliExpress 商品 ID,即商品链接中的数字。 | 3256806808957451 |
shipTo | 字符串 | 否 | 收货国家,ISO 代码如 US、DE,影响价格、库存和送达天数。 | US |
currency | 字符串 | 否 | 价格币种,ISO 代码如 USD、EUR。 | USD |
返回结构
| 字段 | 类型 | 说明 |
|---|---|---|
request_id | 字符串 | 本次请求的唯一标识。 |
data | 对象 | 接口业务数据。 |
下表字段位于 data 内。数组接口描述的是单个数组元素,分页接口描述的是 items[] 中的单条记录。
返回字段
| 字段 | 类型 | 说明 | 示例 |
|---|---|---|---|
url | 字符串 | 页面链接 | - |
price | 数字 | 价格 | 241.64 |
title | 字符串 | 标题 | - |
video | 字符串 | 视频链接(如有) | - |
images | 数组 | 图片链接 | - |
rating | 字符串 | 平均评分(满分 5) | - |
options | 数组 | 可选项及其取值 | - |
options.name | 字符串 | 选项名 | Ships From |
options.values | 数组 | 选项值 | - |
store_id | 字符串 | 店铺 ID | 1104265660 |
currency | 字符串 | 币种 | USD |
ship_from | 字符串 | 发货地 | United States |
variants | 数组 | 变体(SKU) | - |
variants.image | 字符串 | 变体图片 | - |
variants.price | 数字 | 变体价格 | 241.64 |
variants.sku_id | 字符串 | 变体 SKU ID | 12000061321190160 |
variants.in_stock | 布尔值 | 变体是否有货 | true |
variants.attributes | 对象 | 变体各选项取值 | - |
variants.original_price | 数字 | 变体折前价 | 891.55 |
variants.quantity_available | 整数 | 变体可售数量 | 9 |
product_id | 字符串 | 商品 ID | 3256813302984638 |
sold_count | 整数 | 销量(订单数) | 1 |
store_name | 字符串 | 店铺名称 | LuxMark Department Stores Store |
seller_level | 字符串 | 卖家等级 | 14-s |
seller_score | 整数 | 卖家分数 | 176 |
free_shipping | 布尔值 | 是否包邮 | true |
return_policy | 字符串 | 退货政策 | - |
reviews_count | 整数 | 评价数 | 0 |
shipping_cost | 整数 | 运费;搜索结果中为 eBay 显示的原文 | 0 |
original_price | 数字 | 折前价 | 891.55 |
seller_country | 字符串 | 卖家所在国家 | China |
wishlist_count | 整数 | 加入心愿单次数 | 4 |
specifications | 数组 | 商品规格参数 | - |
specifications.name | 字符串 | 参数名 | High-concerned chemical |
specifications.value | 字符串 | 参数值 | None |
delivery_days_max | 整数 | 最慢送达天数 | 8 |
delivery_days_min | 整数 | 最快送达天数 | 2 |
seller_opened_at | 字符串 | 开店时间,ISO 8601 | 2024-11-01T00:00:00.000Z |
is_top_rated_seller | 布尔值 | 是否优秀卖家 | false |
quantity_available | 整数 | 可售数量 | 9 |
seller_feedback_count | 整数 | 卖家信用评价数 | 244 |
seller_feedback_percent | 数字 | 卖家好评率(%) | 88.2 |
返回示例
{
"request_id": "d08e8a35-4e1b-4c9e-bb54-9aba2deaa96d",
"data": {
"url": "https://www.aliexpress.com/item/3256813302984638.html",
"price": 241.64,
"title": "24 Pieces 0.4 in Thick Interlocking Floor Mats, 23.6x23.6 in EVA Foam Fitness Tiles – Non-Slip Home Gym Mats with Rubber Top for Workout, Yoga, Playroom, Office",
"video": null,
"images": [
"https://ae-pic-a1.aliexpress-media.com/kf/S2d09e0fb6f454e61a5757b412a587933G.jpg_960x960.jpg",
"https://ae-pic-a1.aliexpress-media.com/kf/S3ef95b419e8243cfb5e1d91a598af81ea.jpg_960x960.jpg"
],
"rating": null,
"options": [
{
"name": "Ships From",
"values": ["United States"]
}
],
"store_id": "1104265660",
"currency": "USD",
"ship_from": "United States",
"variants": [
{
"image": null,
"price": 241.64,
"sku_id": "12000061321190160",
"in_stock": true,
"attributes": {
"Ships From": "United States"
},
"original_price": 891.55,
"quantity_available": 9
}
],
"product_id": "3256813302984638",
"sold_count": 1,
"store_name": "LuxMark Department Stores Store",
"seller_level": "14-s",
"seller_score": 176,
"free_shipping": true,
"return_policy": null,
"reviews_count": 0,
"shipping_cost": 0,
"original_price": 891.55,
"seller_country": "China",
"wishlist_count": 4,
"specifications": [
{
"name": "High-concerned chemical",
"value": "None"
},
{
"name": "Origin",
"value": "Mainland China"
}
],
"delivery_days_max": 8,
"delivery_days_min": 2,
"seller_opened_at": "2024-11-01T00:00:00.000Z",
"is_top_rated_seller": false,
"quantity_available": 9,
"seller_feedback_count": 244,
"seller_feedback_percent": 88.2
}
}错误响应、请求追踪和限流头说明见错误与限流。