Click on "Install 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., "@Twitter MCP ServerCheck the character count for this: 'Hello world! ๐ #excited https://glama.ai'"
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.
Twitter MCP Server
An MCP (Model Context Protocol) server for Claude to accurately count Twitter/X post characters and optimize posts.
Features
Accurate Character Counting: Calculate character count based on Twitter/X's official counting method
Post Validation: Check character limits and other constraints
Post Optimization: Suggestions for optimizing posts that are too long
Entity Extraction: Extract and analyze URLs, mentions, and hashtags
Installation
Configuration for Claude Desktop
Add the following to your Claude Desktop configuration file (~/Library/Application Support/Claude/claude_desktop_config.json):
Usage
The following tools will be available in Claude:
1. count_tweet_characters
2. validate_tweet
3. optimize_tweet
4. extract_entities
Development
API Details
count_tweet_characters
Input:
text(string) - Text to countOutput: Detailed information including character count, remaining characters, validity
validate_tweet
Input:
text(string) - Text to validateOutput: Validity, issues, entity information
optimize_tweet
Input:
text(string) - Text to optimizemaxLength(number, optional) - Maximum character count (default: 280)
Output: Optimized text and suggestions
extract_entities
Input:
text(string) - Text to extract entities fromOutput: Lists of URLs, mentions, and hashtags
Tech Stack
TypeScript: Type safety and better development experience
@modelcontextprotocol/sdk: MCP server implementation
twitter-text: Official Twitter character counting library
License
MIT License
Contributing
Fork this repository
Create a feature branch (
git checkout -b feature/amazing-feature)Commit your changes (
git commit -m 'Add some amazing feature')Push to the branch (
git push origin feature/amazing-feature)Create a Pull Request
Support
If you have any issues or questions, please report them in GitHub Issues.