MCP server for Twitter integration using agent-twitter-client
MCP server for Twitter integration using agent-twitter-client. The agent mcp server wraps that behind the Model Context Protocol, so an assistant can use it through 14 defined tools rather than through you.
A Model Context Protocol (MCP) server that integrates with Twitter using the agent-twitter-client package, allowing AI models to interact with Twitter without direct API access.
The server ships on npm as agent-twitter-client-mcp, so your MCP client can launch it on demand — there is no separate build step. Add the server block to your client's configuration, restart it, and the tools register themselves.
Everything the assistant can do here goes through one of these:
get_user_tweets — Fetch tweets from a specific userget_tweet_by_id — Fetch a specific tweet by IDsearch_tweets — Search for tweetssend_tweet — Post a new tweetsend_tweet_with_poll — Post a tweet with a polllike_tweet — Like a tweetretweet — Retweet a tweetquote_tweet — Quote a tweetget_user_profile — Get a user's profilefollow_user — Follow a userget_followers — Get a user's followersget_following — Get users a user is followingYou will need 8 environment variables: AUTH_METHOD, TWITTER_COOKIES, TWITTER_USERNAME, TWITTER_PASSWORD, TWITTER_EMAIL, TWITTER_2FA_SECRET, TWITTER_API_KEY, TWITTER_API_SECRET_KEY. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.
Among the developer tooling options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Agent's toolset — get_user_tweets, get_tweet_by_id, search_tweets and 11 more — is a fair guide to whether it matches your workflow. It is maintained by ryanmac-npm; worth a glance at recent repository activity before you build anything load-bearing on it.
This entry was verified against Agent's own documentation before publication; SyncDev keeps the directory reviewed rather than auto-generated.
| Tool | What it does |
|---|---|
| get_user_tweets | Fetch tweets from a specific user |
| get_tweet_by_id | Fetch a specific tweet by ID |
| search_tweets | Search for tweets |
| send_tweet | Post a new tweet |
| send_tweet_with_poll | Post a tweet with a poll |
| like_tweet | Like a tweet |
| retweet | Retweet a tweet |
| quote_tweet | Quote a tweet |
| get_user_profile | Get a user's profile |
| follow_user | Follow a user |
| get_followers | Get a user's followers |
| get_following | Get users a user is following |
| grok_chat | Chat with Grok via Twitter |
| health_check | Check the health of the Twitter MCP server |
{
"mcpServers": {
"agent-twitter-client-mcp": {
"command": "npx",
"args": ["-y", "agent-twitter-client-mcp"],
"env": {
"AUTH_METHOD": "cookies",
"TWITTER_COOKIES": "[\"auth_token=YOUR_AUTH_TOKEN; Domain=.twitter.com\", \"ct0=YOUR_CT0_VALUE; Domain=.twitter.com\", \"twid=u%3DYOUR_USER_ID; Domain=.twitter.com\"]"
}
}
}
}Configuration as documented by the project. Restart the client after saving.
| Variable | Description | Required |
|---|---|---|
| AUTH_METHOD | Configuration value read at startup. | Optional |
| TWITTER_COOKIES | Configuration value read at startup. | Optional |
| TWITTER_USERNAME | Configuration value read at startup. | Optional |
| TWITTER_PASSWORD | Configuration value read at startup. | Optional |
| TWITTER_EMAIL | Configuration value read at startup. | Optional |
| TWITTER_2FA_SECRET | Credential the server authenticates with. | Yes |
| TWITTER_API_KEY | Credential the server authenticates with. | Yes |
| TWITTER_API_SECRET_KEY | Credential the server authenticates with. | Yes |
Kill hallucinated APIs — version-accurate, up-to-date library documentation injected straight into context.
Microsoft's official browser automation server — drive a real browser through the accessibility tree, no screenshots needed.
GitHub's official server — repos, issues, pull requests, Actions and code security, straight from your assistant.
Issue tracking at the speed of conversation — Linear's official hosted server with OAuth and zero install.
Local repository surgery — status, diffs, commits, branches and history for any repo on disk.
Timezone sanity for AI — current time anywhere and correct conversions, without the model doing date math.