README.mdโข17.5 kB
# ๐ POEditor MCP Server
A comprehensive Model Context Protocol (MCP) server for POEditor translation management, featuring advanced automation scripts and workflow optimization tools.
[](https://github.com/r-pedraza/poeditor-mcp/releases)
[](https://www.python.org/)
[](https://opensource.org/licenses/MIT)
[](https://github.com/r-pedraza/poeditor-mcp/stargazers)
[](https://github.com/modelcontextprotocol)
[](https://poeditor.com/)
[](https://claude.ai/)
[](https://code.visualstudio.com/)
[](https://github.com/r-pedraza/poeditor-mcp/issues)
[](https://github.com/r-pedraza/poeditor-mcp/pulls)
[](https://github.com/r-pedraza/poeditor-mcp/commits/main)
[](https://github.com/r-pedraza/poeditor-mcp)
## ๐ **Features**
- **๐ Complete MCP Server**: Full integration with POEditor API
- **๐๏ธ Control Center**: Master script to manage all automation tools
- **๐ Smart Reporting**: Interactive HTML reports with progress tracking
- **๐จ Monitoring System**: Automated alerts for translation issues
- **๐ค AI Automation**: Intelligent translation suggestions and consistency checking
- **๐ง Notifications**: Email and Slack integration for team updates
- **๐ฆ Mass Export**: Multi-format export system for all platforms
- **๐ Scheduler**: Automated task execution with cron-like functionality
## ๐ฏ **Why This MCP?**
Unlike other MCP servers that require complex Docker setups, POEditor MCP is designed for simplicity:
- โ **No Docker required** - Pure Python implementation
- ๐ฏ **Translation-focused** - Built specifically for localization workflows
- ๐ง **Minimal setup** - Just add your API token and run
- ๐ **Instant execution** - `python setup.py && python control_center.py`
- ๐ **Visual reports** - Beautiful HTML dashboards
- ๐ค **Built-in AI** - Smart translation suggestions
## ๐ **Project Status**
[](https://github.com/r-pedraza/poeditor-mcp)
[](https://github.com/r-pedraza/poeditor-mcp/commits/main)
[](https://poeditor.com/docs/api)
[](https://github.com/r-pedraza/poeditor-mcp#documentation)
| Feature | Status | Description |
|---------|--------|-------------|
| ๐ MCP Server | โ
Complete | Full MCP protocol implementation |
| ๐ฏ POEditor API | โ
Complete | All API endpoints covered |
| ๐ค Claude Desktop | โ
Supported | Ready-to-use configuration |
| ๐ง VS Code | โ
Supported | MCP extension compatible |
| ๐ Automation | โ
Complete | 10+ automation scripts |
| ๐ Documentation | โ
Complete | Comprehensive guides |
| ๐งช Testing | โ
Complete | Thorough test coverage |
| ๐ Internationalization | ๐ง Planned | Multi-language support |
## ๐ **Quick Start**
### 1. **Automatic Setup** (Recommended)
```bash
# Clone the repository
git clone https://github.com/yourusername/poeditor-mcp.git
cd poeditor-mcp
# Run the automatic setup script
python setup.py
# Follow the interactive prompts to configure your POEditor API token
```
### 2. **Manual Setup**
```bash
# Install dependencies
pip install -r requirements.txt
# Copy environment template
cp .env.template .env
# Edit .env with your POEditor API token
nano .env
# Test the connection
python test_connection.py
```
### 3. **Start Using**
```bash
# Show all available commands
python control_center.py help
# Run daily monitoring
python control_center.py monitor
# Generate progress report
python control_center.py daily_report
# Start automated scheduling
python control_center.py schedule start
```
## ๏ฟฝ **MCP Client Configuration**
Once installed, configure your MCP client to use the POEditor server:
### **๐ฏ Claude Desktop**
Add this configuration to your Claude Desktop config file:
**macOS/Linux**: `~/.claude_desktop_config.json`
**Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
```json
{
"mcpServers": {
"poeditor": {
"command": "python",
"args": ["-m", "mcp_poeditor"],
"cwd": "/path/to/your/poeditor-mcp",
"env": {
"POEDITOR_API_TOKEN": "your_poeditor_token_here"
}
}
}
}
```
### **๐ง Visual Studio Code**
Add this configuration to your VS Code settings:
**File**: `.vscode/settings.json` (workspace) or user settings
```json
{
"mcp.servers": {
"poeditor": {
"command": "python",
"args": ["-m", "mcp_poeditor"],
"cwd": "/path/to/your/poeditor-mcp",
"env": {
"POEDITOR_API_TOKEN": "your_poeditor_token_here"
}
}
}
}
```
### **๐ Configuration Notes**
- Replace `/path/to/your/poeditor-mcp` with the actual path to your installation
- Replace `your_poeditor_token_here` with your actual POEditor API token
- Restart your MCP client after configuration
- Use the provided example files: `claude_desktop_config_example.json` and `vscode_settings_example.json`
## ๏ฟฝ๐ ๏ธ **Available Tools**
The MCP server provides comprehensive POEditor management through these tool categories:
### **๐ Project Management**
- `list_projects` - List all projects
- `get_project` - Get project details
- `create_project` - Create new project
### **๐ Language Management**
- `list_languages` - List project languages
- `add_language` - Add language to project
- `remove_language` - Remove language from project
### **๐ Term Management**
- `list_terms` - List project terms
- `search_terms` - Search terms by key/value
- `add_terms` - Add new terms
- `delete_terms` - Remove terms
### **โ๏ธ Translation Management**
- `list_translations` - Get language translations
- `add_translation` - Add new translation
- `update_translation` - Update existing translation
- `export_translations` - Export in multiple formats
### **๐ Statistics & Analytics**
- `get_project_stats` - Project statistics
- `get_translation_progress` - Progress by language
- `compare_languages` - Language comparison analysis
## ๐๏ธ **Automation Scripts**
The project includes a powerful suite of automation scripts accessible through the control center:
```bash
python control_center.py <command>
```
### **๐ Reporting & Analytics**
- `daily_report` - Generate comprehensive HTML progress reports
- `status` - Check system health and configuration
### **๐จ Monitoring & Alerts**
- `monitor` - Scan for translation issues and quality problems
- `test` - Run system diagnostics
### **๐ค Automation**
- `automate` - AI-powered translation suggestions and consistency checks
- `schedule` - Automated task scheduling and execution
### **๐ Optimization**
- `optimize` - Workflow analysis with actionable recommendations
- `sync` - Synchronize translations between similar projects
### **๐ฆ Export & Integration**
- `export` - Mass export in multiple formats (JSON, Android XML, iOS Strings, etc.)
- `notify` - Send team notifications via email/Slack
### **๐ง Management**
- `setup` - Interactive environment configuration
- `demo` - Complete system demonstration
## ๐ **Project Structure**
```
poeditor-mcp/
โโโ ๐ README.md # This file
โโโ ๐ requirements.txt # Python dependencies
โโโ ๐ .env.template # Environment template
โโโ ๐ setup.py # Automatic setup script
โโโ ๐ test_connection.py # Connection test utility
โโโ ๐ claude_desktop_config_example.json # Claude Desktop config example
โโโ ๐ vscode_settings_example.json # VS Code config example
โโโ ๐ CONFIG_README.md # Configuration guide
โ
โโโ ๐ mcp_poeditor/ # Core MCP package
โ โโโ ๐ __init__.py
โ โโโ ๐ __main__.py # Entry point
โ โโโ ๐ server.py # MCP server implementation
โ โโโ ๐ poeditor_client.py # POEditor API client
โ โ
โ โโโ ๐ tools/ # MCP tools
โ โ โโโ ๐ projects.py # Project management
โ โ โโโ ๐ languages.py # Language management
โ โ โโโ ๐ terms.py # Term management
โ โ โโโ ๐ translations.py # Translation management
โ โ โโโ ๐ stats.py # Statistics & analytics
โ โ
โ โโโ ๐ utils/ # Utilities
โ โโโ ๐ config.py # Configuration management
โ โโโ ๐ helpers.py # Helper functions
โ
โโโ ๐ scripts/ # ๐๏ธ AUTOMATION SUITE
โ โโโ ๐ README.md # Scripts documentation
โ โโโ ๐ control_center.py # ๐๏ธ Master control script
โ โโโ ๐ daily_report.py # ๐ Daily progress reports
โ โโโ ๐ translation_monitor.py # ๐จ Quality monitoring
โ โโโ ๐ workflow_optimizer.py # ๐ Workflow optimization
โ โโโ ๐ project_sync.py # ๐ Project synchronization
โ โโโ ๐ notification_manager.py # ๐ง Team notifications
โ โโโ ๐ translation_automator.py # ๐ค AI automation
โ โโโ ๐ mass_exporter.py # ๐ฆ Multi-format export
โ โโโ ๐ scheduler.py # ๐ Task scheduling
โ โโโ ๐ demo_workflow.py # ๐ฏ Complete demo
โ
โโโ ๐ examples/ # Usage examples
โ โโโ ๐ basic_usage.py # Basic MCP usage
โ โโโ ๐ automation_examples.py # Automation examples
โ โโโ ๐ integration_guide.md # Integration guide
โ
โโโ ๐ docs/ # Documentation
โโโ ๐ INSTALLATION.md # Detailed installation
โโโ ๐ CONFIGURATION.md # Configuration guide
โโโ ๐ API_REFERENCE.md # API documentation
โโโ ๐ CONTRIBUTING.md # Contribution guidelines
```
## ๐ง **Configuration**
### **Environment Variables**
Create a `.env` file in the root directory:
```env
# POEditor API Configuration
POEDITOR_API_TOKEN=your_api_token_here
POEDITOR_API_URL=https://api.poeditor.com/v2/
# MCP Server Configuration
MCP_SERVER_NAME=poeditor-mcp
MCP_SERVER_VERSION=1.0.0
# Notification Settings (Optional)
SMTP_SERVER=smtp.gmail.com
SMTP_PORT=587
SMTP_USERNAME=your_email@company.com
SMTP_PASSWORD=your_app_password
SLACK_WEBHOOK_URL=https://hooks.slack.com/services/...
# Automation Settings
DEFAULT_EXPORT_FORMAT=json
MAX_RETRIES=3
REQUEST_TIMEOUT=30
LOG_LEVEL=INFO
```
### **Scheduler Configuration**
Customize automation schedules in `scripts/scheduler_config.json`:
```json
{
"schedules": {
"daily_report": {
"time": "08:00",
"enabled": true,
"weekdays_only": true,
"description": "Generate daily progress report"
},
"monitoring": {
"time": "09:00",
"enabled": true,
"weekdays_only": true,
"description": "Run translation quality monitoring"
},
"weekly_optimization": {
"day": "monday",
"time": "08:30",
"enabled": true,
"description": "Weekly workflow optimization analysis"
}
}
}
```
## ๐ **Usage Examples**
### **Basic Translation Management**
```python
from mcp_poeditor.server import call_tool
# List all projects
projects = await call_tool("list_projects", {})
# Get project languages
languages = await call_tool("list_languages", {"project_id": "123456"})
# Search for specific terms
results = await call_tool("search_terms", {
"project_id": "123456",
"search_query": "login"
})
# Export translations
export_url = await call_tool("export_translations", {
"project_id": "123456",
"language_code": "es",
"file_format": "json"
})
```
### **Automation Workflow**
```bash
# Morning routine
python control_center.py monitor # Check for issues
python control_center.py daily_report # Generate progress report
# Development workflow
python control_center.py automate # Get AI suggestions
python control_center.py export # Export for developers
# Weekly optimization
python control_center.py optimize # Analyze workflow efficiency
python control_center.py sync # Sync related projects
```
### **Integration with CI/CD**
```yaml
# GitHub Actions example
name: Translation Export
on:
schedule:
- cron: '0 8 * * *' # Daily at 8 AM
jobs:
export:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install dependencies
run: pip install -r requirements.txt
- name: Export translations
env:
POEDITOR_API_TOKEN: ${{ secrets.POEDITOR_API_TOKEN }}
run: python control_center.py export
```
## ๐ **Automated Workflows**
### **Daily Automation**
- ๐
**Morning**: Quality monitoring and progress reports
- ๐ **Midday**: AI-powered translation suggestions
- ๐ **Evening**: Export updates for development teams
### **Weekly Optimization**
- ๐ **Monday**: Workflow analysis and optimization recommendations
- ๐ **Wednesday**: Project synchronization and consistency checks
- ๐ฆ **Friday**: Complete backup and multi-format export
### **Real-time Monitoring**
- ๐จ **Quality alerts**: Fuzzy translations, consistency issues
- ๐ **Progress tracking**: Language completion milestones
- ๐ฅ **Team notifications**: Slack/email updates for important events
## ๐ฏ **Supported Export Formats**
Perfect for any development workflow:
- ๐ฑ **Mobile**: Android XML, iOS Strings, React Native JSON
- ๐ **Web**: JSON, CSV for React/Vue/Angular applications
- ๐ฅ๏ธ **Backend**: Gettext PO, Java Properties, YAML
- ๐ **Analysis**: Excel XLSX, CSV for progress tracking
- ๐ **Integration**: XLIFF, TMX for CAT tools
## ๐ **Documentation**
- [๐ Installation Guide](docs/INSTALLATION.md) - Detailed setup instructions
- [โ๏ธ Configuration Guide](docs/CONFIGURATION.md) - Advanced configuration options
- [๐ง API Reference](docs/API_REFERENCE.md) - Complete API documentation
- [๐ Integration Guide](examples/integration_guide.md) - Platform integration examples
- [๐ค Contributing](docs/CONTRIBUTING.md) - How to contribute to the project
## ๐ **Troubleshooting**
### **Common Issues**
**Connection Failed**
```bash
# Test your POEditor API token
python test_connection.py
# Check configuration
python control_center.py status
```
**Missing Dependencies**
```bash
# Reinstall requirements
pip install -r requirements.txt
# Run system diagnostics
python control_center.py test
```
**Permission Errors**
```bash
# Fix file permissions
chmod +x setup.py
chmod +x control_center.py
```
### **Getting Help**
1. ๐ **Check logs**: `./logs/` directory contains detailed execution logs
2. ๐งช **Run diagnostics**: `python control_center.py test`
3. ๐ **System status**: `python control_center.py status`
4. ๐ **Report issues**: Create a GitHub issue with log details
## ๐ค **Contributing**
We welcome contributions! Please see our [Contributing Guide](docs/CONTRIBUTING.md) for details on:
- ๐ Reporting bugs
- ๐ก Suggesting features
- ๐ง Submitting pull requests
- ๐ Improving documentation
## ๐ **License**
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
## ๐ **Acknowledgments**
- [Model Context Protocol](https://github.com/modelcontextprotocol) for the excellent MCP framework
- [POEditor](https://poeditor.com) for their comprehensive translation management API
- The open-source community for inspiration and best practices
---
**โญ If this project helps you, please consider giving it a star!**
**๐ Start automating your translation workflow today!**