{"record":{"id":"83414bdc71feeaee","repo":"gitroomhq/postiz-app","slug":"tiktok-refused-to-publish-your-post-83414b","errorCode":null,"errorMessage":"TikTok refused to publish your post","messagePattern":"TikTok refused to publish your post","errorType":"exception","errorClass":"BadBody","httpStatus":null,"severity":"error","filePath":"libraries/nestjs-libraries/src/integrations/social/tiktok.provider.ts","lineNumber":929,"sourceCode":"            id: response.id,\n            releaseURL: check.releaseURL,\n            postId: String(check.postId),\n            status: 'success',\n          },\n        ];\n      }\n\n      // Cap below the 10-minute activity timeout of the old workflows using\n      // this method: failing here (non-retryable) is safe, timing the activity\n      // out is not - a retried activity would publish the post again.\n      if (Date.now() - started > 8 * 60 * 1000) {\n        break;\n      }\n\n      await timer(20000);\n    }\n\n    throw new BadBody(\n      'titok-error-upload',\n      JSON.stringify({}),\n      Buffer.from(JSON.stringify({})),\n      'TikTok refused to publish your post'\n    );\n  }\n\n  async analytics(\n    id: string,\n    accessToken: string,\n    date: number\n  ): Promise<AnalyticsData[]> {\n    const today = dayjs().format('YYYY-MM-DD');\n\n    try {\n      // Get user stats (follower_count, following_count, likes_count, video_count)\n      const userStatsResponse = await fetch(\n        'https://open.tiktokapis.com/v2/user/info/?fields=follower_count,following_count,likes_count,video_count',","sourceCodeStart":911,"sourceCodeEnd":947,"githubUrl":"https://github.com/gitroomhq/postiz-app/blob/0f1647f7491a217d43eb5ae7a480484bdf0aff3e/libraries/nestjs-libraries/src/integrations/social/tiktok.provider.ts#L911-L947","documentation":"After uploading a video, post polls TikTok's publish status but never reaches a published state within the allowed polling attempts, so it assumes TikTok refused to publish. Note the typo'd code 'titok-error-upload'.","triggerScenarios":"TikTok's /v2/post/publish/status/task endpoint keeps returning PUBLISH_IN_PROGRESS or reports FAILED/failed status loops for every poll; the loop exhausts (after timer(20000) waits) and falls through to the throw.","commonSituations":"Videos stuck in TikTok moderation/review; invalid caption or claim metadata causing silent failure; capacity issues on TikTok's side for large videos; poll responses that never include a success code.","solutions":["Check the TikTok developer dashboard / caption content for policy violations (music, claims, hashtags)","Retry the post — transient TikTok processing failures are common for large files","Verify the uploaded video meets TikTok's requirements (codec H.264, size < 4GB(advertised limits), aspect/metadata)","If reproducible for one channel only, reconnect the channel and re-upload"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"catch (e) { if (e instanceof BadBody && e.code === 'titok-error-upload') { /* safe: tweet/post not created; surface to user or retry once */ } throw e; }","preventionTips":["Keep TikTok videos within codec/size/duration policy to avoid stuck moderation","Retry once after a few minutes for transient processing stalls","Pre-validate captions and media before scheduling to reduce policy rejections"],"tags":["tiktok","publish-status","polling-timeout","video-processing"],"backgroundTag":"social-media-publish-timeout","analyzedSha":"0f1647f7491a217d43eb5ae7a480484bdf0aff3e","analyzedAt":"2026-08-27T12:09:55.020Z","schemaVersion":2},"datasetVersion":"2026-08-27T13:17:12.746Z"}