T

Twitter

Provides a TypeScript-based server for interacting with Twitter, enabling tweet operations, user pro...

93 views
1 installs
Updated Sep 9, 2025
Not audited
Provides a TypeScript-based server for interacting with Twitter, enabling tweet operations, user profile management, and Grok AI integration through multiple authentication methods.
  1. Choose Authentication Method

    Decide which authentication method to use for connecting to Twitter. The recommended method is cookie-based authentication. You may also use username/password or Twitter API credentials if preferred.

  2. For Cookie-Based Authentication (Recommended)

    1. Log in to Twitter in your browser.

    2. Open Developer Tools:

      • Press F12 or right-click anywhere on the page and select “Inspect.”
    3. Go to the Application Tab:

      • In Developer Tools, go to the “Application” tab.
      • On the left, expand the “Cookies” section and select https://twitter.com.
    4. Copy Required Cookies:

      • Find and copy the values of these cookies: auth_token, ct0, and twid.
    5. Format Cookies:

      • Format your cookies as a JSON array (as shown below), ensuring each entry also specifies Domain=.twitter.com:
        [
          "auth_token=YOUR_AUTH_TOKEN; Domain=.twitter.com",
          "ct0=YOUR_CT0_VALUE; Domain=.twitter.com",
          "twid=u%3DYOUR_USER_ID; Domain=.twitter.com"
        ]
        
    6. Paste Cookies in the FastMCP Connection Interface:

      • In the Install Now (FastMCP) connection interface, set the following ENV values:
        • AUTH_METHOD: cookies
        • TWITTER_COOKIES: Use your prepared formatted cookie JSON as above
  3. For Username/Password Authentication

    1. Gather Your Twitter Account Information:

      • Username, password, and if applicable, your email and 2FA secret.
    2. Enter in FastMCP Connection Interface:

      • Set:
        • AUTH_METHOD: credentials
        • TWITTER_USERNAME: Your Twitter username
        • TWITTER_PASSWORD: Your Twitter password
        • TWITTER_EMAIL: (Optional) Your associated email
        • TWITTER_2FA_SECRET: (Optional) Your Two-Factor secret, if 2FA is enabled
  4. For Twitter API Authentication

    1. Obtain API credentials from Twitter Developer Portal:

      • Go to Twitter Developer Portal
      • Create a new Project & App if you don’t have one yet
      • In your App settings, generate the following keys/tokens:
        • API Key
        • API Secret Key
        • Access Token
        • Access Token Secret
    2. Enter in FastMCP Connection Interface:

      • Set:
        • AUTH_METHOD: api
        • TWITTER_API_KEY: Your API key
        • TWITTER_API_SECRET_KEY: Your API secret key
        • TWITTER_ACCESS_TOKEN: Your access token
        • TWITTER_ACCESS_TOKEN_SECRET: Your access token secret
  5. Finalize and Install

    • Click “Install Now” in the FastMCP connection interface.
    • The MCP server will run with your provided credentials and enable Twitter interaction.

Note: If using cookies, ensure to refresh your cookies periodically as they can expire. If using API keys or password authentication, follow best practices for credential security.

Quick Start

View on GitHub

More for Communication

View All →

Similar MCP Servers

Report Issue

Thank you! Your issue report has been submitted successfully.