LeoYeAI/agent-master-skills / skills/1688-product-search
1688-product-search
Verified1688商品搜索SKILL:提供完整的1688商品搜索能力,包括类目查询、关键词搜索、图片搜索、商品详情、相关性商品、拉取货盘底池等9个核心接口。 支持多语言搜索和商品推荐,使用1688开放平台官方API,统一鉴权,Token全局缓存共享。
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 17.9 KB |
| _meta.json | config | 295 B |
| references/api.md | markdown | 3.4 KB |
| scripts/auth.py | script | 4.2 KB |
| scripts/auth_fixed.py | script | 4.9 KB |
| scripts/fixed_image_upload.py | script | 3.5 KB |
| scripts/image_search_handler.py | script | 6.2 KB |
| scripts/image_utils.py | script | 2.7 KB |
| scripts/product_search.py | script | 27.4 KB |
| scripts/product_search_fixed.py | script | 3.8 KB |
| scripts/product_search_updated.py | script | 19.7 KB |
| scripts/smart_recommend.py | script | 3.2 KB |
references/api.md
View on GitHub# 1688 Product Search API 接口文档
## 类目查询接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/category.translation.getById/${APPKEY}
```
### 请求参数
| 参数 | 类型 | 必填 | 说明 |
|------|------|------|------|
| categoryId | string | 是 | 类目ID,0表示获取所有一级类目 |
| language | string | 否 | 语言代码,默认en |
| access_token | string | 是 | 访问令牌 |
| _aop_signature | string | 是 | 签名 |
## 关键词搜索接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.keywordQuery/${APPKEY}
```
### 请求参数
| 参数 | 类型 | 必填 | 说明 |
|------|------|------|------|
| searchParams | string | 是 | JSON格式的搜索参数 |
| access_token | string | 是 | 访问令牌 |
| _aop_signature | string | 是 | 签名 |
### searchParams 结构
```json
{
"keyword": "dress",
"country": "en",
"pageNo": 1,
"pageSize": 20,
"filter": "shipIn48Hours,certifiedFactory",
"sort": "{\"price\":\"asc\"}"
}
```
## 图片搜索接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.imageQuery/${APPKEY}
```
### searchParams 结构
```json
{
"imageId": "your_image_id",
"country": "en",
"pageNo": 1,
"pageSize": 20
}
```
## 商品详情接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.queryProductDetail/${APPKEY}
```
### detailParams 结构
```json
{
"offerIds": ["offer_id1", "offer_id2"],
"country": "en"
}
```
## 店铺搜索接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.shopSearch/${APPKEY}
```
### searchParams 结构
```json
{
"sellerOpenId": "seller_open_id",
"country": "en",
"pageNo": 1,
"pageSize": 20
}
```
## 商品推荐接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.offerRecommend/${APPKEY}
```
### recommendParams 结构
```json
{
"keyword": "dress",
"country": "en",
"pageNo": 1,
"pageSize": 20
}
```
## 搜索导航接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.search.keywordSNQuery/${APPKEY}
```
### navParams 结构
```json
{
"keyword": "dress",
"country": "en"
}
```
## 相关推荐接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.related.recommend/${APPKEY}
```
### recommendParams 结构
```json
{
"offerId": "offer_id",
"country": "en",
"pageNo": 1,
"pageSize": 20
}
```
## 图片上传接口
### 请求地址
```
POST https://gw.open.1688.com/openapi/param2/1/com.alibaba.fenxiao.crossborder/product.image.upload/${APPKEY}
```
### uploadParams 结构
```json
{
"imageBase64": "base64_encoded_image_data"
}
```
## 签名规则
1. 将所有请求参数(除_aop_signature外)按key的字母顺序排序
2. 将排序后的参数拼接成字符串:`key1value1key2value2...`
3. 在拼接字符串前加上URL路径(从param2开始)
4. 对结果进行HMAC-SHA1加密,并转换为大写十六进制
## 错误码
| 错误码 | 说明 |
|--------|------|
| gw.SignatureInvalid | 签名无效 |
| gw.ParamMissing | 参数缺失 |
| 401 | 未授权/Token无效 |
| 400 | 参数错误 |
| 403 | 无权限调用 |Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |