API upload ảnh sản phẩm

POST /v1/products/upload-image — upload ảnh lên marketplace và nhận image_id để tái sử dụng trong image search.

Request body

FieldRequiredDescription
channelYes1688 | taobao
image_base64One ofẢnh Base64 (đã bỏ prefix data-URL). Bắt buộc với Taobao.
image_url1688 onlyURL công khai; server fetch khi không có base64

Ví dụ

POST /v1/products/upload-image
{
  "channel": "1688",
  "image_base64": "/9j/4AAQSkZJRg..."
}

Response

{
  "channel": "1688",
  "image_id": "img_1234567890",
  "request_id": "req_..."
}

Xem upload-image response fields.