diff --git a/docs.json b/docs.json index b2b0def..ff0c5d0 100644 --- a/docs.json +++ b/docs.json @@ -45,7 +45,8 @@ "group": "Developer Tools", "pages": [ "docs/getting-started/client-libraries", - "docs/getting-started/deepl-cli" + "docs/getting-started/deepl-cli", + "docs/getting-started/deepl-mcp-server" ] }, "docs/getting-started/managing-api-keys", diff --git a/docs/getting-started/deepl-mcp-server.mdx b/docs/getting-started/deepl-mcp-server.mdx new file mode 100644 index 0000000..d5570cc --- /dev/null +++ b/docs/getting-started/deepl-mcp-server.mdx @@ -0,0 +1,119 @@ +--- +title: "DeepL MCP Server" +description: "Use the DeepL MCP Server to add translation capabilities to Claude, Cursor, and other AI agents." +public: true +--- + +**This page shows you:** +- What the DeepL MCP Server does and when to use it +- How to install and configure it for Claude Code and Claude Desktop +- What tools are available to your AI agent + +The [DeepL MCP Server](https://github.com/DeepLcom/deepl-mcp-server) is an open-source (MIT license) [Model Context Protocol](https://modelcontextprotocol.io/) server that gives AI agents access to DeepL's translation, text improvement, and glossary capabilities. MCP lets AI agents discover and call external tools through a standardized protocol — your agent sends a tool request to the MCP server, which calls the DeepL API and returns the result. + + +If you want to build a custom MCP server from scratch using the DeepL API, see the [MCP Server Cookbook](/docs/learning-how-tos/examples-and-guides/deepl-mcp-server-how-to-build-and-use-translation-in-llm-applications). + + +## Prerequisites + +- [Node.js](https://nodejs.org/) v18 or later +- A DeepL API key ([create a free account](https://www.deepl.com/en/pro/change-plan#developer)) + +## Quick start + +Run the server directly with npx: + +```bash +npx deepl-mcp-server +``` + +Or install it locally: + +```bash +npm install deepl-mcp-server +``` + +## Configuration + + + + +Add the MCP server to Claude Code with a single command: + +```bash +claude mcp add deepl -e DEEPL_API_KEY=your-api-key -- npx deepl-mcp-server +``` + +Claude Code will now have access to DeepL translation tools in every session. + + + + +Add the following to your Claude Desktop configuration file: + +- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json` +- **Windows**: `%AppData%\Claude\claude_desktop_config.json` +- **Linux**: `~/.config/Claude/claude_desktop_config.json` + +```json +{ + "mcpServers": { + "deepl": { + "command": "npx", + "args": ["deepl-mcp-server"], + "env": { + "DEEPL_API_KEY": "your-api-key" + } + } + } +} +``` + +Restart Claude Desktop to activate the server. + + + + +The DeepL MCP Server works with any MCP-compatible client. Configure it using the `npx deepl-mcp-server` command and pass your API key via the `DEEPL_API_KEY` environment variable. + +Refer to your client's documentation for how to add MCP servers. + + + + +## Available tools + +Once configured, your AI agent can use the following tools: + +| **Tool** | **Description** | +|----------|-----------------| +| `translate-text` | Translate text between languages with automatic source language detection | +| `translate-document` | Translate documents (PDF, DOCX, PPTX, XLSX, HTML, TXT) with format preservation | +| `rephrase-text` | Improve and rephrase text with customizable writing style and tone | +| `get-source-languages` | List all available source languages | +| `get-target-languages` | List all available target languages | +| `get-glossary-info` | Retrieve details about a specific glossary | +| `get-glossary-entries` | Fetch dictionary entries from a glossary | +| `list-glossaries` | List all glossaries in your account | + +## Example usage + +Once the MCP server is connected, you can ask your AI agent things like: + +- "Translate this email into German with formal tone" +- "Translate my report.pdf into French" +- "Rephrase this paragraph to sound more professional" +- "What languages does DeepL support?" +- "Show me the entries in my marketing glossary" + +The agent will automatically use the appropriate DeepL tool to fulfill the request. + +## Next steps + +Now that you know how to use the DeepL MCP Server: + +- **Explore the source:** Review the [DeepL MCP Server on GitHub](https://github.com/DeepLcom/deepl-mcp-server) for full documentation and source code +- **Build your own:** Follow the [MCP Server Cookbook](/docs/learning-how-tos/examples-and-guides/deepl-mcp-server-how-to-build-and-use-translation-in-llm-applications) to create a custom MCP server from scratch +- **Set up authentication:** Learn about [DeepL API authentication](/docs/getting-started/auth) and key management +- **Use client libraries:** Explore the [official SDKs](/docs/getting-started/client-libraries) for Python, Node.js, and more