A local MCP server for Roslyn-powered C# code analysis and safe, transactional refactoring.
- ✓Open-source license (MIT)
- ✓Actively maintained (<30d)
- ✓Clear description
- ✓Topics declared
- ✓Documented (README)
git clone https://github.com/lantean-code/roslyn-workbench-mcpMCP Servers overview
# Roslyn Workbench MCP
<!-- mcp-name: io.github.lantean-code/roslyn-workbench-mcp -->

Roslyn Workbench is a local stdio MCP server for Roslyn-powered C# code analysis and safe, transactional refactoring.
It provides persistent multi-workspace sessions, semantic queries for symbols and code structure, bounded agent-facing results, and source changes staged through transactions with preview, history, rollback, conflict detection and crash recovery. Code Actions use the same transaction boundary. Nothing writes source files until an explicit `transaction-commit` call.
## Install
Roslyn Workbench is distributed through [NuGet.org](https://www.nuget.org/packages/Lantean.Roslyn.Workbench.Mcp) as the `Lantean.Roslyn.Workbench.Mcp` .NET tool and requires a supported .NET 10 SDK. Pin the exact release version you intend to run. The [compatibility policy](https://lantean-code.github.io/roslyn-workbench-mcp/latest/compatibility.html) defines the stable 1.x guarantees for tools, errors and continuations, recovery formats and plugin APIs.
Run an exact package version without a permanent installation:
```bash
dnx Lantean.Roslyn.Workbench.Mcp@VERSION --yes -- --version
```
Alternatively, install the same package as a global tool with `dotnet tool install --global Lantean.Roslyn.Workbench.Mcp --version VERSION`.
See the [documentation site](https://lantean-code.github.io/roslyn-workbench-mcp/) for installation and MCP client configuration.
Configure any MCP client capable of launching a local stdio process to run:
```json
{
"command": "roslyn-workbench-mcp",
"args": [
"--operational-mode", "inspection-only",
"--state-directory", "/absolute/path/to/roslyn-workbench-state"
]
}
```
`inspection-only` is the safe default and exposes no source-mutation or transaction tools. Select `transactional` for client-mediated commit confirmation, `approval-required` for confirmation bound to an exact transaction-review receipt, or deliberately select `autonomous-trusted` for transactions without Host confirmation. See the configuration guide for client elicitation requirements.
## Supported environments
Windows x64, Linux x64 and WSL2 x64 are supported. macOS x64 and ARM64 are best effort until hosted validation exists. Windows ARM64 and Linux ARM64 are not currently supported release targets. The server can be used by any MCP client that supports local stdio servers; operations requiring elicitation depend on the client advertising and permitting it.
## Improve agent tool selection
Connecting Roslyn Workbench makes its tools available, but an MCP client may not select them automatically when ordinary file and text-search tools can also attempt the task. Short repository instructions can tell an agent when compiler-aware tooling is the better choice without forcing it into every C# workflow.
Add this basic instruction to the user-level guidance used by your agent, or to repository guidance when it should apply only to a particular codebase:
```markdown
## Roslyn Workbench
When Roslyn Workbench MCP is available, consider using it for C# work that benefits from compiler semantics, including precise symbol navigation, references, diagnostics, code structure, Code Actions, change-impact analysis and transactional source changes. Its semantic tools are particularly useful when symbol identity or compiler interpretation matters, while the repository's normal tools and commands remain suitable for builds, tests, package management, documentation and non-semantic file operations. Transaction previews and structured next actions can help keep source changes safe and easy to review.
```
The [documentation site](https://lantean-code.github.io/roslyn-workbench-mcp/) explains user-level and repository-level setup for Codex, GitHub Copilot, Claude Code and other MCP clients. User-level guidance avoids repeating the instruction when Roslyn Workbench is available across repositories, while repository guidance can provide a more specific layer for an individual codebase.
## Trust and transaction safety
Open only workspaces you trust. Loading a workspace evaluates MSBuild project logic and later operations can load project analyzers with the Host process's operating-system permissions. External plugin loading is disabled by default; supplying `--enable-plugins` explicitly opts into loading configured third-party plugins as trusted in-process code, which is not sandboxed.
A typical safe workflow when `transactional` or `autonomous-trusted` mode is configured is:
1. Inspect `server-status` and open a trusted solution, solution filter or project with `workspace-open`.
2. Use query tools to inspect the loaded workspace.
3. Check `workspace-status`, then begin a transaction with `transaction-start`.
4. Stage a mutation or Code Action and inspect it with `transaction-preview`.
5. Commit the reviewed transaction or discard it with `transaction-rollback`.
The live MCP `tools/list` response is authoritative for the tools and schemas exposed by a running instance. The [documentation site](https://lantean-code.github.io/roslyn-workbench-mcp/) provides the richer versioned tool reference and agent guide.
## Plugins and contributions
Plugin authors reference the separate `Lantean.Roslyn.Workbench.Mcp.Plugins` package. See the [plugin-authoring guide](https://lantean-code.github.io/roslyn-workbench-mcp/latest/plugin-authoring.html) for the supported API and deployment layout. Users install trusted plugins manually; there is no curated plugin repository.
External pull requests are accepted. Discuss the scope first and sign every contributed commit with a cryptographic signature that GitHub can verify. See the [contribution policy](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/CONTRIBUTING.md) for the process.
## Support and project links
- [Support and feedback routes](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/SUPPORT.md)
- [Security reporting](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/SECURITY.md)
- [Contribution policy](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/CONTRIBUTING.md)
- [Code of Conduct](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/CODE_OF_CONDUCT.md)
- [Documentation](https://lantean-code.github.io/roslyn-workbench-mcp/)
- [Releases](https://github.com/lantean-code/roslyn-workbench-mcp/releases)
- [NuGet package](https://www.nuget.org/packages/Lantean.Roslyn.Workbench.Mcp)
## Thanks
[](https://github.com/dotnet/roslyn)
Roslyn Workbench MCP is made possible by the [.NET Compiler Platform](https://github.com/dotnet/roslyn). Thank you to the Roslyn team for building and maintaining the compiler tooling that powers its semantic analysis and refactoring capabilities.
[](https://sentry.io/)
Thank you to [Sentry](https://sentry.io/) for supporting the project with an open-source licence for its opt-in error-reporting service.
Roslyn Workbench MCP is licensed under the [MIT License](https://github.com/lantean-code/roslyn-workbench-mcp/blob/develop/LICENSE).
What people ask about roslyn-workbench-mcp
What is lantean-code/roslyn-workbench-mcp?
+
lantean-code/roslyn-workbench-mcp is mcp servers for the Claude AI ecosystem. A local MCP server for Roslyn-powered C# code analysis and safe, transactional refactoring. It has 1 GitHub stars and its last recorded update is dated 2026-10-10.
How do I install roslyn-workbench-mcp?
+
You can install roslyn-workbench-mcp by cloning the repository (https://github.com/lantean-code/roslyn-workbench-mcp) or following the README instructions on GitHub. ClaudeWave also provides quick install blocks on this page.
Is lantean-code/roslyn-workbench-mcp safe to use?
+
Our security agent has analyzed lantean-code/roslyn-workbench-mcp and assigned a Trust Score of 95/100 (tier: Verified). See the full breakdown of passed checks and flags on this page.
Who maintains lantean-code/roslyn-workbench-mcp?
+
lantean-code/roslyn-workbench-mcp is maintained by lantean-code. The last recorded GitHub activity is dated 2026-10-10, with 3 open issues.
Are there alternatives to roslyn-workbench-mcp?
+
Yes. On ClaudeWave you can browse similar mcp servers at /categories/mcp, sorted by popularity or recent activity.
Deploy roslyn-workbench-mcp to your cloud
Ship this repo to production in minutes. Each platform spins up its own environment with editable env vars.
Maintain this repo? Add a badge to your README
Drop the badge into your GitHub README to show it's tracked on ClaudeWave. Each badge links back to this page and reflects the live Trust Score.
[](https://claudewave.com/repo/lantean-code-roslyn-workbench-mcp)<a href="https://claudewave.com/repo/lantean-code-roslyn-workbench-mcp"><img src="https://claudewave.com/api/badge/lantean-code-roslyn-workbench-mcp" alt="Featured on ClaudeWave: lantean-code/roslyn-workbench-mcp" width="320" height="64" /></a>More MCP Servers
Fair-code workflow automation platform with native AI capabilities. Combine visual building with custom code, self-host or cloud, 400+ integrations.
User-friendly AI Interface (Supports Ollama, OpenAI API, ...)
An open-source AI agent that brings the power of Gemini directly into your terminal.
Real-time global intelligence dashboard. AI-powered news aggregation, geopolitical monitoring, and infrastructure tracking in a unified situational awareness interface
🕷️ An adaptive Web Scraping framework that handles everything from a single request to a full-scale crawl! Don't be shy, join here: https://discord.gg/EMgGbDceNQ and follow here for daily tips and tricks: https://x.com/Scrapling_dev
The fastest path to AI-powered full stack observability, even for lean teams.