您的浏览器不支持JavaScript,请启用JavaScript以获得最佳体验。
Create a publishing task
Developer docs / Publishing tasks

Create a publishing task

Creates TikTok Shop, TikTok or TikTok Business publishing tasks. Success means accepted; inspect publishing records for completion.

POST/v1/creator/post/create
Authentication:
Request header x-api-key: <YOUR_API_KEY>; keep the key on the server and never expose it in client code, logs or shared files.
Success criteria:
HTTP 2xx with code=0; for asynchronous tasks, also query the final status.

Request body fields

FieldTypeRequiredDescription
businessIdstringYesFILE: file ID; EXTERNAL_URL: original HTTPS MP4 URL
businessTypeFILE | EXTERNAL_URLYesUploaded file or external video URL
creatorIdstringYescreatorId returned by the creator endpoint
titlestringYesPost caption, up to 4,000 characters
platformTIKTOK_SHOP | TIKTOK | TIKTOK_BUSINESSYesPublishing platform
mediaTypeVIDEO | PHOTONoOptional explicit media type; inferred from the request body when omitted
scheduledAtintegerNoUnix epoch in milliseconds
scheduledTzstringNoIANA timezone
oauthRegionstringNoCreator OAuth authorization region
coverFileIdinteger | stringNoCustom video cover file ID; pass together with tiktokShop.coverUri and omit for photo posts
tiktokShopobjectConditionalTikTok Shop video options: products, cover, pre-check, music and AI label
tiktokShop.preCheckbooleanNoWhether to submit a pre-check before publishing; defaults to false
tiktokShop.preCheckOvertimeintegerNoPre-check timeout in seconds, from 600 to 3600 inclusive. If the official pre-check remains incomplete beyond this time, automatically skip it and continue publishing.
tiktokShop.isAiGeneratedbooleanNoWhether to label the video as AI-generated; TikTok adds an AI-generated label when true
tiktokShop.coverUristringNoURI returned by the cover upload endpoint; pass coverFileId with it
tiktokShop.coverTimestampMsintegerNoVideo timestamp in milliseconds to use as the cover frame; omit when coverUri is present
tiktokShop.musicInfoobjectNoVideo background music; omit when no music is needed
tiktokShop.musicInfo.idstringConditionalMusic ID, required when musicInfo is provided
tiktokShop.productInfo.productIdstringConditionalRequired for VIDEO; product ID returned by the product endpoint
tiktokShop.productInfo.titlestringConditionalRequired for VIDEO; product anchor title, up to 30 characters
tiktokShop.productInfo.sourceSHOP | SHOWCASEConditionalRequired for VIDEO; SHOP for shop products or SHOWCASE for showcase products
tiktokShopPhotoobjectConditionalTikTok Shop photo options
tiktokShopPhoto.postTypeMULTI_PHOTO_ONE_ANCHORConditionalUse MULTI_PHOTO_ONE_ANCHOR for PHOTO
tiktokShopPhoto.businessIdsstring[]ConditionalRequired for PHOTO; 1–15 image fileIds in final display order
tiktokShopPhoto.productLinks[0].productIdstringConditionalRequired for PHOTO; product ID for the single product anchor
tiktokShopPhoto.productLinks[0].titlestringConditionalRequired for PHOTO; product anchor title, up to 30 characters
tiktokShopPhoto.productLinks[0].sourceSHOP | SHOWCASEConditionalRequired for PHOTO; product source
tiktokShopPhoto.musicInfoobjectNoPhoto post background music; omit when no music is needed
tiktokShopPhoto.musicInfo.idstringConditionalMusic ID, required when musicInfo is provided
tiktokBusinessobjectNoBusiness video options: interaction restrictions, cover, brand flags, AI label, music and location; no privacy level.
tiktokBusinessPhotoobjectConditionalRequired for Business PHOTO; 1–15 image file IDs and privacyLevel from publishing settings.
tiktokobjectConditionalTikTok video publishing settings
tiktokBusiness.musicSoundInfo.musicSoundIdstringNoCommercial song_clip_id; omit to add no platform music
tiktokBusiness.musicSoundInfo.musicSoundVolumeintegerNoMusic volume 0–100, default 50
tiktokBusiness.musicSoundInfo.videoOriginalSoundVolumeintegerNoOriginal audio volume 0–100, default 50
tiktokBusiness.locationInfoobjectNolocationId and locationName must be paired; locationAddress is display-only
tiktokBusinessPhoto.businessIdsinteger[]Conditional1–15 image file IDs in display order
tiktokBusinessPhoto.privacyLevelstringConditionalRequired for Business photos; use a value from publishing settings
tiktokBusinessPhoto.photoCoverIndexintegerNoZero-based cover index; default 0
tiktokBusinessPhoto.autoAddMusicbooleanNoAuto music; forced false when musicSoundInfo selects a track
tiktokBusinessPhoto.musicSoundInfoobjectNoMusic ID, name and artist; no volume fields for photos
tiktokBusinessPhoto.locationInfoobjectNoLocation ID and name must be paired
For a video cover, use tiktokShop.coverTimestampMs for a frame or pass coverFileId together with tiktokShop.coverUri for a custom cover; do not mix the two methods.
TikTok Shop photo posts support 1–15 images and one product; businessId must equal businessIds[0], and the first image is the cover.
Persist postId and status, then verify the final state in publishing records.
Business location ID and name must be provided together. Use musicSoundId (song_clip_id), never commercialMusicId. Video volumes range from 0 to 100 and default to 50. Photos have no volume parameters; selected music overrides autoAddMusic.
For Business video covers, coverFileId overrides coverTimestampMs. Account-disabled interactions cannot be enabled.
EXTERNAL_URL supports only TikTok Shop VIDEO on Pro/Elite or equivalent legacy plans: HTTPS URL at most 256 characters, Content-Type video/mp4, Content-Length strictly below 200 MiB.
Success response
{
  "code": 0,
  "data": {
    "id": 100,
    "postId": "post_xxx",
    "platform": "TIKTOK_SHOP",
    "title": "Summer Sale 2026 #summer",
    "videoUrl": "https://cdn.ailingtu.com/media/video.mp4",
    "status": "SCHEDULED"
  },
  "message": "success"
}
Request example · TikTok Shop commerce video
{
  "businessId": "1465129",
  "businessType": "FILE",
  "coverFileId": 1465137,
  "creatorId": "2077242233106595840",
  "title": "Womens midlength Tshirt",
  "platform": "TIKTOK_SHOP",
  "scheduledAt": 1787752245233,
  "scheduledTz": "America/New_York",
  "tiktokShop": {
    "preCheck": true,
    "preCheckOvertime": 1800,
    "isAiGenerated": false,
    "coverUri": "tos-useast5-i-photomode-tx/owJB0AmAiCIAINiw1WSCmp1ftJzwBqxROEB5w5",
    "productInfo": {
      "productId": "1729452608393351351",
      "title": "Womens midlength Tshirt",
      "source": "SHOWCASE"
    }
  }
}
Request example · TikTok Shop commerce photo post
{
  "businessId": "591",
  "businessType": "FILE",
  "creatorId": "2077242233106595840",
  "title": "Summer Sale 2026 #summer",
  "platform": "TIKTOK_SHOP",
  "mediaType": "PHOTO",
  "scheduledAt": 1784896665989,
  "scheduledTz": "America/New_York",
  "oauthRegion": "USA",
  "tiktokShopPhoto": {
    "postType": "MULTI_PHOTO_ONE_ANCHOR",
    "businessIds": [
      "591",
      "592"
    ],
    "productLinks": [
      {
        "productId": "1732280564607717841",
        "title": "Summer Vibes Cord",
        "source": "SHOP"
      }
    ],
    "musicInfo": {
      "id": "7567668059796720391",
      "title": "original sound",
      "author": "Ivan",
      "duration": "15"
    }
  }
}
Request example · TikTok Business video
{
  "creatorId": "2077242233106595840",
  "businessType": "FILE",
  "businessId": "591",
  "title": "New collection",
  "platform": "TIKTOK_BUSINESS",
  "mediaType": "VIDEO",
  "tiktokBusiness": {
    "musicSoundInfo": {
      "musicSoundId": "7123456789012345678",
      "musicSoundVolume": 50,
      "videoOriginalSoundVolume": 50
    },
    "locationInfo": {
      "locationId": "loc-1",
      "locationName": "London"
    }
  }
}
Request example · TikTok Business photo post
{
  "creatorId": "2077242233106595840",
  "businessType": "FILE",
  "businessId": "591",
  "title": "New collection",
  "platform": "TIKTOK_BUSINESS",
  "mediaType": "PHOTO",
  "tiktokBusinessPhoto": {
    "businessIds": [
      591,
      592
    ],
    "privacyLevel": "SELF_ONLY",
    "photoCoverIndex": 0
  }
}

Response and errors

Main response fields come from the published contract; see the JSON Schema. Required refers to the constraint in the containing object.

FieldTypeRequiredDescription
codeintegerYesFixed value: 0
messagestringNo—
dataobjectYes—
data.idunionYes—
data.postIdstringYes—
data.platformstringYesAllowed values: TIKTOK_SHOP, TIKTOK, TIKTOK_BUSINESS
data.titlestringYes—
data.videoUrlstring | nullNo—
data.statusstringYes—
timestampintegerNoResponse timestamp in milliseconds.
  • HTTP 400The request parameters or body are invalid. Fix them and retry.
  • HTTP 401The API key is missing or invalid. Check x-api-key.
  • HTTP 403The API key has no permission to call this endpoint.
  • HTTP 429Too many requests. Retry with exponential backoff.
  • HTTP 500The server failed. Retry transient failures with exponential backoff.

Fix parameter, permission or authorization errors before retrying. If task creation times out, query existing tasks first and do not submit duplicates after an interrupted poll.

Last updated · 2026-11-16