MCP.so
Sign In

X/Twitter MCP Server

@Barresider

About X/Twitter MCP Server

An MCP Server to interact with X/Twitter besides the official API.

Basic information

Category

Other

License

MIT

Runtime

node

Transports

stdio

Publisher

Barresider

Config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "x-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@barresider/x-mcp"
      ],
      "env": {
        "TWITTER_USERNAME": "your_twitter_username",
        "TWITTER_PASSWORD": "your_twitter_password"
      }
    }
  }
}

Tools

No tools detected

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is X/Twitter MCP Server?

X/Twitter MCP Server is a Model Context Protocol (MCP) server that provides unofficial X/Twitter API access through browser automation using Playwright. It enables AI agents and applications to programmatically interact with X/Twitter for content creation, scraping, and social media automation.

How to use X/Twitter MCP Server?

Add the server configuration to your Claude Desktop config file with your X/Twitter credentials as environment variables (TWITTER_USERNAME, TWITTER_PASSWORD). Optionally, provide a PROXY_URL. Restart Claude Desktop to begin using the 25+ MCP tools. For standalone use, run npm run cli login to authenticate.

Key features of X/Twitter MCP Server

  • Post tweets, threads, and interact with posts
  • Scrape timelines, profiles, and search tweets
  • Like, retweet, bookmark, and reply to posts
  • Upload images, videos, and GIFs to tweets
  • Supports stdio and HTTP/SSE transport
  • 25+ MCP tools for X/Twitter automation

Use cases of X/Twitter MCP Server

  • Automate posting tweets and threads from AI agents
  • Scrape trending topics and hashtags for analysis
  • Search for viral content with minimum engagement filters
  • Monitor and interact with comments on posts
  • Extract comprehensive user profiles and recent posts

FAQ from X/Twitter MCP Server

What are the prerequisites for X/Twitter MCP Server?

Node.js 18+ and valid X/Twitter account credentials are required. Docker is optional for containerized deployment.

How does authentication work?

Credentials are provided via TWITTER_USERNAME and TWITTER_PASSWORD environment variables. Run npm run cli login to store a session in the directory specified by AUTH_DIR (default playwright/.auth).

Does the server support proxies?

Yes, it supports HTTP/HTTPS proxies configured via the PROXY_URL environment variable, with optional authentication, useful for rotating IPs or accessing restricted networks.

What are common troubleshooting steps?

Verify credentials, re-authenticate, check for UI updates, reduce request frequency, and ensure proper environment variables for Docker.

Is this tool official or affiliated with X/Twitter?

No, this is an unofficial tool using browser automation and is not affiliated with X/Twitter. Use responsibly and respect X/Twitter's terms of service.

Comments

More Other MCP servers