About pzalutski-pixel/sharplens-mcp
pzalutski-pixel/sharplens-mcp is an MCP server published by pzalutski-pixel in the Data category: roslyn-powered MCP server for AI-driven C# semantic analysis, refactoring, and code generation. Conduid read 92 tools from its source: add_missing_imports, add_null_checks, analyze_change_impact, analyze_control_flow, analyze_data_flow, analyze_method and 86 more. No package is published for it, so it installs from a source checkout.
The repository has 41 stars and 8 forks, is licensed MIT, and its last commit was on 17 Oct 2026. The latest release is v1.6.4 (17 Oct 2026): Patch release — cross-project test coverage, find_tests speed and test detection, plus fixes across every tool so its answers and edits can be trusted. It follows v1.6.3 (16 Aug 2026), and the 5 most recent releases go back to v1.6.0 (3 Jul 2026). It passes 3 of the 6 static checks Conduid ran on the repository; it does not pass Dependencies pinned, No dynamic code execution and Scoped permissions. Its topics include code-analysis, devtools, semantic-analysis and roslyn.
Install
git clone https://github.com/pzalutski-pixel/sharplens-mcpTools (92)
add_missing_importsCompute the usings that fix CS0246/CS0103 (generation-only)add_null_checksGenerate ArgumentNullException guardsanalyze_change_impactWhat breaks if changed?analyze_control_flowBranching/reachabilityanalyze_data_flowVariable assignments and usageanalyze_methodSignature + callers + outgoing calls + locationapply_code_action_by_titleApply any refactoring by titleapply_code_fixApply a specific code fixchange_signatureAdd/remove/reorder parameterscheck_architectureEnforce namespace/project dependency rules over the type graphcheck_type_compatibilityCan A assign to B?dependency_graphProject dependenciesdiff_api_surfacePublic-API breaking-change report vs a git refencapsulate_fieldField to propertyextract_interfaceGenerate interface from classextract_methodExtract with data flow analysisextract_variableExtract expression to variablefind_async_issuesasync void / blocking-on-async / unforwarded CancellationTokenfind_attribute_usagesFind types/members by attributefind_callersImpact analysis - who calls this?find_catch_blocksWhere an exception type is caught (optionally via a base clause)find_circular_dependenciesProject and namespace cycle detectionfind_dead_branchesUnreachable basic blocks per method (real CFG, not heuristics)find_god_objectsDetect over-coupled types via efferent + afferent coupling + member-count thresholdsfind_implementationsInterface/abstract implementationsfind_interceptorsSurface [InterceptsLocation] call rerouting, generated code includedfind_naming_violationsNaming audit honoring .editorconfig rules, with conventional defaultsfind_path_betweenReachability + the connecting call path(s) between two methods; follows dispatch, with barriers and a checkpointfind_pattern_usagesWhere a type appears in is/as/pattern matchesfind_referencesAll references; each classified read/write/invocation/cast/typeof/nameof/attribute; optional `kind` filterfind_reflection_usageDetect reflection/dynamic usagefind_similar_codeStructural similarity search (token-shingle fingerprints)find_testsWhich tests cover a symbol — the inverse of find_untested_codefind_throw_sitesWhere an exception type is thrown (optionally derived)find_type_instantiationsWhere a type is constructed (`new T`)find_untested_codeFind public surface no test reaches — tests detected as xUnit, NUnit, MSTest, TUnit, Reqnroll and SpecFlow discover them, with setup, fixtures and step bindingsfind_unused_codeDead code detectionfind_unused_dependenciesPackageReferences/ProjectReferences the compiler never needsfix_allCompute the fix for every instance of a diagnostic id (generation-only)format_document_batchBatch format files in projectgenerate_constructorFrom fields/propertiesgenerate_equality_membersEquals/GetHashCode/operatorsgenerate_test_stubCompilable test skeleton for a method (framework auto-detected)get_attributesList attributes on a symbolget_base_typesFull inheritance chainget_call_graphMulti-hop callers/callees graph with depth bound + cycle detectionget_code_actions_at_positionAll Roslyn refactorings at positionget_code_fixesAvailable fixes for a diagnosticget_complexity_metricsCyclomatic, nesting, LOC, cognitiveget_containing_memberEnclosing symbol at positionget_derived_typesFind all subclassesget_di_registrationsScan DI service registrationsget_diagnosticsCompiler errors/warnings + configured analyzer findings (StyleCop, Roslynator, NetAnalyzers); matches CIget_documentationFull XML docs for a symbol with `<inheritdoc>` expandedget_exception_flowWhich exceptions can escape a method, and where they're caughtget_extension_methodsExtensions applying to a type — classic and C# 14 blocksget_external_type_infoInspect NuGet/BCL/external assembly types — members + XML docsget_file_overviewFile summary with diagnosticsget_generated_codeView generated source codeget_instantiation_optionsHow to create a typeget_method_overloadsAll overloads of a methodget_method_signatureDetailed signature by nameget_method_sourceSource code by nameget_method_source_batchMultiple method sources in one callget_missing_membersUnimplemented interface/abstract membersget_nuget_dependenciesNuGet package listing per projectget_outgoing_callsWhat does this method call?get_project_healthComposite audit dashboard: diagnostics + unused + coupling + coverage per projectget_project_structureSolution structureget_source_generatorsList active source generatorsget_super_methodNavigate to the base member / interface members a member implementsget_symbol_infoSemantic info at positionget_type_hierarchyInheritance chainget_type_membersAll members by type nameget_type_members_batchMultiple types in one callget_type_overviewFull type info in one callgo_to_definitionJump to symbol definitionhealth_checkServer status + load fidelity (`partial` flag, declared-vs-loaded projects, `loadFailures`, `loadWarnings`, `lastLoadFailure`) — check without reloadingimplement_missing_membersGenerate interface stubsinline_variableInline temp variableload_solutionLoad .sln/.slnx/.slnf; reports partial loads (`partial` + `loadFailures`: dropped projects, failed restores, projects loaded without references) and MSBuild warnings (`loadWarnings`) separatelymove_type_to_fileCompute the contents to move a type into its own file (generation-only)organize_usingsSort and remove unusedorganize_usings_batchBatch organize multiple filesremove_unused_codeCompute dead-code removals + newly unused usings (generation-only)rename_symbolSafe rename across solutionresolve_stack_traceMap a pasted stack trace to file/line/symbol, mangling undonesearch_symbolsGlob pattern search (`*Handler`, `Get*`)semantic_queryMulti-filter search (async, public, etc.)split_typeCompute a partial-class split for selected members (generation-only)sync_documentsSync file changes into loaded solutionvalidate_codeCompile check without writingSecurity checks
Static checks derived from the repository 10 days ago. Heuristics on the source, not an audit.
- ✓README presentThe repository's README runs to about 2.8K words.
- ✓License declaredThe repository declares the MIT license.
- ✓Tests presentA test suite exists in the repository.
- !Dependencies pinnedNo lockfile anywhere in the repository. Installs can pull different code over time.
- !No dynamic code executionScanned 180 source files and found 4 calls to eval or shell execution, in npm/bin/sharplens-mcp.js:8, npm/bin/sharplens-mcp.js:20 and npm/bin/sharplens-mcp.js:38 among others. Review how tool inputs reach them before granting credentials.
- !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.
What the source scan found
- Transport
- None found in the source
- Starts other programs
- 6 callsnpm/bin/sharplens-mcp.js:8, npm/bin/sharplens-mcp.js:20, npm/bin/sharplens-mcp.js:38
- Outbound network calls
- No outbound network calls
- Writes or deletes files
- 3 callssrc/SourceFileIO.cs:34, src/SourceFileIO.cs:35, src/SourceFileWorkspace.cs:90
- Lockfile
- None in the repository
Pattern matches on the source text of 180 files: places to read, not proof of what the code does at run time.
Releases
README
The repository's README runs to about 2.8K words, fetched a month ago. The original in the repository is authoritative.
Read full README