WordPress MCP サーバー
Windows、macOS、Linux と互換性のある、WordPress 統合用のモデル コンテキスト プロトコル (MCP) サーバー。
概要
このMCPサーバーは、WordPress REST APIを介してWordPressサイトとのやり取りを可能にします。JSON-RPC 2.0プロトコルを使用して投稿を作成、取得、更新するためのツールを提供します。
インストール
リポジトリをクローンする
依存関係をインストールします:
プロジェクトをビルドします。
構成
WordPress 資格情報の環境変数を使用して、サーバーを MCP 設定ファイルに追加します。
環境変数は次のとおりです。
WORDPRESS_SITE_URL: WordPressサイトのURL
WORDPRESS_USERNAME: WordPressユーザー名
WORDPRESS_PASSWORD: WordPressアプリケーションのパスワード
環境変数を使用したくない場合は、リクエストパラメータでこれらの資格情報を提供することもできます。
利用可能な方法
投稿を作成
新しい WordPress 投稿を作成します。
パラメータ:
siteUrl: (env で設定されている場合オプション) WordPress サイトの URL
ユーザー名: (envで設定されている場合オプション) WordPressユーザー名
パスワード: (env で設定されている場合オプション) WordPress アプリケーションのパスワード
タイトル: 投稿タイトル
コンテンツ: 投稿内容
ステータス: (オプション)「下書き」 | 「公開」 | 「非公開」(デフォルト:「下書き」)
get_posts
WordPress の投稿を取得します。
パラメータ:
siteUrl: (env で設定されている場合オプション) WordPress サイトの URL
ユーザー名: (envで設定されている場合オプション) WordPressユーザー名
パスワード: (env で設定されている場合オプション) WordPress アプリケーションのパスワード
perPage: (オプション) ページあたりの投稿数 (デフォルト: 10)
ページ: (オプション) ページ番号 (デフォルト: 1)
更新投稿
既存の WordPress 投稿を更新します。
パラメータ:
siteUrl: (env で設定されている場合オプション) WordPress サイトの URL
ユーザー名: (envで設定されている場合オプション) WordPressユーザー名
パスワード: (env で設定されている場合オプション) WordPress アプリケーションのパスワード
postId: 更新する投稿のID
タイトル: (オプション) 新しい投稿のタイトル
コンテンツ: (オプション) 新しい投稿の内容
ステータス: (オプション)「下書き」 | 「公開」 | 「非公開」
セキュリティに関する注意事項
セキュリティのため、メインアカウントのパスワードではなく、WordPressアプリケーションパスワードを使用することをお勧めします。アプリケーションパスワードは、WordPressダッシュボードの「ユーザー」→「セキュリティ」→「アプリケーションパスワード」で生成できます。
使用例
環境変数の使用:
環境変数なし:
要件
Node.js 20.0.0以上
REST API が有効になっている WordPress サイト
認証用のWordPressアプリケーションのパスワード
ライセンス
MITライセンス - 詳細はLICENSEファイルを参照
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.
REST API を介して WordPress サイトとのやり取りを可能にし、ユーザーが JSON-RPC 2.0 プロトコルを使用して投稿を作成、取得、更新できるようにするサーバー。
Related Resources
Related MCP Servers
- -securityAlicense-qualityEnables AI assistants to interact with WordPress sites through the WordPress REST API. Supports multiple WordPress sites with secure authentication, enabling content management, post operations, and site configuration through natural language.Last updated -40104MIT License
- -securityFlicense-qualityA server enabling seamless interaction between AI models and WordPress sites with secure, standardized communication using the WordPress REST API for comprehensive site management.Last updated -276
- AsecurityAlicenseAqualityA server allowing interaction with Reddit via the public API, enabling browsing frontpage posts, retrieving subreddit details, and reading post comments through a Model Context Protocol.Last updated -8106MIT License
- -securityAlicense-qualityEnables AI assistants to interact with WordPress sites through the REST API. Supports multiple WordPress sites with secure authentication, enabling content management, post operations, and site configuration through natural language.Last updated -40MIT License