Sharplens MCP logo

Sharplens MCP

Unclaimed

by pzalutski-pixel

Roslyn-powered MCP server for AI-driven C# semantic analysis, refactoring, and code generation

Set up this server

01 / Choose your client

02 / Before you connect

Authentication is not specified. Check the project instructions before connecting.

Install the runtime required by the project and make it available to your client.

Project instructions

Use names from the project instructions, separated by commas. Enter names only, never secret values.

03 / Add the configuration

Source: generated from public install instructions

claude mcp add --transport stdio 'sharplens-mcp' -- 'npx' '-y' 'sharplens-mcp'

Run in your terminal after replacing any placeholders.

04 / Check it in your client

Open your client’s MCP settings and confirm the server connects and lists its tools. A copied configuration does not confirm a working connection.

aiclaude-codecode-analysiscsharpdotnetmcproslynsemantic-analysis

More in AI & ML

Browse the full directory

Unclaimed listing

Is this your MCP server?

This listing was auto-indexed from the public record. Claim it to edit the page, set compatibility and unlock growth tools. Takes under two minutes.

Claim this server

Security profile

Claimed and verified servers get a weekly static scan that shows what the code can reach: external services, environment variables, shell commands, agent configuration folders, plus any dependencies with known advisories. Claim this listing to get one. How the security profile works

40 of 40 tools

Documented tools (40)

From project documentation. A server handshake does not verify each tool’s description or behavior.

add_missing_imports

Compute the usings that fix CS0246/CS0103 (generation-only)

analyze_change_impact

What breaks if changed?

analyze_control_flow

Branching/reachability

analyze_data_flow

Variable assignments and usage

check_type_compatibility

Can A assign to B?

diff_api_surface

Public-API breaking-change report vs a git ref

find_attribute_usages

Find types/members by attribute

find_callers

Impact analysis - who calls this?

find_circular_dependencies

Project and namespace cycle detection

find_dead_branches

Unreachable basic blocks per method (real CFG, not heuristics)

find_implementations

Interface/abstract implementations

find_path_between

Reachability + the connecting call path(s) between two methods; follows dispatch, with barriers and a checkpoint

find_references

All references; each classified read/write/invocation/cast/typeof/nameof/attribute; optional kind filter

find_similar_code

Structural similarity search (token-shingle fingerprints)

find_unused_code

Dead code detection

get_attributes

List attributes on a symbol

get_base_types

Full inheritance chain

get_call_graph

Multi-hop callers/callees graph with depth bound + cycle detection

get_complexity_metrics

Cyclomatic, nesting, LOC, cognitive

get_containing_member

Enclosing symbol at position

get_derived_types

Find all subclasses

get_diagnostics

Compiler errors/warnings + configured analyzer findings (StyleCop, Roslynator, NetAnalyzers); matches CI

get_documentation

Full XML docs for a symbol with <inheritdoc> expanded

get_exception_flow

Which exceptions can escape a method, and where they're caught

get_extension_methods

Extensions applying to a type — classic and C# 14 blocks

get_external_type_info

Inspect NuGet/BCL/external assembly types — members + XML docs

get_method_overloads

All overloads of a method

get_method_signature

Detailed signature by name

get_outgoing_calls

What does this method call?

get_super_method

Navigate to the base member / interface members a member implements

get_symbol_info

Semantic info at position

get_type_hierarchy

Inheritance chain

get_type_members

All members by type name

get_type_members_batch

Multiple types in one call

go_to_definition

Jump to symbol definition

remove_unused_code

Compute dead-code removals + newly unused usings (generation-only)

resolve_stack_trace

Map a pasted stack trace to file/line/symbol, mangling undone

search_symbols

Glob pattern search (Handler, Get)

semantic_query

Multi-filter search (async, public, etc.)

validate_code

Compile check without writing

Tool change history

Compared across complete checks of the same configuration. Tools were listed, not invoked. Input-schema changes are not measured here.

No complete tool checks yet.

FAQ

Questions about Sharplens MCP Server

How do I connect Sharplens MCP Server to Claude?
Run `claude mcp add sharplens-mcp -- npx -y sharplens-mcp` in Claude Code, or add the same command and arguments under mcpServers in Cursor's mcp.json or Claude Desktop's claude_desktop_config.json, then restart the client. The blocks above are ready to paste.
Is Sharplens MCP Server free?
The listed licence is MIT. Check the upstream terms for permitted use and commercial requirements; a public repository does not by itself mean the software is free or open source. Connected APIs and hosted services may have separate charges.
What can Sharplens MCP Server do?
Sharplens MCP Server documents 40 tools to the agent, including add_missing_imports, analyze_change_impact, analyze_control_flow. The descriptions above come from project documentation. A live handshake does not test individual tool behavior.