Twitter MCP サーバー
Twitter API 統合のためのモデル コンテキスト プロトコル サーバーの実装。
設定
- リポジトリをクローンする
- 依存関係をインストール:
npm install
.env.example
を.env
にコピーし、Twitter API の認証情報を入力します。- プロジェクトをビルドします:
npm run build
- サーバーを起動します:
npm start
環境変数
.env
に必要な Twitter API 認証情報:
利用可能なツール
ツイート操作
postTweet
: 新しいツイートを投稿するpostTweetWithMedia
: メディアを添付したツイートを投稿するgetTweetById
: IDで特定のツイートを取得するreplyToTweet
: 既存のツイートに返信するdeleteTweet
: ツイートを削除する
検索と分析
searchTweets
: ツイートを検索getHashtagAnalytics
: ハッシュタグの分析情報を取得する
ユーザー操作
getUserInfo
: ユーザー情報を取得するgetUserTimeline
: ユーザーのツイートを取得するgetFollowers
: ユーザーのフォロワーを取得するgetFollowing
: ユーザーがフォローしているアカウントを取得する
婚約
likeTweet
: ツイートにいいねする- ツイートを
unlikeTweet
しない retweet
: ツイートをリツイートするundoRetweet
: リツイートを元に戻すgetRetweets
: ツイートをリツイートしたユーザーを取得するgetLikedTweets
: ユーザーが「いいね!」したツイートを取得する
リスト管理
createList
: 新しいリストを作成するaddUserToList
: ユーザーをリストに追加するremoveUserFromList
: リストからユーザーを削除するgetListMembers
: リストのメンバーを取得する
エラー処理
すべてのツールは標準化されたエラー応答を返します。
- 不足しているパラメータ:
Missing required parameter: parameter_name
- APIエラー: Twitter APIからのエラーメッセージ
- 見つからないエラー: リソースに適切な「見つからない」メッセージ
応答フォーマット
すべての成功した応答は次の形式に従います。
発達
- ビルド:
npm run build
- 開始:
npm start
- ウォッチモード:
npm run dev
ステータス: 正常に動作しています レスポンス: ツイートIDを返します 最新のテスト: 成功
ステータス: 正常に動作しています レスポンス: 完全なツイートデータを返します 最新のテスト: 成功
ステータス: 正常に動作しています 応答: アクションの確認 最新のテスト: 成功
ステータス: 正常に動作しています 応答: アクションの確認 最新のテスト: 成功
ステータス: 正常に動作しています レスポンス: 返信ツイートIDを返します 最新のテスト: 成功
ステータス: 正常に動作しています 応答: ユーザープロファイルデータが完了しました 最新のテスト: 成功
ステータス: 正常に動作しています 応答: アクションの確認 最新のテスト: 成功
ステータス: 正常に動作しています 応答: リスト作成の確認 最新のテスト: 成功
ステータス: 正常に動作しています 応答: 所有リストとメンバーリストの両方を返します 最新のテスト: 成功
ステータス: エラー 400 エラー: 無効なリクエストパラメータ 必要な修正: パラメータ検証
ステータス: エラー 400 エラー: 無効なリクエストパラメータ 必要な修正: クエリパラメータのフォーマット
ステータス: エラー 400 エラー: 無効なリクエストパラメータ 必要な修正: パラメータ検証
- エラー処理:
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
Tools
モデル コンテキスト プロトコルを介して Twitter とのやり取りを可能にし、大規模な言語モデルによるツイートの投稿、ツイートの検索、ツイートへの返信を可能にします。
Related Resources
Related MCP Servers
- -securityFlicense-qualityProvides AI agents with comprehensive Twitter functionality through the Model Context Protocol standard, enabling reading tweets, posting content, managing interactions, and accessing timeline data with robust error handling.Last updated -41JavaScript
- -securityAlicense-qualityA Model Context Protocol server that enables AI to interact with Twitter, allowing functions like searching tweets, comparing sentiments across accounts, and retrieving timeline content.Last updated -MIT License
- -securityAlicense-qualityA Model Context Protocol server that enables AI models and applications to interact directly with Twitter/X, providing capabilities to create posts, reply to tweets, retrieve user data, and manage account actions.Last updated -874TypeScriptMIT License
Juhe News MCP Serverofficial
-securityFlicense-qualityA Model Context Protocol server that enables large language models to access the latest trending news headlines and detailed content across various categories including recommended, domestic, technology, and sports news.Last updated -Python