PublishQPublishQ

TikTok

Post videos and photo carousels to TikTok through the PublishQ API.

What you can post

TypeSupportedMax mediaNotes
Video1MP4, WebM, MOV. Max 4 GB, duration varies per account
Photo carousel35WebP, JPEG. Max 20 MB per image

Limitations

  • Media is required. TikTok does not support text-only posts.
  • You cannot mix images and video in the same post. A post is either a single video or up to 35 photos.
  • Video duration varies per account. Query the creator info endpoint before posting to get the current limit.
  • Daily API posting limit. TikTok enforces a daily post cap for posts created via third-party APIs, separate from the native app limit. This is per-account. When you hit it, the post will fail with spam_risk_too_many_posts.

Quick start

Post a video

A single video post that appears on the creator's TikTok profile. Supports MP4, WebM, and MOV up to 4 GB. Duration limit depends on the account (3, 5, or 10 minutes).

Query creator info

TikTok requires that the privacyLevel you set matches one of the options available for the target account. Call this endpoint to get the current settings.

GET /api/v1/accounts/{accountId}/tiktok-creator-info

The response depends on the account type:

Public account:

{
  "privacyLevelOptions": ["PUBLIC_TO_EVERYONE", "MUTUAL_FOLLOW_FRIENDS", "SELF_ONLY"],
  "commentDisabled": false,
  "duetDisabled": false,
  "stitchDisabled": false,
  "maxVideoPostDurationSec": 600
}

Private account:

{
  "privacyLevelOptions": ["FOLLOWER_OF_CREATOR", "MUTUAL_FOLLOW_FRIENDS", "SELF_ONLY"],
  "commentDisabled": false,
  "duetDisabled": true,
  "stitchDisabled": true,
  "maxVideoPostDurationSec": 180
}

If duetDisabled or stitchDisabled is true, TikTok will ignore the corresponding disableDuet/disableStitch settings.

Get your media ready

curl -X POST https://publishq.com/api/v1/media \
  -H "Authorization: Bearer pq_live_..." \
  -F "[email protected]"
curl https://publishq.com/api/v1/media \
  -H "Authorization: Bearer pq_live_..."

Pick the id of the video you want to use from the response.

Create the post

The caption goes in content (max 2200 characters). Hashtags (#) and mentions (@) in the caption are automatically parsed by TikTok.

{
  "content": "New tutorial dropping 🎬 #coding #fyp",
  "mediaIds": ["video-media-id"],
  "thumbnailTimestamp": 3500,
  "accounts": [
    {
      "accountId": "tiktok-account-id",
      "platformSpecificSettings": {
        "privacyLevel": "PUBLIC_TO_EVERYONE",
        "disableComment": false,
        "disableDuet": false,
        "disableStitch": false,
        "brandContentToggle": false,
        "brandOrganicToggle": false
      }
    }
  ],
  "publishNow": true
}

Post a photo carousel

A swipeable photo post with 1–35 images. WebP and JPEG only, max 20 MB per image.

Query creator info

Same as above — call the creator info endpoint to get the available privacy options.

GET /api/v1/accounts/{accountId}/tiktok-creator-info

Get your media ready

curl -X POST https://publishq.com/api/v1/media \
  -H "Authorization: Bearer pq_live_..." \
  -F "[email protected]"

Repeat for each image. Collect the id from each response.

curl https://publishq.com/api/v1/media \
  -H "Authorization: Bearer pq_live_..."

Pick the ids of the images you want to use from the response.

Create the post

Attach 1–35 images. TikTok displays them as a swipeable carousel. The content field maps to the photo title (max 90 characters). Use description in platformSpecificSettings for longer text (max 4000 characters).

{
  "content": "Travel dump 🌍",
  "mediaIds": ["img-1", "img-2", "img-3", "img-4", "img-5"],
  "accounts": [
    {
      "accountId": "tiktok-account-id",
      "platformSpecificSettings": {
        "privacyLevel": "PUBLIC_TO_EVERYONE",
        "disableComment": false,
        "disableDuet": false,
        "disableStitch": false,
        "brandContentToggle": false,
        "brandOrganicToggle": false,
        "autoAddMusic": true,
        "photoCoverIndex": 2,
        "description": "Best spots from our trip through Southeast Asia 🇹🇭🇻🇳🇰🇭 #travel #photomode #backpacking"
      }
    }
  ],
  "publishNow": true
}

Photo carousel title limit

TikTok photo posts have a 90-character title limit (the content field), while video posts allow up to 2200 characters. If you're posting to TikTok alongside platforms with longer limits, use postOverrides to provide a shorter title just for TikTok.

{
  "content": "Full description of our latest product launch with all the details...",
  "mediaIds": ["img-1", "img-2", "img-3"],
  "accounts": [
    { "accountId": "instagram-account-id" },
    {
      "accountId": "tiktok-account-id",
      "postOverrides": {
        "content": "New product just dropped 🔥"
      },
      "platformSpecificSettings": {
        "privacyLevel": "PUBLIC_TO_EVERYONE",
        "disableComment": false,
        "disableDuet": false,
        "disableStitch": false,
        "brandContentToggle": false,
        "brandOrganicToggle": false,
        "description": "Full description with all the #details and @mentions here"
      }
    }
  ],
  "publishNow": true
}

Media specs

Video

SpecValue
Max file size4 GB
Min duration3 seconds
Max durationVaries per account (3, 5, or 10 minutes)
Supported formatsMP4 (recommended), WebM, MOV
Supported codecsH.264 (recommended), H.265, VP8, VP9
Framerate23–60 FPS
ResolutionMin 360px, max 4096px (both dimensions)

Images

SpecValue
Max file size20 MB per image
Max images per post35
Supported formatsWebP, JPEG
Max resolution1080p

Platform-specific settings

FieldTypeDescription
privacyLevelenumWho can view this post. The value must match one of the options returned by the TikTok creator_info/query endpoint for the target account.
disableCommentbooleanIf true, other TikTok users cannot comment on this post. Ignored if the creator has set comments to "No one" in their privacy settings.
disableDuetbooleanIf true, other TikTok users cannot create Duets with this post. Only applies to video posts. Ignored for photo posts and private accounts.
disableStitchbooleanIf true, other TikTok users cannot create Stitches with this post. Only applies to video posts. Ignored for photo posts and private accounts.
brandContentTogglebooleanSet to true if this is a paid partnership promoting a third-party business. Required by TikTok for branded content disclosure.
brandOrganicTogglebooleanSet to true if this post promotes the creator's own business.
autoAddMusicboolean (optional)Photo posts only. If true, TikTok automatically adds recommended background music to the photo carousel. Users can change the music later in the TikTok app.
videoMadeWithAiboolean (optional)Video posts only. Set to true if the video is AI-generated content. The video will be labeled with a "Creator labeled as AI-generated" tag.
descriptionstring (optional)Photo posts only. Additional description text (max 4000 characters). Hashtags and mentions in the description are parsed by TikTok.
photoCoverIndexnumber (optional)Photo posts only. Zero-based index of the image to use as the carousel cover. Defaults to 0 (first image).
Full schema: TikTokPlatformSpecificSettings

Not yet supported

  • Video captions/subtitles (TikTok supports up to 20 VTT files via the API)

On this page