Skip to content

Upload Image for Buyer Messages

POST
/customer_service/202309/images/upload

You must use this API to upload the image first, before sending an image as a message using Send Message.

shop_cipher
required
string

Identifies the shop. Obtain it from the Get Authorized Shops API.

Media typemultipart/form-data
object
data
required

The format of the image must be jpg, gif, webp, or png. The size of the image must not exceed 10MB.

string format: binary

Success

Media typeapplication/json
object
code

Status code; 0 means success.

integer format: int64
message

Success or failure message.

string
request_id

Request log ID.

string
data
object
url

Image URL

string
width

Width of the uploaded image in pixels.

integer format: int64
height

Height of the uploaded image in pixels.

integer format: int64
Example
{
"code": 0,
"data": {
"url": "https://p16-oec-va.ibyteimg.com/tos-maliva-i-o3syd03w52-us/2ca53c34ad8443e6b39f4e0153d3aed4~tplv-o3syd03w52-origin-image.image?from=1320446476",
"width": 1280,
"height": 720
},
"message": "Success",
"request_id": "202203070749000101890810281E8C70B7"
}