
infatoshi/x-mcp
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
infatoshi/x-mcp - кандидат на сервер MCP, импортированный из https://github.com/infatoshi/x-mcp.
Обзор
infatoshi/x-mcp - кандидат на сервер MCP, импортированный из https://github.com/infatoshi/x-mcp.
Обзор (машинный перевод)
Сервер MCP (Model Context Protocol), который предоставляет агентам ИИ полный доступ к API X (Twitter). Размещайте твиты, ищите, читайте графики, например, ретвиты, загружайте медиа - все через естественный язык.
Работает с Claude Code, Claude Desktop, OpenAI Codex, Cursor, Windsurf, Cline и любым другим MCP-совместимым клиентом.
** Если вы агент LLM/AI, помогающий пользователю настроить этот проект, прочитайте LLMs.md для пошаговых инструкций, через которые вы можете пройти.
Что это может сделать?
Оригинальное название: What You Can Say
post_tweet, quote_tweet, delete_tweet | «Почта „привет, мир“ на X» | OK |
get_tweet, search_tweets, get_timeline, get_mentions | «Покажите мне последние сообщения @elonmusk» | OK |
get_user, get_followers, get_following | «Поиск @openai» / «Кому следует этот пользователь?»
retweet [[Retweet This]][править править код]]
| Media | upload_media | «Загрузите это изображение и опубликуйте его с подписью…» | OK |
[[Т13]] | Сколько впечатлений получил мой последний пост? | OK |
Эта страница переведена автоматически. Технические детали смотрите в оригинале.
README
Показан фрагмент оригинального README. Открыть оригинал.
x-mcp
An MCP (Model Context Protocol) server that gives AI agents full access to the X (Twitter) API. Post tweets, search, read timelines, like, retweet, upload media – all through natural language.
Works with Claude Code, Claude Desktop, OpenAI Codex, Cursor, Windsurf, Cline, and any other MCP-compatible client.
If you’re an LLM/AI agent helping a user set up this project, read LLMs.md for step-by-step instructions you can walk the user through.
What Can It Do?
| Category | Tools | What You Can Say | Status |
|---|---|---|---|
| Post | post_tweet, quote_tweet, delete_tweet |
“Post ‘hello world’ on X” | OK |
| Read | get_tweet, search_tweets, get_timeline, get_mentions |
“Show me @elonmusk’s latest posts” | OK |
| Users | get_user, get_followers, get_following |
“Look up @openai” / “Who does this user follow?” | OK |
| Engage | retweet |
“Retweet this” | OK |
| Media | upload_media |
“Upload this image and post it with the caption…” | OK |
| Analytics | get_metrics |
“How many impressions did my last post get?” | OK |
| Bookmarks | get_bookmarks, bookmark_tweet, unbookmark_tweet |
“Show my bookmarks” | Requires Basic+ tier |
| Reply | reply_to_tweet |
“Reply to this tweet saying thanks” | Restricted (see below) |
| Like | like_tweet |
“Like that tweet” | Removed on Free tier (see below) |
Accepts tweet URLs or IDs interchangeably – paste https://x.com/user/status/123 or just 123.
Setup
1. Clone and build
git clone https://github.com/INFATOSHI/x-mcp.git
cd x-mcp
npm install
npm run build
2. Get your X API credentials
You need 5 credentials from the X Developer Portal. Here’s exactly how to get them:
a) Create an app
- Go to the X Developer Portal
- Sign in with your X account
- Go to Apps in the left sidebar
- Click Create App (you may need to sign up for a developer account first)
- Give it a name (e.g.,
my-x-mcp) - You’ll immediately see your Consumer Key (API Key), Secret Key (API Secret), and Bearer Token
- Save all three now – the secret won’t be shown again
b) Enable write permissions
By default, new apps only have Read permissions. You need Read and Write to post tweets, like, retweet, etc.
- In your app’s page, scroll down to User authentication settings
- Click Set up
- Set App permissions to Read and write
- Set Type of App to Web App, Automated App or Bot
- Set Callback URI / Redirect URL to
https://localhost(required but won’t be used) - Set Website URL to any valid URL (e.g.,
https://x.com) - Click Save
c) Generate access tokens (with write permissions)
Установка
This server does not publish a one-line install command.
Open the repository installation guide Новичок в MCP? Начните с руководства на mcpskill.org →Конфигурация
{
"mcpServers": {
"x-twitter": {
"command": "node",
"args": ["/ABSOLUTE/PATH/TO/x-mcp/dist/index.js"],
"env": {
"X_API_KEY": "your_consumer_key",
"X_API_SECRET": "your_secret_key",
"X_ACCESS_TOKEN": "your_access_token",
"X_ACCESS_TOKEN_SECRET": "your_access_token_secret",
"X_BEARER_TOKEN": "your_bearer_token"
}
}
}
}