Skip to content
verify mcp Beta VerifyMCP is currently in beta. If you notice any issues, get in touch and we’ll put it right.

io.github.darylmcd/roslyn-mcp

NUGET · DARYLMCD.ROSLYNMCP

Local-first MCP server for semantic C# analysis & refactoring via Roslyn & MSBuildWorkspace.

−6 this week 80 Trust /100

Last scanned (18 hours ago)

Scores higher than 65% of NuGet servers

Category Developer Tools

Trust breakdown (7 categories)

How this component scores in each security and reliability category. Every signal is checked automatically from public evidence about the published package, including repeated runs of it in an isolated sandbox, and we only credit what we can confirm. How we score → Why this is hard to score →

Supply Chain Security100
  • No malware found by supply-chain analysis.Pass
  • No known CVEs affecting this package version or its production dependencies.Pass
  • No install/post-install scripts declared.Pass
  • No production dependencies, so there is no dependency health to assess. View diagnostics → Pass
Provenance & Transparency48
  • Source repository is publicly reachable at the declared URL. View diagnostics → Pass
  • Build provenance not yet verified. View diagnostics → Unverified
  • Clear OSI-approved license (MIT).Pass
  • Actively maintained (last published 6 days ago).Pass
  • Publishes a security disclosure policy (SECURITY.md).Pass
