API Reference
Command
Get-CxWindowsUpdateUninstallCandidate
Implements the Get-CxWindowsUpdateUninstallCandidate cmdlet.
Examples
Example 1
Get-CxWindowsUpdateUninstallCandidate
Example 2
Get-CxWindowsUpdateUninstallCandidate -Kb KB5039999
Example 3
Get-CxWindowsUpdateUninstallCandidate -ProviderMode Hybrid -WsusProviderServer wsus01.contoso.local -IncludeSecurityCorrelation
Example 4
Get-CxWindowsUpdateUninstallCandidate -MinimumState Warning -OnlyUninstallable -SortByRisk
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.
Syntax
Get-CxWindowsUpdateUninstallCandidate [-ComputerName <string[]>] [-AutoSelectOnWebSites <bool>] [-BrowseOnly <bool>] [-CategoryId <string[]>] [-CustomCriteria <string>] [-DeploymentAction <Unknown>] [-EventLookbackDays <int>] [-HistoryDays <int>] [-HistoryMaxEntries <int>] [-IncludeDownstreamComputerTargets <bool>] [-IncludeSecurityCorrelation] [-InstallationStatus <Installed|NotInstalled>] [-IsAssigned <bool>] [-IsHidden <bool>] [-Kb <string[]>] [-MaxUpdates <int>] [-MinimumState <Informational|Warning|Critical>] [-Online <bool>] [-OnlyUninstallable] [-ProviderMode <Endpoint|Wsus|Hybrid>] [-Query <string>] [-QueryTimeoutSeconds <int>] [-RebootRequired <bool>] [-RevisionNumber <int>] [-SecurityAsOfMonthOffset <int>] [-ServerSelection <Default|ManagedServer|WindowsUpdate|Others>] [-ServiceId <string>] [-ServiceName <string>] [-SkipCorrelation] [-SkipEventTelemetry] [-SkipHistory] [-SortByRisk] [-UpdateId <string[]>] [-UpdateType <Unknown|Software|Driver|ServicePack>] [-WsusProviderPort <int>] [-WsusProviderServer <string>] [-WsusProviderUseSsl] [-WsusQueryTimeoutSeconds <int>] [<CommonParameters>]#Parameters
- ComputerName string[]
- Target computer(s). Use '.' for local computer or provide DNS names.
- AutoSelectOnWebSites bool
- Optional auto-select-on-web-sites filter.
- BrowseOnly bool
- Optional browse-only filter.
- CategoryId string[]
- Optional category identifiers to include.
- CustomCriteria string
- Optional custom WUA criteria appended to the structured query.
- DeploymentAction WindowsUpdateDeploymentAction
- Optional deployment action filter. Possible values: Unknown, None, Installation, Uninstallation, Detection, OptionalInstallation, All
- Possible values:
Unknown,Installation,Uninstallation,Detection,OptionalInstallation,All - EventLookbackDays int
- Event log lookback window in days for optional environment correlation.
- HistoryDays int
- Number of days included in the recent-history slice. Set to 0 to disable the day cutoff.
- HistoryMaxEntries int
- Maximum number of recent-history rows used for candidate enrichment. Set to 0 to disable the cap.
- IncludeDownstreamComputerTargets bool
- When true, include downstream computer targets when querying WSUS.
- IncludeSecurityCorrelation SwitchParameter
- When present, includes MSRC-based security correlation in environment hints.
- InstallationStatus WindowsUpdateInstallationStatus
- Optional installation state filter. When omitted, uninstall candidate discovery defaults to installed updates. Possible values: Installed, NotInstalled
- Possible values:
Installed,NotInstalled - IsAssigned bool
- Optional assigned-state filter.
- IsHidden bool
- Optional hidden-state filter.
- Kb string[]
- Optional KB article identifiers to include.
- MaxUpdates int
- Optional maximum number of returned updates per computer. Set to 0 to disable the cap.
- MinimumState WindowsUpdateUninstallCandidateState
- Optional minimum risk state returned by the reusable candidate query. Possible values: Informational, Warning, Critical
- Possible values:
Informational,Warning,Critical - Online bool
- Optional flag controlling whether the searcher performs an online scan.
- OnlyUninstallable SwitchParameter
- When present, only returns candidates that WUA reports as uninstallable.
- ProviderMode WindowsUpdateProviderMode
- Correlation provider mode used for optional environment hints. Possible values: Endpoint, Wsus, Hybrid
- Possible values:
Endpoint,Wsus,Hybrid - Query string
- Optional raw WUA criteria string. When supplied, structured filters are ignored.
- QueryTimeoutSeconds int
- Per-query timeout in seconds for optional environment correlation.
- RebootRequired bool
- Optional reboot-required filter.
- RevisionNumber int
- Optional revision number filter.
- SecurityAsOfMonthOffset int
- Month offset used for optional MSRC correlation. 0 means current month, 1 means previous month, and so on.
- ServerSelection WindowsUpdateServerSelection
- Optional WUA searcher server selection. Possible values: Default, ManagedServer, WindowsUpdate, Others
- Possible values:
Default,ManagedServer,WindowsUpdate,Others - ServiceId string
- Optional update service identifier used when ServerSelection is Others.
- ServiceName string
- Optional update service display name resolved through the reusable service-discovery layer.
- SkipCorrelation SwitchParameter
- Skips environment correlation enrichment.
- SkipEventTelemetry SwitchParameter
- Disables event log telemetry collection for optional environment correlation.
- SkipHistory SwitchParameter
- Skips recent WUA history enrichment.
- SortByRisk SwitchParameter
- When present, orders candidates by risk and recency instead of preserving WUA discovery order.
- UpdateId string[]
- Optional update identifiers to include.
- UpdateType WindowsUpdateQueryType
- Optional update type filter. Possible values: Unknown, Software, Driver, ServicePack
- Possible values:
Unknown,Software,Driver,ServicePack - WsusProviderPort int
- WSUS provider port used for Wsus or Hybrid environment hints.
- WsusProviderServer string
- Optional WSUS server used for Wsus or Hybrid environment hints.
- WsusProviderUseSsl SwitchParameter
- When true, WSUS provider lookup uses SSL.
- WsusQueryTimeoutSeconds int
- WSUS query timeout in seconds for optional environment correlation.
Outputs
ComputerX.Updates.WindowsUpdateUninstallCandidate