find_package_consolidation_candidates
[external]
Groups PackageReference and packages.config declarations across the loaded workspace to highlight version drift, central package management adoption, and alignment candidates.
Try it locally in the Glider playground
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| packageId | string | No | Optional NuGet package ID filter. |
| projectName | string | No | Optional project name filter. |
| onlyConflicts | boolean | No | Return only packages with multiple declared versions. Default is false. Default: false |
| pathStyle | string | No | Path style: 'absolute' (default) or 'relative' (to solution root). Default: "absolute" |
| packagesSkip | number | No | Package-summary pagination offset. Default is 0. Default: 0 |
| packagesTake | number | No | Package-summary pagination size. Default is 200. Default: 200 |
| maxProjectsPerPackage | number | No | Maximum project declarations to include per package group. Default is 50. Use 0 to include all. Default: 50 |
| responseDetail | string | No | compact returns results and actionable state. full adds diagnostic metadata under responseDiagnostics. Default: "compact" |
Examples
Replace sample paths and symbol keys with values from your workspace.
Inspect version drift for one package
Arguments
{
"packageId": "Newtonsoft.Json",
"onlyConflicts": true
}Full MCP request
Full MCP request
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "find_package_consolidation_candidates",
"arguments": {
"packageId": "Newtonsoft.Json",
"onlyConflicts": true
}
}
}Illustrative response
{
"success": true,
"summary": {
"packageCount": 1,
"conflictCount": 1,
"centrallyManagedPackageCount": 0,
"mixedManagementPackageCount": 0,
"legacyPackageCount": 0
},
"packages": {
"items": [
{
"packageId": "Newtonsoft.Json",
"recommendedVersion": "13.0.3",
"recommendationPolicy": "most-common-declared",
"hasVersionConflict": true,
"declaredVersions": [
{
"version": "12.0.3",
"declarationCount": 1
},
{
"version": "13.0.3",
"declarationCount": 2
}
]
}
]
}
}Inspect all package groups in one project
Arguments
{
"projectName": "MyProject"
}Full MCP request
Full MCP request
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "find_package_consolidation_candidates",
"arguments": {
"projectName": "MyProject"
}
}
}Response Notes
Returns package-group summaries, version declarations, and project-level package management evidence Results use top-level fields with success. Compact is the default; full adds responseDiagnostics. Both modes retain errors, coverage, partial state, and recovery advice.