Install
openclaw skills install douyin-research-kitExtract and analyze Douyin (抖音) content using yt-dlp. Supports video metadata, caption extraction, user profile analysis, music/sound info, and engagement stats. Use when user mentions "Douyin research", "抖音分析", "抖音提取", "Douyin extract", "抖音数据", "analyze Douyin", or provides a douyin.com/v.douyin.com URL.
openclaw skills install douyin-research-kitExtract structured data from Douyin videos, profiles, and content for research. Powered by yt-dlp locally — no API key required.
Version: 1.0.0 Prerequisite: yt-dlp >= 2024.01.01
# macOS
brew install yt-dlp
# pip
pip install yt-dlp
# Verify
yt-dlp --version
Douyin often requires cookies for stable access. Export browser cookies:
yt-dlp --cookies-from-browser chrome "URL"
Extract title, creator, engagement stats from a single video.
yt-dlp --dump-json --skip-download --cookies-from-browser chrome \
"https://www.douyin.com/video/VIDEO_ID"
Key JSON fields:
| Field | JSON path |
|---|---|
| Title / Caption | .title / .description |
| Creator | .uploader |
| Creator ID | .uploader_id |
| Upload date | .upload_date (YYYYMMDD → YYYY-MM-DD) |
| Duration | .duration (seconds) |
| Views | .view_count |
| Likes | .like_count (点赞) |
| Comments | .comment_count |
| Shares | .repost_count (转发) |
| Music/Sound | .track |
| Music author | .artist |
| Thumbnail | .thumbnail |
Short links:
yt-dlp --dump-json --skip-download --cookies-from-browser chrome \
"https://v.douyin.com/SHORTCODE/"
yt-dlp auto-resolves v.douyin.com short links.
Extract recent videos from a creator's profile.
yt-dlp --flat-playlist --dump-json --playlist-end 20 \
--cookies-from-browser chrome \
"https://www.douyin.com/user/USER_SEC_UID"
Output is one JSON per line. Parse for .title, .upload_date, .view_count, .like_count, .duration.
Output format: Table with columns: #, Date, Title (first 40 chars), Duration, Views, Likes.
Some Douyin videos have embedded subtitles:
# List available subtitles
yt-dlp --list-subs --skip-download --cookies-from-browser chrome \
"https://www.douyin.com/video/VIDEO_ID"
# Download subtitles
yt-dlp --skip-download --write-sub --write-auto-sub \
--sub-lang zh --sub-format vtt --convert-subs srt \
--cookies-from-browser chrome \
-o "/tmp/douyin-%(id)s.%(ext)s" \
"https://www.douyin.com/video/VIDEO_ID"
After download, read .srt and clean:
Output format: [HH:MM:SS] subtitle text
yt-dlp --flat-playlist --dump-json --playlist-end 20 \
--cookies-from-browser chrome \
"https://www.douyin.com/music/MUSIC_ID"
yt-dlp --flat-playlist --dump-json --playlist-end 20 \
--cookies-from-browser chrome \
"https://www.douyin.com/hashtag/HASHTAG_ID"
yt-dlp --dump-json --skip-download --cookies-from-browser chrome \
"https://live.douyin.com/ROOM_ID"
Returns stream title, host info, viewer count, and stream status.
| Pattern | Type |
|---|---|
douyin.com/video/ID | Single video |
v.douyin.com/SHORTCODE/ | Short link (auto-resolves) |
douyin.com/user/SEC_UID | User profile |
douyin.com/music/ID | Music/sound page |
douyin.com/hashtag/ID | Hashtag page |
live.douyin.com/ROOM_ID | Live stream |
= 10000 →
{n/10000:.1f}万
= 1000 →
{n/1000:.1f}千
When user provides a Douyin URL:
--cookies-from-browserWhen user asks to download a video:
--cookies-from-browser chromeDouyin Research Kit is an open-source project by SnapVee.