1. 商品相关
Shanjing Ecommerce Api
latest
  • latest
  • 🇺🇸 English
  • 接入指南
    • 平台概述
    • 成为开发者
  • 淘宝&天猫 API
    • 鉴权
      • 获取 Token
      • 刷新 Token
    • 商品相关
      • 获取淘宝/天猫商品详情接口
        GET
      • 淘宝/天猫商品关键词搜索接口
        GET
      • 淘宝/天猫图片搜索同款商品接口
        GET
      • 上传图片到淘宝/天猫用于图搜商品
        POST
    • 订单相关
      • 淘宝/天猫撞库接口
      • 淘宝/天猫预创建订单接口
      • 淘宝/天猫正式创建订单接口
      • 淘宝/天猫取消订单接口
      • 淘宝/天猫查询订单接口
  1. 商品相关

上传图片到淘宝/天猫用于图搜商品

POST
/rest/taobao-global/upload/image
请通过POST方式,提交image_base64,获取imageId,用于后续的图片搜索接口,Base64编码必须是 jpg、jpeg、png、webp 格式的图像文件编码,大小上限为3MB。

Request

Authorization
Bearer Token
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
or
Header Params

Body Params multipart/form-data

Request Code Samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location 'https://ecommerce-api.shanjing-inc.com/rest/taobao-global/upload/image' \
--header 'x-app-key;' \
--header 'x-timestrap;' \
--header 'x-sign-method;' \
--header 'x-signature;' \
--header 'x-access-token;' \
--header 'Authorization: Bearer <token>' \
--form 'image_base64="图片Base64串";type=false'

Responses

🟢200成功
application/json
Bodyapplication/json

Example
{
    "errorCode": "string",
    "errorMsg": "string",
    "data": {
        "imageId": "string"
    }
}
🟢200接口异常错误
Modified at 2026-03-14 05:37:03
Previous
淘宝/天猫图片搜索同款商品接口
Next
淘宝/天猫撞库接口
Built with