Apply CSV Mappings
POST/api/tiktok-shop/integration-instances/:integration_instance_id/products/csv-mappings/apply
Commit half of the two-step CSV import — mirrors Shopify's Apply Bulk Mapping CSV. Applies the {tiktok_shop_product_sku_id, sku_product_id} pairings returned by the Validate CSV Mappings endpoint. Each pairing maps a flattened TikTok SKU to a SKU.io product via the canonical mapping path (creates/updates the ProductListing and re-links any unmapped sales-order lines).
Any valid API token can call this endpoint — no specific scope required. Manage tokens.
Body: mappings (required, min 1). Each entry needs tiktok_shop_product_sku_id (integer — the internal TikTokShopProductSku id, NOT the tiktok_sku_id string) and sku_product_id (integer, must exist in products). SKUs that don't belong to this integration instance are counted in failed_count rather than mapped.
Response: { mapped_count, failed_count }.
Request
Responses
- 200
- 401
- 403
- 404
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not found — no record with the given identifier (or the route does not exist). Verify the ID before retrying.
Unprocessable Entity
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.