stable本次发布有变化全部展示
来自 TikTok Shop 官方资料快照 ·
- 当前资料结构化阅读页
- 固定快照已留存,可追溯
- 官方原文可核对
资料正文
§1 Path: /affiliate_partner/202505/campaigns/{campaign_id}/products/promotion_links/generate_batch
#§2 Method: [POST]
#§3 Function Description
This API offers the ability to generate promotion links for multiple products in a campaign.
§4 Common Parameters
For common parameters, refer to How to call TikTok Shop APIs - Common Parameters
| Properties | Location | Type | Require | Sample | Properties description |
|---|---|---|---|---|---|
| content-type | header | string | Y | application/json | Allowed type: application/json |
§5 Request Path Parameters
| Properties | Type | Require | Sample | Properties description |
|---|---|---|---|---|
| campaign_id | string | Y | 7362840009596339923 | The ID of the campaign |
§6 Request Query Parameters
| Properties | Type | Require | Sample | Properties description |
|---|---|---|---|---|
| app_key | string | Y | 38abcd | Every single app will have a unique key. Please use the specific key assigned to your app. |
| sign | string | Y | 5361235029d141222525e303d742f9e38aea052d10896d3197ab9d6233730b8c | Signature generated by gen algorithm. When you send API requests to TTS, you must sign them so that TTS can identify the senders. |
| timestamp | int | Y | 1623812664 | Unix timestamp GMT (UTC+00:00). This timestamp is used across all API requests. Developers can use this convert to local time. |
| category_asset_cipher | string | N | GCP_XF90igAAAABh00qsWgtvOiGFNqyubMt3= | The partner identifier used in API requests. Retrieve this value by using the [Get Authorized Category Assets API] (https://partner.tiktokshop.com/docv2/page/666012dd609d4402cc3be995). |
§7 Request Body Parameters
| Properties | Type | Require | Sample | Properties description |
|---|---|---|---|---|
| product_ids | []string | N | [7362840009596339971,7362840009596339923] | The list of product IDs. The max length is 50. |
§8 Request Sample
Query
https://open-api.tiktokglobalshop.com/affiliate_partner/202505/campaigns/7362840009596339923/products/promotion_links/generate_batch?app_key=123abc&sign=5361235029d141222525e303d742f9e38aea052d10896d3197ab9d6233730b8c×tamp=1625484268&category_asset_cipher=GCP_XF90igAAAABh00qsWgtvOiGFNqyubMt3=
Body
{"product_ids":[7362840009596340000,7362840009596340000]}
§9 Response Parameters
| Properties | Type | Sample | Properties description |
|---|---|---|---|
| code | int | 0 | The success or failure status code returned in API response. |
| message | string | Success | The success or failure messages returned in API response. Reasons of failure will be described in the message. |
| request_id | string | 202203070749000101890810281E8C70B7 | Request log |
| data | object | Specific return information | |
| ^product_promotion_links | []object | The list of products for which the promotion links are generated successfully. | |
| ^^product_id | string | 7362840009596339971 | The ID of the product to promote. |
| ^^link | string | https://affiliate.tiktok.com/api/v1/share/AIxvOHlaJoKO | This is the product promotion link that agencies can share with collaborated creators. Creators can copy/paste this link into the web browser. Creators will be re-directed to the add-product-link page in the Tikotk app. Creators can decide whether to add products to their showcases in the pop-up window. |
| ^failed_product_ids | []string | [7362840009596339923] | The list of products for which the promotion links failed to be generated. |
§10 Response Sample
{"code":0,"data":{"product_promotion_links":[{"product_id":"7362840009596339971","link":"https://affiliate.tiktok.com/api/v1/share/AIxvOHlaJoKO"}],"failed_product_ids":[7362840009596340000]},"message":"Success","request_id":"202203070749000101890810281E8C70B7"}
§11 Error Code
For common error codes, refer to How to call TikTok Shop APIs - Common Error Code
| Code | Message |
|---|
