tiktok_download

Downloads TikTok and Douyin videos with traffic metrics via the TikHub API.

1.2k|126|Updated Mar 14, 2025
One-click install
npx skills add https://github.com/inclusionAI/AWorld --skill tiktok-download
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tiktok_download
Source: https://github.com/inclusionAI/AWorld/tree/main/aworld-skills/tiktok_download
Command: npx skills add https://github.com/inclusionAI/AWorld --skill tiktok-download

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires httpx.

What problem does it solve?

Manually saving TikTok or Douyin videos and recording their engagement metrics is slow and error-prone, especially across many URLs. This Skill automates single or batch video downloads through the TikHub API while capturing full raw API responses and converting them into spreadsheet-ready summaries.

Core Features & Use Cases

  • Single and Batch Downloads: Download one video by share URL or process a URL list concurrently with up to 10 workers, saving MP4 files plus likes, comments, shares, and play counts.
  • Raw JSON Persistence: Every successful API response is saved as a full raw JSON file for auditing and replay, with an option to disable saving.
  • CSV and JSON Post-Processing: A stdlib-only script converts raw API JSON into a flat CSV and a simplified JSON summary covering author, statistics, music, and AIGC fields.
  • Use Case: A social media analyst collects 50 TikTok URLs from a campaign, runs the batch command, then post-processes the raw JSON directory into a CSV for reporting.

Quick Start

Ask the agent to download a TikTok video from a share URL and export its engagement metrics to a CSV summary using the TikHub API key configured in the skill.

Frequently Asked Questions about tiktok_download

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I download a TikTok video with Python?

Run the tikhub_independent.py script with the one command followed by the share URL. It calls the TikHub API to fetch video metadata, downloads the MP4, and prints metrics like likes, comments, and play counts.

How to batch download TikTok and Douyin videos from a URL list?

Place one URL per line in a text file and run the batch subcommand. Downloads run concurrently with up to 10 worker threads, and each result reports success, saved path, and metrics.

Does this TikTok downloader require an API key?

Yes, a valid paid TikHub API key from tikhub.io is mandatory. Without it, the script stops immediately and instructs the user to obtain and configure a key before any download or data fetching occurs.

What dependencies does the TikHub downloader need?

The downloader requires only the httpx Python package. The post-processing script that generates CSV and simplified JSON summaries uses only the Python standard library, so no extra packages are needed for it.

Why does TikTok video download fail with 401 or 403 errors?

A 401 or 403 response means the API key is invalid or lacks required scopes. Verify the key configured in the skill, and for 429 rate limits reduce the max-workers setting or retry later.

What are the limitations of the TikHub video download approach?

It only supports the fetch_one_video_by_share_url endpoint, so user-profile crawling, image carousels, and non-URL workflows are excluded. Private or removed videos fail parsing, and mainland TikTok access may require a proxy.