Skip to content

Security & Configuration

ResourceAccessScope
FilesystemRead + WriteOnly the paths you specify in tool calls
MySQL databaseRead + WriteOnly the WordPress database configured in env variables
NetworkNoneThe server has no outbound connections
SystemNoneNo shell commands, no process execution

The server does not make any HTTP requests. It communicates only via stdio with the MCP client (Claude Desktop, Claude Code, etc.) and via MySQL with your database (if configured).


The server reads credentials from environment variables. There are two ways to provide them.

Create a .env file in the same directory as the divi-translator binary:

.env
WP_MYSQL_HOST=localhost
WP_MYSQL_PORT=3306
WP_MYSQL_USER=db_user
WP_MYSQL_PASSWORD=db_password
WP_MYSQL_DATABASE=wordpress_db
WP_TABLE_PREFIX=wp_
WP_BACKUP_DIR=/path/to/backups

The server loads this file automatically at startup. If the file is not found in the binary’s directory, the server also checks the current working directory.

Pass credentials via the env block in claude_desktop_config.json:

claude_desktop_config.json
{
"mcpServers": {
"divi-translator": {
"command": "/path/to/divi-translator",
"args": [],
"env": {
"WP_MYSQL_USER": "db_user",
"WP_MYSQL_PASSWORD": "db_password",
"WP_MYSQL_DATABASE": "wordpress_db"
}
}
}
}

VariableRequiredDefaultDescription
WP_MYSQL_HOSTlocalhostMySQL server hostname
WP_MYSQL_PORT3306MySQL port
WP_MYSQL_USERMySQL username
WP_MYSQL_PASSWORDMySQL password (empty = no password)
WP_MYSQL_DATABASEWordPress database name
WP_TABLE_PREFIXwp_WordPress table prefix
WP_BACKUP_DIRcurrent dirDirectory for backup files

MySQL credentials are only required if you use the extract_wordpress_text tool. File-based translation (extract_divi_text) works without any environment variables.


Every WordPress post translation creates a backup before writing any changes. This is automatic and cannot be disabled.

Backup location: {WP_BACKUP_DIR}/post_{id}_{timestamp}.txt

Backup includes:

  • Post ID
  • Backup timestamp
  • Original title
  • Original slug
  • Original excerpt
  • Full post content (with all Divi shortcodes)

To restore a post manually:

  1. Open the backup file and copy the content section (after the --- separator)
  2. Go to WordPress admin → Posts → Edit the post
  3. Switch to the Text editor (not Visual)
  4. Paste the original content
  5. Restore the title, slug, and excerpt from the backup header
  6. Update the post

Alternatively, restore directly via MySQL:

UPDATE wp_posts
SET
post_title = 'Original Title',
post_name = 'original-slug',
post_excerpt = 'Original excerpt...',
post_content = '[et_pb_section ...]...[/et_pb_section]'
WHERE ID = 42;

The server passes text through Claude for translation. At no point does it execute the translated content as code. The output is stored as plain text in a file or as a WordPress post content field.

Divi shortcodes are never sent to Claude — they are extracted before the text is returned and reinserted from the server’s memory after the translation is received.


  1. Keep the divi-translator binary updated to the latest release
  2. Store credentials in environment variables, not in the command arguments
  3. Set restrictive permissions on .env: chmod 600 .env
  4. Do not expose the binary on a network-accessible port — it runs over stdio only
  5. Set WP_BACKUP_DIR to a directory outside the web root
  6. Review backup files periodically and remove old ones
  7. Use a dedicated MySQL user with only SELECT, UPDATE permissions on the WordPress database

Report bugs and vulnerabilities at: github.com/scopweb/mcp-go-divi-translation/issues

For security-related issues, open a private security advisory on GitHub rather than a public issue.