mister-weeden/wordpress-mcp-server
If you are the rightful owner of wordpress-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
The WordPress MCP Server is a Model Context Protocol server designed to enable Claude AI to create and manage WordPress blog posts, making it ideal for researchers, students, and professionals who want to document their work and share insights.
WordPress MCP Server
A Model Context Protocol (MCP) server that enables Claude AI to create and manage WordPress blog posts. Perfect for researchers, students, and professionals who want to document their work, share insights, and build a technical blog with AI assistance.
š Features
- Direct WordPress Integration: Create, update, and manage blog posts through Claude
- Academic Focus: Built-in prompts for thesis documentation and research blogging
- Flexible Deployment: Support for both Claude Desktop (stdio) and remote (HTTP) modes
- Rich Content Support: Handle categories, tags, excerpts, and full HTML content
- Port-Aware Configuration: Clean separation between WordPress (8000+) and MCP (9000+) ports
- Type Safety: Full type hints and async/await support
š¦ Installation
pip install wordpress-mcp-server
šÆ Quick Start
1. Install and Configure
# Install the package
pip install wordpress-mcp-server
# Test connection to your WordPress site
wordpress-mcp-server --test-connection --wordpress-url http://your-site.com
2. Claude Desktop Integration
Add to your Claude Desktop config (claude_desktop_config.json
):
{
"mcpServers": {
"wordpress-blog": {
"command": "wordpress-mcp-server",
"args": ["--mode", "stdio"],
"env": {
"WORDPRESS_URL": "http://your-wordpress-site.com",
"WORDPRESS_USERNAME": "your-username",
"WORDPRESS_PASSWORD": "your-password"
}
}
}
}
3. Start Blogging with Claude
Once configured, you can ask Claude to:
"Create a blog post about my research on Fast Fourier Transform algorithms"
"Write a thesis update documenting my progress with divide-and-conquer algorithms"
"List my recent blog posts and their status"
"Update post ID 15 with new findings from my experiments"
š§ Configuration Options
Environment Variables
export WORDPRESS_URL="http://your-site.com"
export WORDPRESS_USERNAME="admin"
export WORDPRESS_PASSWORD="your-password"
export MCP_SERVER_PORT="9001"
export MCP_SERVER_MODE="stdio"
Command Line Options
# Basic usage
wordpress-mcp-server --mode stdio
# Custom WordPress URL and port
wordpress-mcp-server \
--wordpress-url http://localhost:8888 \
--mcp-port 9001 \
--mode stdio
# HTTP mode for remote access
wordpress-mcp-server \
--mode http \
--host 0.0.0.0 \
--mcp-port 9001
# Test connection
wordpress-mcp-server --test-connection
š Perfect for Academic Blogging
Built-in Academic Prompts
The server includes specialized prompts for academic and research blogging:
Thesis Documentation
"Use the thesis_blog_post prompt to document my progress with:
- Topic: Machine Learning Algorithm Optimization
- Findings: Achieved 15% speed improvement with new caching strategy
- Challenges: Memory management issues with large datasets"
Algorithm Analysis
"Use the algorithm_analysis_post prompt for:
- Algorithm: Quicksort with median-of-three pivot selection
- Complexity: O(n log n) average case, O(n²) worst case
- Applications: Database indexing and real-time sorting systems"
Recommended Blog Structure
- Weekly Progress Updates: Document research milestones and discoveries
- Technical Deep Dives: Explain complex algorithms and implementations
- Problem-Solving Sessions: Share debugging experiences and solutions
- Literature Reviews: Summarize and analyze research papers
- Code Showcases: Highlight implementations and optimizations
š ļø Advanced Usage
Docker Deployment
# Clone and setup
git clone https://github.com/your-repo/wordpress-mcp-server
cd wordpress-mcp-server
# Build and run with Docker Compose
docker-compose up -d
# Or with custom configuration
docker run -e WORDPRESS_URL=http://your-site.com \
-e WORDPRESS_USERNAME=admin \
-e WORDPRESS_PASSWORD=secret \
wordpress-mcp-server
Development Setup
# Clone repository
git clone https://github.com/your-repo/wordpress-mcp-server
cd wordpress-mcp-server
# Setup development environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -e .[dev]
# Run tests
pytest
# Run with development settings
wordpress-mcp-server --log-level DEBUG --test-connection
š Available Tools
Blog Management Tools
Tool | Description | Parameters |
---|---|---|
create_blog_post | Create new blog post | title, content, status, excerpt, categories, tags |
update_blog_post | Update existing post | post_id, title, content, status |
list_blog_posts | List published/draft posts | status, per_page |
test_wordpress_connection | Verify WordPress connectivity | none |
Example Tool Usage
# Through Claude, you can:
"Create a blog post titled 'Understanding Big-O Notation' with content explaining
time complexity, add it to the 'Algorithms' category and tag it with 'computer-science',
'complexity-analysis', and 'education'"
"List my last 5 published posts to see what I've written recently"
"Update post ID 23 to change the status from draft to published"
š Security Considerations
- WordPress Credentials: Use WordPress Application Passwords instead of admin passwords
- Network Access: Restrict MCP server access to trusted networks only
- HTTPS: Use HTTPS for WordPress URLs in production
- Firewall Rules: Configure appropriate firewall rules for port access
š Troubleshooting
Common Issues
-
Connection Failed
# Test WordPress connection wordpress-mcp-server --test-connection # Check WordPress REST API curl http://your-site.com/wp-json/wp/v2/
-
Port Conflicts
# Check port usage netstat -an | grep :9001 # Use different port wordpress-mcp-server --mcp-port 9002
-
Permission Errors
- Ensure WordPress user has post creation permissions
- Check WordPress REST API is enabled
- Verify user roles and capabilities
Debug Mode
# Enable debug logging
wordpress-mcp-server --log-level DEBUG
# Log to file
wordpress-mcp-server --log-file wordpress-mcp.log
š Port Configuration
Service | Port Range | Default | Purpose |
---|---|---|---|
WordPress | 8000-8999 | 8888 | Web interface |
MCP Server | 9000+ | 9001 | MCP protocol |
This separation ensures clean network architecture and avoids port conflicts.
š¤ Contributing
Contributions are welcome! Please see our for details.
Development Workflow
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature
- Make changes and add tests
- Run tests:
pytest
- Submit a pull request
š License
This project is licensed under the MIT License - see the file for details.
š Use Cases
For Students
- Document thesis research progress
- Create technical tutorials and explanations
- Share project updates and insights
- Build a professional portfolio
For Researchers
- Publish research findings and methodologies
- Create accessible explanations of complex topics
- Document experimental results
- Share literature reviews and analysis
For Developers
- Write technical blog posts about algorithms
- Document software development processes
- Share coding insights and best practices
- Create educational programming content
š Examples
Check out our for:
- Sample Claude conversations
- Blog post templates
- Configuration examples
- Integration patterns
š Links
Made with ā¤ļø for the research and development community
Transform your research journey into engaging blog content with the power of AI assistance!
WordPress MCP Server - Complete Package Structure
š Directory Layout
wordpress-mcp-server/
āāā š src/
ā āāā š wordpress_mcp_server/
ā āāā š __init__.py # Package initialization and metadata
ā āāā š server.py # Main MCP server implementation
ā āāā š cli.py # Command-line interface
ā āāā š py.typed # Type hints marker file
āāā š tests/
ā āāā š __init__.py
ā āāā š test_server.py # Server tests
ā āāā š test_cli.py # CLI tests
ā āāā š conftest.py # Pytest configuration
āāā š examples/
ā āāā š basic_usage.py # Usage examples
ā āāā š claude_conversations.md # Example conversations
ā āāā š docker_example/
ā āāā š docker-compose.yml
ā āāā š .env.example
āāā š .github/
ā āāā š workflows/
ā āāā š publish.yml # GitHub Actions CI/CD
āāā š pyproject.toml # Modern Python packaging config
āāā š setup.cfg # Additional build configuration
āāā š MANIFEST.in # File inclusion rules
āāā š README.md # Package documentation
āāā š LICENSE # MIT license
āāā š CHANGELOG.md # Version history
āāā š CONTRIBUTING.md # Contribution guidelines
āāā š Dockerfile # Docker container build
āāā š docker-compose.yml # Docker Compose setup
āāā š .gitignore # Git ignore rules
āāā š .dockerignore # Docker ignore rules
āāā š requirements.txt # Legacy requirements (optional)
šļø File Descriptions
Core Package Files
File | Purpose | Contains |
---|---|---|
src/wordpress_mcp_server/__init__.py | Package entry point | Version, exports, metadata |
src/wordpress_mcp_server/server.py | Main functionality | MCP server, WordPress client |
src/wordpress_mcp_server/cli.py | Command interface | Argument parsing, entry points |
src/wordpress_mcp_server/py.typed | Type safety | PEP 561 marker for type hints |
Configuration Files
File | Purpose | Configures |
---|---|---|
pyproject.toml | Package metadata | Dependencies, build system, tools |
setup.cfg | Additional config | Linting rules, test options |
MANIFEST.in | File inclusion | What files to include in package |
Documentation
File | Purpose | Audience |
---|---|---|
README.md | Main documentation | Users, PyPI page |
CHANGELOG.md | Version history | Users, maintainers |
CONTRIBUTING.md | Development guide | Contributors |
LICENSE | Legal terms | Everyone |
Testing & CI/CD
File | Purpose | Used For |
---|---|---|
tests/ | Test suite | Quality assurance |
.github/workflows/publish.yml | Automation | CI/CD pipeline |
Deployment
File | Purpose | Deployment |
---|---|---|
Dockerfile | Container build | Docker deployment |
docker-compose.yml | Service orchestration | Multi-container setup |
š¦ Installation Methods
1. From PyPI (Production)
pip install wordpress-mcp-server
2. From Source (Development)
git clone https://github.com/YOUR_USERNAME/wordpress-mcp-server.git
cd wordpress-mcp-server
pip install -e .[dev]
3. From Docker
docker pull wordpress-mcp-server:latest
docker run -e WORDPRESS_URL=http://your-site.com wordpress-mcp-server
š Quick Start Commands
Package Usage
# Basic usage
wordpress-mcp-server --mode stdio
# With custom configuration
wordpress-mcp-server \
--wordpress-url http://localhost:8888 \
--mcp-port 9001 \
--mode stdio
# Test connection
wordpress-mcp-server --test-connection
# HTTP mode for remote access
wordpress-mcp-server --mode http --host 0.0.0.0 --mcp-port 9001
Development Commands
# Setup development environment
python -m venv venv
source venv/bin/activate
pip install -e .[dev,test]
# Run tests
pytest tests/ -v
# Lint code
black src tests
flake8 src tests
mypy src
# Build package
python -m build
# Check package
twine check dist/*
š Workflow Overview
Development Workflow
- Clone repository
- Setup environment (
venv
, install dependencies) - Make changes (code, tests, docs)
- Test locally (pytest, linting)
- Commit and push
- Create pull request
Release Workflow
- Update version (pyproject.toml, init.py)
- Update CHANGELOG.md
- Test thoroughly
- Create GitHub release
- GitHub Actions publishes to PyPI
User Workflow
- Install package (
pip install wordpress-mcp-server
) - Configure WordPress (URL, credentials)
- Setup Claude Desktop (config file)
- Start blogging with AI assistance!
š File Creation Checklist
When setting up the package, create files in this order:
Phase 1: Core Package
-
src/wordpress_mcp_server/__init__.py
-
src/wordpress_mcp_server/server.py
-
src/wordpress_mcp_server/cli.py
-
src/wordpress_mcp_server/py.typed
Phase 2: Configuration
-
pyproject.toml
-
MANIFEST.in
-
setup.cfg
(optional)
Phase 3: Documentation
-
README.md
-
LICENSE
-
CHANGELOG.md
-
CONTRIBUTING.md
Phase 4: Testing
-
tests/__init__.py
-
tests/test_server.py
-
tests/test_cli.py
-
tests/conftest.py
Phase 5: CI/CD
-
.github/workflows/publish.yml
-
.gitignore
Phase 6: Docker (Optional)
-
Dockerfile
-
docker-compose.yml
-
.dockerignore
Phase 7: Examples
-
examples/basic_usage.py
-
examples/claude_conversations.md
šÆ Key Features
For Users
- Easy Installation:
pip install wordpress-mcp-server
- Simple Configuration: Environment variables and CLI options
- Claude Integration: Works seamlessly with Claude Desktop
- Academic Focus: Built-in prompts for research documentation
For Developers
- Modern Python: Type hints, async/await, Python 3.8+
- Quality Assurance: Tests, linting, CI/CD
- Documentation: Comprehensive README and examples
- Easy Contributing: Clear development setup
For Deployment
- Multiple Options: pip, Docker, source installation
- Flexible Configuration: CLI, environment variables, config files
- Port Management: Smart port allocation (8000+ for WordPress, 9000+ for MCP)
š Next Steps
Once you've created this structure:
- Test locally to ensure everything works
- Publish to Test PyPI first for validation
- Create GitHub repository and push code
- Setup GitHub Actions for automated publishing
- Publish to PyPI for worldwide access
- Share with community and gather feedback
This package structure follows Python packaging best practices and will provide a professional, maintainable foundation for the WordPress MCP Server!