rewrite
Automated mass refactoring of source code.
The OpenRewrite MCP server provides AI agents with programmatic access to automated code refactoring capabilities through the Model Context Protocol. Built by Moderne on top of the open-source OpenRewrite framework, it exposes type-aware search and refactoring recipes as deterministic tool calls that agents can invoke. This MCP server enables coding assistants to migrate frameworks, fix security issues, and apply stylistic changes across Java, Kotlin, Groovy, JavaScript/TypeScript, Python, and C# codebases with pre-computed context from Lossless Semantic Trees, reducing token overhead while improving accuracy.
Key Features
Use Cases
- 01Enabling AI coding assistants to perform automated framework migrations across codebases
- 02Allowing agents to fix security vulnerabilities using pre-packaged remediation recipes
- 03Providing coding agents with type-aware semantic search across large repositories
- 04Automating code style and consistency enforcement through agent-driven refactoring
- 05Supporting AI-powered technical debt reduction with contextual code transformations
- 06Integrating refactoring capabilities into agent workflows with minimal token overhead
Related MCP Servers
View moremarkitdown
Python tool for converting files and office documents to Markdown.
firecrawl
The context API to search, scrape, and interact with the web at scale. 🔥
prompts.chat
f.k.a. Awesome ChatGPT Prompts. Share, discover, and collect prompts from the community. Free and open source — self-host for your organization with complete privacy.
langflow
Langflow is a powerful tool for building and deploying AI-powered agents and workflows.
rewrite — FAQ
What is the OpenRewrite MCP server?+
The OpenRewrite MCP server is a Model Context Protocol integration that exposes automated refactoring recipes and type-aware code analysis capabilities to AI agents. It allows coding assistants to understand and transform source code across multiple languages using OpenRewrite's Lossless Semantic Tree technology.
How do I install the OpenRewrite MCP server?+
The OpenRewrite MCP server is part of Moderne's agent tools suite. Installation details are available through the Moderne CLI and documentation at docs.moderne.io. You'll need to configure your MCP client to connect to the local server endpoint provided by Moderne.
Which AI clients work with the OpenRewrite MCP server?+
The MCP server is compatible with any client that supports the Model Context Protocol standard, including Claude Desktop and other MCP-compatible coding assistants. It integrates specifically with Moderne's Prethink and Trigrep agent tools.
Do I need an API key or Moderne license to use this MCP server?+
The OpenRewrite framework is open source under Apache 2.0 for many languages and recipes. Some advanced features and additional language parsers use the Moderne Source Available License, which is free for your own code. Proprietary recipes require a Moderne commercial license.
What programming languages does the OpenRewrite MCP server support?+
The MCP server provides refactoring capabilities for Java, Kotlin, Groovy, JavaScript, TypeScript, Python, and C#. Language support and recipe availability vary based on the OpenRewrite and Moderne licensing tiers.
Is the OpenRewrite MCP server free to use?+
The core OpenRewrite framework is free and open source. The MCP server is part of Moderne's tooling, with free tiers for individual use and open source projects, while enterprise features require a commercial license.
How do I install rewrite?+
Open the source repository on GitHub and follow its README. rewrite is a mcp server — MCP Agents Market links you directly to the official repo.
Is rewrite free?+
rewrite is an open-source project hosted on GitHub. Check the repository for its license and any usage requirements.