MCP-Twikit Project Detailed Introduction
Project Overview
MCP-Twikit is a Model Context Protocol (MCP) server for interacting with Twitter. This project provides AI assistants (such as Claude Desktop) with powerful Twitter data access and analysis capabilities through the MCP protocol.
Core Features
1. Twitter Search Functionality
- Supports searching for tweets by keyword
- Allows specifying the number of search results
- Supports sorting by time (newest first)
- Can search for tweets from specific users (using the
to:usernamesyntax)
2. Timeline Retrieval
- Retrieves a user's personal Twitter timeline
- Provides real-time access to the latest tweet content
- Supports parsing of various tweet types
3. Social Media Sentiment Analysis
- Analyzes the sentiment of tweets in batches
- Compares public sentiment across multiple accounts
- Generates detailed sentiment analysis reports
Installation and Configuration
Automatic Installation (Recommended)
Automatically install to Claude Desktop via Smithery:
npx -y @smithery/cli install mcp-twikit --client claude
Manual Configuration
Add the following to the Claude Desktop configuration file:
{
"mcpServer": {
"command": "uvx",
"args": ["--from", "git+https://github.com/adhikasp/mcp-twikit", "mcp-twikit"],
"env": {
"TWITTER_USERNAME": "@example",
"TWITTER_EMAIL": "[email protected]",
"TWITTER_PASSWORD": "secret"
}
}
}
Using the MCP Client CLI
Supports interactive use via the mcp-client-cli tool.
Real-World Application Scenarios
1. Brand Sentiment Monitoring
The project documentation showcases a real-world case: analyzing customer sentiment towards the four largest internet service providers in Indonesia:
$ llm compare 20 latest tweet directed @IndiHomeCare, @di_cbn, @BiznetHome, @ID_MyRepublic. What are people sentiment to the product? Do 1 search for each account
Analysis results show:
- IndiHomeCare: Primarily negative sentiment (unstable network, slow response)
- CBN: Mostly negative sentiment (long-term outages, slow customer service response)
- BiznetHome: Strong negative sentiment (frequent network interruptions, slow speed)
- MyRepublic: Extremely negative sentiment (severe service interruptions, extremely poor customer service)
2. Personal Timeline Analysis
$ llm what is happening on my twitter timeline?
Capable of analyzing and summarizing:
- Professional/technical news
- Important tweet summaries
- Categorized organization of various topics
Technical Features
Model Context Protocol Integration
- Built entirely based on the MCP standard
- Seamless integration with Claude Desktop
- Supports tool calling and structured responses
Multi-Functional API Support
search_twitter: Tweet search functionalityget_timeline: Timeline retrieval functionality- Supports complex query syntax and parameter configuration
Security Authentication
- Supports username/email/password authentication
- Secure environment variable configuration
- Adheres to Twitter API usage guidelines
Related Project Ecosystem
Developer adhikasp also maintains other MCP server projects:
mcp-linkedin: LinkedIn data accessmcp-git-ingest: GitHub repository analysismcp-reddit: Reddit content retrievalmcp-youtube: YouTube transcription retrieval
Usage Recommendations
- Enterprise Applications: Suitable for brand monitoring, competitor analysis, customer sentiment tracking
- Personal Use: Timeline management, trend analysis, social media insights
- Research Purposes: Social media research, sentiment analysis research, data mining
Precautions
- Requires valid Twitter account credentials
- Adheres to Twitter's terms of service and API limitations
- It is recommended to reasonably control the request frequency to avoid account risks
- Ensure data usage complies with privacy protection requirements