undoom-douyin-data-analysis
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@undoom-douyin-data-analysis Search for 'cooking' videos and analyze keywords"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
抖音数据分析 MCP 服务器
基于原始抖音数据分析工具开发的 MCP (Model Context Protocol) 服务器,提供抖音视频和用户数据的采集、分析和导出功能。
🎉 现已发布到 PyPI,可直接安装使用!
功能特性
数据采集
视频搜索: 根据关键词搜索抖音视频,采集标题、作者、点赞数、评论数等信息
用户搜索: 根据关键词搜索抖音用户,采集用户名、抖音号、粉丝数、获赞数等信息
自定义参数: 支持设置滚动次数和延迟时间,控制采集规模和速度
数据分析
互动数据分析: 分析视频的点赞、评论、分享等互动数据,提供统计报告
内容长度分析: 分析视频标题长度分布,了解内容特征
关键词分析: 使用中文分词技术分析高频词汇,发现热门话题
数据导出
多格式支持: 支持 JSON、Excel、CSV 格式导出
分类导出: 可选择导出视频数据、用户数据或全部数据
时间戳: 自动添加时间戳,避免文件覆盖
Related MCP server: TikTok Unauthorized API Scraper
安装和配置
方式一:从 PyPI 安装(推荐)
直接安装:
pip install undoom-douyin-data-analysis配置 MCP 客户端: 在你的 MCP 客户端配置文件中添加以下配置:
{ "mcpServers": { "undoom-douyin-data-analysis": { "command": "uvx", "args": [ "--index-url", "https://pypi.tuna.tsinghua.edu.cn/simple", "--from", "undoom-douyin-data-analysis", "undoom-douyin-mcp" ] } } }
方式二:本地开发安装
克隆仓库:
git clone <repository-url> cd undoom_Douyin_data_analysis安装依赖:
uv sync本地运行:
uv run undoom-douyin-mcp
环境要求
Python 3.13+
Chrome/Chromium 浏览器
网络连接(访问抖音)
可用工具
1. search_douyin_videos
搜索抖音视频数据
参数:
keyword(必需): 搜索关键词scroll_count(可选): 滚动次数,默认为10delay(可选): 每次滚动的延迟时间(秒),默认为2.0
2. search_douyin_users
搜索抖音用户数据
3. analyze_interaction_data
分析视频互动数据(点赞、评论等)
4. analyze_content_length
分析视频标题长度分布
5. analyze_keywords
分析视频标题中的高频词汇
6. export_data
导出采集的数据
7. get_data_summary
获取当前采集数据的摘要信息
8. clear_data
清空当前采集的数据
可用资源
1. douyin://data/videos
当前采集的视频数据(JSON 格式)
2. douyin://data/users
当前采集的用户数据(JSON 格式)
3. douyin://analysis/summary
数据采集和分析摘要(文本格式)
使用示例
基本工作流程
搜索视频数据: 使用 search_douyin_videos 工具搜索关键词
分析数据: 使用 analyze_interaction_data 分析互动数据 使用 analyze_keywords 分析高频词汇
导出结果: 使用 export_data 导出为指定格式
项目信息
PyPI 包: undoom-douyin-data-analysis
版本: 0.1.3
许可证: MIT License
Python 版本: 3.13+
注意事项
网络环境: 需要能够访问抖音网站
浏览器依赖: 使用 DrissionPage 需要 Chrome/Chromium 浏览器
采集频率: 建议设置适当的延迟时间,避免过于频繁的请求
合规使用: 请遵守抖音的使用条款和相关法律法规
数据使用: 采集的数据仅供学习和研究使用,请勿用于商业用途
技术架构
MCP 协议: 基于 Model Context Protocol 实现
异步处理: 使用 asyncio 进行异步操作
数据解析: 使用 BeautifulSoup 解析 HTML
中文分词: 使用 jieba 进行中文文本分析
数据处理: 使用 pandas 进行数据操作和导出
Available Tools
8 toolsanalyze_content_lengthC
分析视频标题长度分布
Inputs: no named parameters.
analyze_interaction_dataB
分析视频互动数据(点赞、评论等)
Inputs: no named parameters.
analyze_keywordsC
分析视频标题中的高频词汇
Inputs: top_n.
clear_dataB
清空当前采集的数据
Inputs: data_type.
export_dataC
导出采集的数据
Inputs: format, data_type, filename.
get_data_summaryA
获取当前采集数据的摘要信息
Inputs: no named parameters.
search_douyin_usersC
搜索抖音用户数据
Inputs: keyword (required), scroll_count, delay.
search_douyin_videosC
搜索抖音视频数据
Inputs: keyword (required), scroll_count, delay.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 8 tools
Each tool has a distinct purpose: two search tools for users and videos, three analysis tools for different aspects (content length, interactions, keywords), and three data management tools (clear, export, summary). No overlap between tools.
All tool names follow a consistent verb_noun pattern in snake_case (e.g., search_douyin_users, analyze_keywords, clear_data). The naming is uniform and predictable.
With 8 tools, the server covers the core workflow of searching, analyzing, and managing Douyin data without being too sparse or excessively numerous. The count fits the scope well.
The tool set covers the essential lifecycle: search, analyze (content length, interactions, keywords), and data management (clear, export, summary). A minor gap is the lack of a direct fetch for individual video or user details by ID, but search and analysis tools compensate adequately.
Maintenance
Related MCP Connectors
Public data from 20+ platforms, including Douyin, Xiaohongshu, Weibo and TikTok, as structured JSON
TikTok research for AI agents. Ask ChatGPT, Claude, Cursor, Codex or any MCP client what people search, watch, say and buy on TikTok, and get real numbers back. 34 tools: weekly TikTok search volume and 7-day trends, content gaps, videos, creators, comments and caption transcripts, hashtags and sounds, TikTok Shop sales estimates for products, shops, creators, videos and LIVE streams, TikTok’s Top Ads library with CTR and retention, places, and a fair comment-giveaway picker. 17 markets. Built for marketers, agencies, TikTok Shop sellers and creators. Sign in with OAuth or an API key; 50 free credits, no card.
TikTok search demand, videos, creators, comments and captions for AI agents. OAuth or API key.
Real-time TikTok videos, profiles, comments, trends & Creative Center ads MCP. OAuth or API key.
Related MCP Servers
- AlicenseDqualityDmaintenanceProvides access to Douyin (TikTok China) API for searching videos, retrieving user profiles, posts, comments, music, challenges, live streams, and hot trends through the Douyin platform.79MIT
- AlicenseCqualityDmaintenanceEnables access to TikTok data without watermarks, including trending users, hashtags, post analytics, user profiles, and download links for specific countries. Supports searching by username, user ID, or post links.1010MIT
- FlicenseAqualityDmaintenanceEnables AI assistants to access Douyin (TikTok China) data including video search, details, comments, and user information via local JavaScript signature.816-
- FlicenseNot gradedqualityCmaintenanceEnables local scraping and interaction with Douyin (TikTok China) content, including videos, user data, comments, live streams, and private messages, using personal account cookies without official APIs.1-