Upload file

Note:

  • For APIs used for Shop, the API key is: <api_key>. The base_url information of the Shop.

  • For APIs used for Partner, the API key is: <shop_key>. The base_url information of the Partner.

Request:

curl --location '$BASE_URL.OA/UploadFile' \
--header 'Authorization: Bearer $API_KEY' \
--form 'type="image"' \
--form 'oa_id="<int64>"' \
--form 'file=@"/path/to/file"'

Response:

{
    "token": "string"
}

Request body structure

Parameters
Data type
Describe

type

string

data type

id

int64

OA ID

Return data attribute structure

Parameters
Data type
Describe

token

string

File/image token, used for API sending file/image messages

Last updated