POST Upload Product File
Upload Product File Seller Required scope: seller.product.basic Upload non-image files, such as PDF or video to TikTok Shop. Use this API when you need to add videos to your product to improve the shopping experience, or submit certifications or reports to meet TikTok Shop requirements for listing restricted products. Note: You must store the response body to retrieve the ID or URL required to associate the file with a product during product creation or editing. Version 202309
POST/product/202309/files/upload
Request
Header
| Properties | Type | Description |
|---|---|---|
| content-type Required | string | Allowed type: multipart/form-data |
| x-tts-access-token Required | string | The seller access_token value from Get Access Token, when user_type = 0. Follow this guide to get seller access_token. |
Query
| Properties | Type | Description |
|---|---|---|
| app_key Required | string | Every single app will have a unique key. Please use the specific key assigned to your app. |
| sign Required | string | Signature generated by gen algorithm. When you send API requests to TTS, you must sign them so that TTS can identify the senders. |
| timestamp Required | int | Unix timestamp GMT (UTC+00:00). This timestamp is used across all API requests. Developers can use this convert to local time. |
Body
| Properties | Type | Description |
|---|---|---|
| data Required | file | The local file to be uploaded.Note:- Supported formats: PDF, MP4, MOV, MKV, WMV, WEBM, AVI, 3GP, FLV, MPEG- Max PDF size: 20 MB- Max video size: 100 MB- Video aspect ratio: 9:16 to 16:9Recommendations for product videos:- Aspect ratio: 1:1 - Resolution: HD 720p or higher- Duration: 20 - 60 seconds |
| name Required | string | The name of the file, including the file extension (e.g. certification.pdf)Note:- Do not use additional periods, except the one preceding the file extension.- Do not begin the name with symbols.- Do not include spaces. |
Example
CurlGoNode.jsJavaEnable word wrap
Response Parameters
| Properties | Type | Description |
|---|---|---|
| code | int | The success or failure status code returned in API response. |
| message | string | The success or failure messages returned in API response. Reasons of failure will be described in the message. |
| request_id | string | Request log |
| data | object | Specific return information |
Example
JSONEnable word wrap
Error Code
View common error codes
| Code | Message | | --- | --- | | 12019103 | Couldn't upload file, the file is empty. | | 12019104 | The file name is empty. | | 12019105 | Failed to process the file. The format or content is not supported. | | 12019122 | The video ratio must be between 9:16 and 16:9. | | 12038002 | Invalid upload file. Please ensure you are passing the correct file data. | | 12038004 | Failed to process the image. The format or content is not supported. | | 12038005 | The file size exceeds the maximum allowed size. | | 36009003 | Internal error. Please try again. If the issue persists after multiple attempts, please contact platform support. |
Is this content helpful?Helpful
Not Helpful
PreviousNext