{"id":5913,"date":"2025-04-02T19:29:35","date_gmt":"2025-04-02T19:29:35","guid":{"rendered":"https:\/\/instruction.austincc.edu\/devtest\/using-the-server-wp-mcp-tool-a-guide\/"},"modified":"2025-04-02T19:29:35","modified_gmt":"2025-04-02T19:29:35","slug":"using-the-server-wp-mcp-tool-a-guide","status":"publish","type":"post","link":"https:\/\/instruction.austincc.edu\/devtest\/using-the-server-wp-mcp-tool-a-guide\/","title":{"rendered":"Using the server-wp-mcp Tool: A Guide"},"content":{"rendered":"<p>The server-wp-mcp tool is a powerful utility that allows you to interact with WordPress sites programmatically through a command-line interface. This tool is particularly useful for developers and administrators who need to manage WordPress content and functionality through code.<\/p>\n<h2>Getting Started<\/h2>\n<p>To use server-wp-mcp, you&#8217;ll need:<\/p>\n<p>1. Node.js installed on your system<br \/>\n2. A configuration file (.server-wp-mcp.json) with your WordPress site settings<br \/>\n3. A wp-sites.json file containing your site credentials<\/p>\n<h2>Configuration Setup<\/h2>\n<p>The tool requires two main configuration files:<\/p>\n<p>1. .server-wp-mcp.json:<br \/>\n&#8220;`json<br \/>\n{<br \/>\n  &#8220;wpSitesPath&#8221;: &#8220;.\/wp-sites.json&#8221;<br \/>\n}<br \/>\n&#8220;`<\/p>\n<p>2. wp-sites.json:<br \/>\n&#8220;`json<br \/>\n{<br \/>\n  &#8220;sitename&#8221;: {<br \/>\n    &#8220;URL&#8221;: &#8220;your-site-url&#8221;,<br \/>\n    &#8220;USER&#8221;: &#8220;your-username&#8221;,<br \/>\n    &#8220;PASS&#8221;: &#8220;your-password&#8221;<br \/>\n  }<br \/>\n}<br \/>\n&#8220;`<\/p>\n<h2>Common Use Cases<\/h2>\n<p>The tool can be used for various tasks such as:<br \/>\n&#8211; Creating and managing posts<br \/>\n&#8211; Managing users<br \/>\n&#8211; Querying content<br \/>\n&#8211; Updating site settings<\/p>\n<h2>Best Practices<\/h2>\n<p>1. Always keep your credentials secure<br \/>\n2. Use environment variables when possible<br \/>\n3. Test commands in a development environment first<br \/>\n4. Keep your Node.js version up to date<\/p>\n<h2>Troubleshooting<\/h2>\n<p>Common issues you might encounter:<\/p>\n<p>1. &#8220;Error: Missing required config values: wpSitesPath&#8221;<br \/>\n&#8211; Solution: Ensure your .server-wp-mcp.json file exists and contains the correct path<\/p>\n<p>2. Connection timeout errors<br \/>\n&#8211; Solution: Check your network connection and site URL<\/p>\n<p>3. Authentication errors<br \/>\n&#8211; Solution: Verify your credentials in wp-sites.json<\/p>\n<p>The server-wp-mcp tool streamlines WordPress management tasks and can be a valuable addition to your development workflow when properly configured and used.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The server-wp-mcp tool is a powerful utility that allows you to interact with WordPress sites programmatically through a command-line interface. This tool is particularly useful for developers and administrators who need to manage WordPress content and functionality through code. Getting Started To use server-wp-mcp, you&#8217;ll need: 1. Node.js installed on your system 2. A configuration [&hellip;]<\/p>\n","protected":false},"author":123,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[3],"tags":[7],"class_list":["post-5913","post","type-post","status-publish","format-standard","hentry","category-blog","tag-webinars"],"acf":{"carousel_content":null},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/paTq4c-1xn","_links":{"self":[{"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/posts\/5913","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/users\/123"}],"replies":[{"embeddable":true,"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/comments?post=5913"}],"version-history":[{"count":0,"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/posts\/5913\/revisions"}],"wp:attachment":[{"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/media?parent=5913"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/categories?post=5913"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/instruction.austincc.edu\/devtest\/wp-json\/wp\/v2\/tags?post=5913"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}