Schema Quality & AI Usability83
  • 100% of prompts and resources have a non-trivial description (not blank, and not just the item's name).Pass
  • AI-judged instruction clarity (excellent).Pass
  • Context-footprint check failed: tool/resource definitions use about 24236 tokens (~137/item across 176 items; 171 tools + 5 resources), over budget; trim descriptions and params. See how to fix → Fail
  • Usage-examples check failed: none of the tools include examples. See how to fix → Fail
Stability & Change Management60
  • Stability check failed: the tool surface changed between 4.3.0 and 5.0.0: 4 tool removals, 2 breaking changes, 0 additions. See how to fix → Fail
Tool Coverage100
  • 100% of tools have a non-trivial description (not blank, and not just the tool's name).Pass
  • 100% of tool parameters carry a description.Pass
  • Structured output schemas are declared (5% of tools); any adoption earns full credit.Pass
Tool Safety81
  • No prompt-injection markers were found in the server instructions, tool names or descriptions we captured.Pass
  • 2 of 9 tool(s) whose name or description implies an irreversible operation declare an MCP destructiveHint annotation; "delete_file_preview" implies "delete" and declares readOnlyHint instead, contradicting what its own name says it does. See how to fix → Partial
  • An AI judge read all 173 captured unit(s) of tool text and found none that tries to manipulate the model reading it.Pass
Capabilities100
  • Implements a current MCP spec version (2026-07-28).Pass
Changelog

Every change we have recorded for this component, newest first. Security-relevant changes are always shown. ▲ marks a change for the better, ▼ a change for the worse; unmarked changes are neutral.

  • 4 Nov 26 −5

    No change was recorded against any check on this day. Stability & Change Management went from 97 to 60.

  • 29 Oct 26 −1
    • Stability: pass → unverified ▼ security
    • Tool safety: pass → unverified ▼ security
    • Stability: pass → fail ▼ security
    • Capabilities: pass → unverified ▼ functional
    • Tool coverage: 100 → unverified ▼ functional
    • Schema quality: 100 → unverified ▼ functional
    • Package version: 4.4.0 → 5.0.0 functional
  • 28 Oct 26 0
    • Stability: pass → unverified ▼ security
    • Tool safety: pass → unverified ▼ security
    • Capabilities: pass → unverified ▼ functional
    • Tool coverage: 100 → unverified ▼ functional
    • Schema quality: 100 → unverified ▼ functional
    • Package version: 4.3.0 → 4.4.0 functional
  • 25 Oct 26 +1
    • Stability: 0.97 → pass security
  • 24 Oct 26 −1
    • Stability: pass → 0.97 functional
  • 17 Oct 26 +1
    • Stability: 0.93 → pass security
  • 16 Oct 26 +45
    • Injection markers: unverified → pass ▲ security
    • Tool coverage: unverified → 100 ▲ functional
    • Stability: unverified → 0.93 ▲ functional
    • MCP protocol: unverified → pass ▲ functional
    • Schema quality: unverified → 100 ▲ functional
  • 12 Oct 26 −45
    • Tool safety: pass → unverified ▼ security
    • Stability: fail → unverified ▼ security
    • Capabilities: pass → unverified ▼ functional
    • Tool coverage: 100 → unverified ▼ functional
    • Schema quality: 100 → unverified ▼ functional
Diagnostics

Diagnostic detail from the automated scan of this channel: what the scanner observed at each step, so you can see exactly where a check passed or failed. It is informational only and never changes the trust score.

Captured 4 Nov 2026 · Analysed nuget/Darylmcd.RoslynMcp@5.0.0

Provenance Inconclusive

We could not complete the check, so nothing is claimed either way. This is a gap on our side, not a finding about the package.

Result Inconclusive
Ecosystem nuget
Reason Signature present, unverified

Signer

Signed as Repository signature, names nuget.org
Subject CN=NuGet.org Repository by Microsoft,O=NuGet.org Repository by Microsoft,L=Redmond,ST=Washington,C=US
Issuer CN=DigiCert Trusted G4 Code Signing RSA4096 SHA384 2021 CA1,O=DigiCert\, Inc.,C=US
Valid from 23 Feb 2024
Valid until 18 May 2027
Service index https://api.nuget.org/v3/index.json
Owners darylmcd

Background: How many MCP packages publish verified provenance →

Dependencies 0 packages
Packages resolved 0
Tree resolution Complete

Background: SBOMs and build attestations, explained →

Registry declarations For information only

What the registry and the package's own manifest say about this version. The publisher or the registry writes these, nothing here is verified, and none of it affects the score.

Repository https://github.com/darylmcd/Roslyn-Backed-MCP
Repository type git
Commit f8734a2f8a12d5445c7c831696b6f1f5e9fd52d4
Project URL https://github.com/darylmcd/Roslyn-Backed-MCP
MCP tools · 171 exposed · ~23,672 tokens

The tools this component advertises to a client, with an estimated token cost for each. Expand a tool to see its parameters and schema. The per-tool counts are indicative and are not scored directly; the schema's total context footprint is one signal in Schema Quality & AI Usability. A tool's description is untrusted text the model reads on every call, which is what makes this list a security surface and not just an inventory: how tool poisoning works →

Tool Tokens
add_central_package_version_preview ~80

Preview adding a PackageVersion entry to Directory.Packages.props.

NameTypeReqDescription
packageIdstringyesNuGet package id to add to Directory.Packages.props
versionstringyesNuGet package version to set in Directory.Packages.props
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

add_package_reference_preview ~81

Preview adding a PackageReference to a project file.

NameTypeReqDescription
packageIdstringyesNuGet package id to add
projectNamestringyesProject name or project file path within the loaded workspace
versionstringyesNuGet package version to add
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

add_pragma_suppression ~102

Insert #pragma warning disable <id> immediately before the given 1-based line in a source file.

NameTypeReqDescription
diagnosticIdstringyesDiagnostic id (e.g. CS0168)
filePathstringyesAbsolute path to the source file
lineintegeryes1-based line number: pragma is inserted before this line
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

add_project_reference_preview ~71

Preview adding a ProjectReference to a project file.

NameTypeReqDescription
projectNamestringyesProject name or project file path within the loaded workspace
referencedProjectNamestringyesReferenced project name or project file path
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

add_target_framework_preview ~75

Preview adding a target framework to a project file.

NameTypeReqDescription
projectNamestringyesProject name or project file path within the loaded workspace
targetFrameworkstringyesTarget framework moniker to add, for example net8.0
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

analyze_control_flow ~116

Analyze control flow through a code region: entry/exit points, reachability, and return statements. EndPointIsReachable uses Roslyn fall-through semantics, not whether the method can complete.

NameTypeReqDescription
endLineintegeryes1-based end line of the code region to analyze
filePathstringyesAbsolute path to the source file
startLineintegeryes1-based start line of the code region to analyze
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

analyze_data_flow ~111

Analyze how variables flow through a code region: which are read, written, captured by lambdas, always assigned, etc. Use to understand data dependencies before refactoring.

NameTypeReqDescription
endLineintegeryes1-based end line of the code region to analyze
filePathstringyesAbsolute path to the source file
startLineintegeryes1-based start line of the code region to analyze
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

analyze_snippet ~131

Analyze a C# snippet for compilation errors and declared symbols in an ephemeral workspace — no solution load. Use for fragments, diffs, or pasted code; `kind` selects the wrapper.

NameTypeReqDescription
codestringyesThe C# code to analyze
kindstring–The snippet kind: 'expression', 'statements', 'returnExpression', 'members', or 'program' (default)
usingsarray|null–Optional: additional using directives. Pass as a native JSON array, not a JSON-encoded string. Example: ["System.IO", "System.Net.Http"].

No output schema declared.

No examples provided.

apply_code_action ~37

Apply a previously previewed code action using its preview token

NameTypeReqDescription
previewTokenstringyesThe preview token returned by preview_code_action

No output schema declared.

No examples provided.

apply_composite ~37

DESTRUCTIVE — apply an orchestration token.

NameTypeReqDescription
previewTokenstringyesThe preview token returned by an orchestration preview tool

No output schema declared.

No examples provided.

apply_multi_file_edit ~227

Apply text edits to multiple files under one atomic pre-apply snapshot. Prefer preview_multi_file_edit + preview_multi_file_edit_apply for review workflows.

NameTypeReqDescription
autoRevertOnErrorboolean–When true AND verify surfaces new compile errors, automatically revert the entire batch through the single-slot undo path this call populated. Ignored when verify is false. Default false.
fileEditsarrayyesArray of file edits. Each has filePath (string) and edits (array of TextEditDto with startLine, startColumn, endLine, endColumn, newText)
skipSyntaxCheckboolean–When false (default), each C# file is parsed after edits; parser errors block that file's apply.
verifyboolean–When true, run compile_check once after the batch completes (scoped to the single owning project when possible) and attach the result under Verification. Pre-existing errors are filtered out, so only…
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

apply_project_mutation ~43

Apply a previously previewed project file mutation using its preview token.

NameTypeReqDescription
previewTokenstringyesThe preview token returned by one of the project mutation preview tools

No output schema declared.

No examples provided.

apply_text_edit ~294

Apply one or more text edits to a source file in the workspace. Revertible via revert_last_apply. Prefer a semantic preview/apply Roslyn tool whenever one exists; fall back here only when none does.

NameTypeReqDescription
autoRevertOnErrorboolean–When true AND verify surfaces new compile errors, automatically revert the edit through the single-slot undo path this call populated. Single-shot per call - never touches prior-turn edits. Ignored w…
editsarrayyesArray of text edits. Each edit has startLine, startColumn, endLine, endColumn (1-based), and newText. Example: [{"startLine":10,"startColumn":5,"endLine":10,"endColumn":15,"newText":"newValue"}]. All…
filePathstringyesAbsolute path to the file to edit.
skipSyntaxCheckboolean–When false (default), C# files are parsed after edits and lexer/parser errors block the apply. Set true only for intentional intermediate invalid states.
verifyboolean–When true, run compile_check scoped to the owning project after the edit and attach the result under Verification. Pre-existing errors are filtered out, so only NEW errors appear in the outcome.
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

apply_with_verify ~90

Apply a solution-snapshot preview token, run compile_check, and auto-revert compile errors. Producer-specific apply routes enforce token-family checks; excludes composite and project-mutation tokens.

NameTypeReqDescription
previewTokenstringyesThe preview token returned by an *_preview tool
rollbackOnErrorboolean–If true (default) and the apply introduces new compile errors, automatically revert via revert_last_apply.

No output schema declared.

No examples provided.

build_project ~62

Run dotnet build for a specific project in the loaded workspace and return structured diagnostics and execution output

NameTypeReqDescription
projectNamestringyesProject name or project file path within the loaded workspace
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

build_workspace ~40

Run dotnet build for the loaded workspace and return structured diagnostics and execution output

NameTypeReqDescription
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

bulk_replace_type_apply ~59

Apply a token from bulk_replace_type_preview or replace_invocation_preview. This shared route rejects other preview families before mutating the workspace.

NameTypeReqDescription
previewTokenstringyesThe preview token returned by bulk_replace_type_preview or replace_invocation_preview

No output schema declared.

No examples provided.

bulk_replace_type_preview ~118

Preview replacing one type across solution consumers after interface extraction. Choose parameters, fields, or all; parameters also updates generic base/interface arguments.

NameTypeReqDescription
newTypeNamestringyesFully qualified or simple name of the replacement type
oldTypeNamestringyesFully qualified or simple name of the type to replace
scopestring|null–Optional: scope filter — 'parameters', 'fields', or 'all' (default: 'all')
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

callers_callees ~187

Find direct callers and callees for the symbol at an exact position or symbolHandle. Position resolution uses its token, so place the caret on the intended member name.

NameTypeReqDescription
calleesLimitinteger–Maximum number of callees to return (default: 100)
callersLimitinteger–Maximum number of callers to return (default: 100)
columninteger|null–Optional: 1-based column number
filePathstring|null–Optional: absolute path to the source file
lineinteger|null–Optional: 1-based line number
metadataNamestring|null–Optional: fully qualified metadata name, e.g. Namespace.TypeName
symbolHandlestring|null–Optional: stable symbol handle returned by other semantic tools
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

change_signature_preview ~461

Preview method parameter changes or class/struct primary-constructor add/remove with every callsite under one preview token. Struct zero-construction semantics are preserved.

NameTypeReqDescription
columninteger|null–Optional: 1-based column number of the target declaration or parameter
defaultValuestring|null–op='add' only: the default value spliced into every existing callsite (e.g. 'null', 'default', '""', '0').
filePathstring|null–Optional: absolute path to the source file containing the method, constructor, type declaration, or parameter
lineinteger|null–Optional: 1-based line number of the target declaration or parameter
metadataNamestring|null–Optional: bare fully-qualified method or primary-constructor type name without parentheses (e.g. 'Foo.Bar.Baz'). For overloaded methods supply file/line/column to disambiguate, or use symbolHandle fr…
namestring|null–Parameter name. For op='add': the new parameter's name. For op='remove': the existing parameter to drop (or use position). For op='rename': the current name.
newNamestring|null–op='rename' only: the new parameter name.
newOrderstring|null–op='reorder' only: comma-separated permutation of parameter names or 0-based indices (e.g. 'b,a,c' or '1,0,2'). Must list every parameter exactly once.
opstringyesOperation: 'add', 'remove', 'rename', or 'reorder'.
parameterTypestring|null–op='add' only: the parameter type (e.g. 'string', 'IReadOnlyList<int>', 'CancellationToken').
positioninteger|null–Optional position (0-based) of the parameter. For op='add': insertion index (defaults to trailing). For op='remove': index to drop.
symbolHandlestring|null–Optional: stable symbol handle returned by other semantic tools
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

change_type_namespace_preview ~137

Preview relocating a type between namespaces in one project, optionally moving its file and updating consumer using directives. Use get_namespace_dependencies to identify circular dependencies.

NameTypeReqDescription
fromNamespacestringyesFully-qualified namespace currently containing the type
newFilePathstring|null–Optional: absolute destination file path. If omitted, the file stays in place and only its namespace declaration is rewritten
toNamespacestringyesFully-qualified destination namespace inside the same project
typeNamestringyesName of the type to relocate (must be unique within fromNamespace)
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

code_fix_apply ~35

Apply a previously previewed code fix using its preview token

NameTypeReqDescription
previewTokenstringyesPreview token from code_fix_preview.

No output schema declared.

No examples provided.

code_fix_preview ~106

Preview a curated code fix for a specific diagnostic occurrence

NameTypeReqDescription
columnintegeryes1-based column number
diagnosticIdstringyesDiagnostic identifier, e.g. CS8019
filePathstringyesAbsolute path to the source file.
fixIdstring|null–Optional: curated fix identifier from diagnostic_details
lineintegeryes1-based line number
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

compile_check ~304

Fast in-memory compilation check using the Roslyn Compilation API - validates compilability without invoking dotnet build. Reports compiler diagnostics (CS*) only; use project_diagnostics for analyzer (CA*, IDE*) diagnostics. Results are paginated.

NameTypeReqDescription
emitValidationboolean–When true, performs full PE-emit validation (catches more issues like missing references at emit time). Default: false (faster, uses GetDiagnostics only). Requires restored NuGet packages for the per…
filestring|null–Optional: only return diagnostics whose file path matches this absolute path
filesarray|null–Optional: only return diagnostics whose file path matches any absolute path in this list. Pass as a native JSON array of absolute file paths, not a JSON-encoded string. When combined with file, the u…
limitinteger–Maximum number of diagnostics to return (default: 50)
offsetinteger–Number of diagnostics to skip before returning results (default: 0)
projectNamestring|null–Optional: filter by project name
severitystring|null–Optional: minimum severity filter (Error, Warning, Info, Hidden)
workspaceIdstring|null–Optional: the workspace session identifier returned by workspace_load. With one workspace loaded you may omit it — the read-path middleware resolves it automatically; pass it explicitly when two or m…

No output schema declared.

No examples provided.

create_file_apply ~35

Apply a previously previewed file creation using its preview token.

NameTypeReqDescription
previewTokenstringyesPreview token from create_file_preview.

No output schema declared.

No examples provided.

create_file_preview ~87

Preview creating a new source file inside a loaded workspace project. Returns the file diff and a preview token.

NameTypeReqDescription
contentstringyesInitial file contents
filePathstringyesAbsolute path to the file to create.
projectNamestringyesProject name or project file path within the loaded workspace
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

delete_file_apply ~35

Apply a previously previewed file deletion using its preview token.

NameTypeReqDescription
previewTokenstringyesPreview token from delete_file_preview.

No output schema declared.

No examples provided.

delete_file_preview ~58

Preview deleting an existing source file from a loaded workspace. Returns the file diff and a preview token.

NameTypeReqDescription
filePathstringyesAbsolute path to the file to delete.
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

dependency_inversion_preview ~111

Preview extracting an interface and updating constructor dependencies to use it.

NameTypeReqDescription
filePathstringyesAbsolute path to the source file containing the concrete type.
interfaceNamestring|null–Optional: interface name. Defaults to I + type name
interfaceProjectNamestringyesTarget project name or project file path for the extracted interface
typeNamestringyesName of the concrete type to invert dependencies around
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

diagnostic_details ~201

Get details and available code fixes for one diagnostic occurrence. CA-series NetAnalyzers expose fixes through get_code_actions and preview_code_action instead.

NameTypeReqDescription
columninteger|null–1-based column number (alias: startColumn). Supply column or startColumn, or both with the same value.
diagnosticIdstringyesDiagnostic identifier, e.g. CS8019
filePathstringyesAbsolute path to the source file
lineinteger|null–1-based line number (alias: startLine). Supply line or startLine, or both with the same value.
startColumninteger|null–Alias for column, matching the positional-tool convention used by find_references, goto_definition, etc.
startLineinteger|null–Alias for line, matching the positional-tool convention used by find_references, goto_definition, etc.
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

document_symbols ~135

Get a document's declarations as a hierarchical tree. Accepts filePath or a symbol locator, like symbol_info.

NameTypeReqDescription
filePathstring|null–Optional: absolute path to the source file
metadataNamestring|null–Optional: fully qualified metadata name, e.g. Namespace.TypeName
symbolHandlestring|null–Optional: stable symbol handle returned by other semantic tools
workspaceIdstring|null–Optional: the workspace session identifier returned by workspace_load. With one workspace loaded you may omit it — the read-path middleware resolves it automatically; pass it explicitly when two or m…

No output schema declared.

No examples provided.

enclosing_symbol ~89

Find the enclosing symbol (method, property, type) at a given file position — useful for understanding the context of a cursor position

NameTypeReqDescription
columnintegeryes1-based column number
filePathstringyesAbsolute path to the source file
lineintegeryes1-based line number
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

evaluate_csharp ~160

Evaluate a C# expression or multi-line script and return its value and type. Use timeoutSeconds for a per-call budget; progress reports cover long compile and execution work.

NameTypeReqDescription
codestringyesThe C# code to evaluate (expression, statement, or multi-line script)
importsarray|null–Optional: additional namespace imports. Pass as a native JSON array, not a JSON-encoded string. Example: ["System.IO", "System.Net.Http"].
timeoutSecondsinteger|null–Optional: per-call timeout in seconds (UX-002). Overrides ROSLYNMCP_SCRIPT_TIMEOUT_SECONDS for this single invocation. Must be > 0 and fit the server timer range after watchdog grace; null falls back…

No output schema declared.

No examples provided.

evaluate_msbuild_items ~80

List MSBuild items of a given type (e.g. Compile, PackageReference) with evaluated includes and metadata.

NameTypeReqDescription
itemTypestringyesItem type (e.g. Compile, PackageReference)
projectNamestringyesProject name as loaded in the workspace
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

evaluate_msbuild_property ~79

Evaluate a single MSBuild property for a project (e.g. TargetFramework, Nullable) using Microsoft.Build.Evaluation.

NameTypeReqDescription
projectNamestringyesProject name as loaded in the workspace
propertyNamestringyesProperty name (e.g. TargetFramework)
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

extract_and_wire_interface_preview ~135

Preview extracting an interface and optionally rewriting DI registrations to use it.

NameTypeReqDescription
filePathstringyesAbsolute path to the source file containing the concrete type
interfaceNamestring|null–Optional: explicit interface name. Defaults to I + type name
targetProjectNamestringyesTarget project name or project file path for the interface
typeNamestringyesName of the concrete type to extract from
updateDiRegistrationsboolean–Whether to rewrite matching DI registrations to use the extracted interface
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

extract_interface_apply ~33

Apply a previously previewed interface extraction

NameTypeReqDescription
previewTokenstringyesThe preview token returned by extract_interface_preview

No output schema declared.

No examples provided.

extract_interface_cross_project_preview ~120

Preview extracting an interface from a type into a different project. For same-project extraction, use extract_interface_preview instead.

NameTypeReqDescription
filePathstringyesAbsolute path to the source file containing the type.
interfaceNamestring|null–Optional: interface name. Defaults to I + type name
targetProjectNamestring|null–Optional: target project name or project file path
typeNamestringyesName of the type declaration to extract from
workspaceIdstringyesWorkspace session id from workspace_load.

No output schema declared.

No examples provided.

extract_interface_preview ~183

Preview extracting an interface from a concrete type in the same project, with selected members. Optionally replace concrete-type references with the interface.

NameTypeReqDescription
filePathstringyesAbsolute path to the source file containing the type
interfaceNamestringyesName for the new interface (e.g., IMyService)
memberNamesarray|null–Optional: specific member names to include. Pass as a native JSON array, not a JSON-encoded string. Example: ["GetValue", "SetValue"]. If omitted, all public instance members are included.
replaceUsagesboolean–If true, replace parameter and field references to the concrete type with the interface (default: false)
typeNamestringyesName of the concrete type to extract from
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

extract_method_apply ~35

Apply a previously previewed extract method refactoring.

NameTypeReqDescription
previewTokenstringyesThe preview token returned by extract_method_preview

No output schema declared.

No examples provided.

extract_method_preview ~149

Preview extracting selected statements into a new method, inferring parameters and return values by data flow. Selection must cover complete statements in one block, with no return statements.

NameTypeReqDescription
endColumnintegeryes1-based end column of the selection
endLineintegeryes1-based end line of the selection
filePathstringyesAbsolute path to the source file
methodNamestringyesName for the extracted method
startColumnintegeryes1-based start column of the selection
startLineintegeryes1-based start line of the selection
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

extract_shared_expression_to_helper_preview ~241

Preview replacing a shared sub-expression with static-helper calls, unlike extract_method_preview. Refuses on occurrences < 2, mixed free-variable types, or cross-type hits when allowCrossFile=false.

NameTypeReqDescription
allowCrossFileboolean–When true, scans the entire project for structurally-identical matches. When false (default), the scan is restricted to the example expression's containing type.
exampleEndColumnintegeryes1-based end column of the example expression
exampleEndLineintegeryes1-based end line of the example expression
exampleFilePathstringyesAbsolute path to a source file containing one instance of the expression
exampleStartColumnintegeryes1-based start column of the example expression
exampleStartLineintegeryes1-based start line of the example expression
helperAccessibilitystring–Accessibility for the synthesized helper: 'private', 'internal', or 'public'. Defaults to 'private'.
helperNamestringyesName for the synthesized helper method
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

extract_type_apply ~33

Apply a previously previewed type extraction

NameTypeReqDescription
previewTokenstringyesThe preview token returned by extract_type_preview

No output schema declared.

No examples provided.

extract_type_preview ~162

Preview extracting selected members from a type into a new type. The source type gets a private field for the new type and the extracted members are moved. Use this for SRP refactoring.

NameTypeReqDescription
filePathstringyesAbsolute path to the source file containing the type
memberNamesarrayyesNames of members to extract into the new type
newFilePathstring|null–Optional: target file path for the new type. If omitted, defaults to {NewTypeName}.cs in the same directory
newTypeNamestringyesName for the new type
typeNamestringyesName of the source type to extract from
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_base_members ~155

Find the base or implemented members behind an override or implementation. Metadata-boundary bases (e.g. IEquatable<T>.Equals from corlib) surface with FilePath=null so counts match member_hierarchy.

NameTypeReqDescription
columninteger|null–Optional: 1-based column number
filePathstring|null–Optional: absolute path to the source file
lineinteger|null–Optional: 1-based line number
metadataNamestring|null–Optional: fully qualified metadata name, e.g. Namespace.TypeName
symbolHandlestring|null–Optional: stable symbol handle returned by other semantic tools
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_consumers ~277

Find all types that depend on a given type or interface, classified by dependency kind (Constructor, Field, Parameter, BaseType, LocalVariable, Property, ReturnType, GenericArgument, StaticMemberAccess). Optional projectFilter scopes the walk.

NameTypeReqDescription
columninteger|null–Optional: 1-based column number
filePathstring|null–Optional: absolute path to the source file
limitinteger–Maximum number of consumers to return (default: 100). Consumers are ordered by ascending type name; the `totals` block and `hasMore` flag let callers page high-fan-out types.
lineinteger|null–Optional: 1-based line number
metadataNamestring|null–Optional: fully qualified metadata name, e.g. Namespace.IMyInterface
offsetinteger–Number of consumers to skip before returning results (default: 0).
projectFilterstring|null–Optional: case-sensitive Project.Name filter to scope the consumer walk; comma-separated for multiple projects (e.g. 'Foo.Core,Foo.Tests'). Null/empty preserves the unfiltered solution-wide walk.
symbolHandlestring|null–Optional: stable symbol handle returned by other semantic tools
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_dead_fields ~160

Find fields never read, never written, or neither; includePublic=true adds public/protected fields. removalBlockedBy explains refusals; only send safelyRemovable hits to remove_dead_code_preview.

NameTypeReqDescription
includePublicboolean–Include public/protected fields in the scan (default: false).
limitinteger–Maximum number of hits to return (default: 50).
projectNamestring|null–Optional: filter by project name to scope the scan on large solutions.
usageKindstring|null–Optional: restrict results to one usage kind: `never-read`, `never-written`, or `never-either`. Default: all kinds.
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_dead_locals ~106

Find locals written but never read via data-flow analysis (IDE0059). Excludes discards, foreach/using/catch locals, pattern/tuple designations, out var, and consts.

NameTypeReqDescription
limitinteger–Maximum number of hits to return (default: 50).
projectNamestring|null–Optional: filter by project name to scope the scan on large solutions.
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_duplicate_helpers ~149

Find private or internal static helpers that only re-wrap a BCL or NuGet method. Unlike find_duplicated_methods, this detects reinvented framework helpers.

NameTypeReqDescription
excludeFrameworkWrappersboolean–When true (default), omit delegations into common hosting, service-registration, and HTTP extension APIs as framework glue (minimal APIs, DI/CORS setup, logging host hooks, HTTP client helpers, and r…
limitinteger–Maximum number of hits to return (default: 50).
projectNamestring|null–Optional: filter by project name to scope the scan on large solutions.
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

find_duplicated_methods ~285

Find clusters of method bodies with matching AST-normalized structure: internal copy-paste candidates for a shared helper. Bucketing uses body shape, not method name.

NameTypeReqDescription
excludeMcpToolWrappersboolean–When true (default), skip [McpServerTool]-attributed methods whose body is a single delegation, since MCP requires one wrapper shim per tool name.
limitinteger–Maximum number of groups to return (default: 50).
minLinesinteger–Minimum body line count for a method to be considered (default: 10). Lower values produce more false-positive clusters.
projectFilterstring|null–Optional: filter by project name to scope the scan on large solutions.
similarityThresholdnumber–Structural similarity threshold in [0.0, 1.0] (default: 0.85). Exact structural duplicates score 1.0; the current implementation reports only exact-structural matches, so any value <= 1.0 behaves ide…
summaryboolean–When true, omit each group's per-member `Methods` array (file paths + line spans) and return only per-cluster metadata. Smaller payload for large solutions where full member lists exceed the MCP outp…
workspaceIdstringyesThe workspace session identifier returned by workspace_load

No output schema declared.

No examples provided.

Install

How do I install the io.github.darylmcd/roslyn-mcp server?

io.github.darylmcd/roslyn-mcp runs locally as a NuGet package, launched with dnx Darylmcd.RoslynMcp@5.0.0 --yes. Ready-made configuration for Claude, Cursor, VS Code, Codex and 3 more is on this page, copied from each client's own documentation.

nuget · Darylmcd.RoslynMcp

# add to Claude Code
claude mcp add darylmcd-roslyn-mcp -- dnx Darylmcd.RoslynMcp@5.0.0 --yes
Common questions

What is the io.github.darylmcd/roslyn-mcp server?

io.github.darylmcd/roslyn-mcp is listed in the public MCP registry as io.github.darylmcd/roslyn-mcp. Local-first MCP server for semantic C# analysis & refactoring via Roslyn & MSBuildWorkspace. This page covers its NuGet package (Darylmcd.RoslynMcp).

Is the io.github.darylmcd/roslyn-mcp server safe to use?

io.github.darylmcd/roslyn-mcp scores 80 out of 100 on VerifyMCP. We found no known CVEs affecting it as of 4 November 2026. It declares no install or post-install scripts. That is a record of what we were able to check automatically, not an endorsement. The category breakdown on this page shows every signal behind the number, including the ones we could not confirm.

What tools does the io.github.darylmcd/roslyn-mcp server expose?

io.github.darylmcd/roslyn-mcp exposes 171 tools: add_central_package_version_preview, add_package_reference_preview, add_pragma_suppression, add_project_reference_preview, add_target_framework_preview, and 166 more. Their descriptions and schemas cost roughly 23,672 tokens of context every time the server is loaded.

Is the io.github.darylmcd/roslyn-mcp server still maintained?

io.github.darylmcd/roslyn-mcp is still listed as active in the MCP registry. We last reached this channel on 4 November 2026. Those dates come from our own scans of the registry and the channel itself, not from anything the publisher announced.

What licence is the io.github.darylmcd/roslyn-mcp server under?

io.github.darylmcd/roslyn-mcp declares the MIT licence, which is OSI-approved. That covers the source only, and says nothing about the cost of any service it calls.