Get-WtWin32Apps
Get all apps from Intune packaged by WinTuner
Load apps from Tenant and filter based on Update available.\r\n\r\nThis is an authenticated command, so call Connect-WtWinTuner before calling this command.
Syntax
Default parameter set (default)
Get-WtWin32Apps [-Update <Boolean>] [-Superseded <Boolean>] [-Superseding <Boolean>] [-NameContains <String>] [-IsAssigned <Boolean>]
Parameter | Req. | Type | Description |
---|---|---|---|
-Update | ❌ | Boolean | Filter based on UpdateAvailable |
-Superseded | ❌ | Boolean | Filter on if this app is superseded. true means only show apps that are superseded. false means only show apps that are not superseded |
-Superseding | ❌ | Boolean | Filter on if this app is superseding other apps. true means only show apps that are superseding at least 1 app. false means only show apps that are not superseding any app |
-NameContains | ❌ | String | Server-side filter on displayName contains. |
-IsAssigned | ❌ | Boolean | Server-side filter on isAssigned. |
Examples
Get all apps with updates
Get all apps that have updates available
Get-WtWin32Apps -Update $true
Update apps
Get all apps that have be an update available and are not superseeded. This executes the New-WtWingetPackage command. You could run this on a weekly bases.
$updatedApps = Get-WtWin32Apps -Update $true -Superseded $false
foreach($app in $updatedApps) { New-WtWingetPackage -PackageId $($app.PackageId) -PackageFolder $rootPackageFolder -Version $($app.LatestVersion) | Deploy-WtWin32App -GraphId $($app.GraphId) -KeepAssignments }
Remove superseeded apps
Get all apps that have been superseeded and remove them. This executes the Remove-WtWin32App command. You could run this on a weekly bases.
$oldApps = Get-WtWin32Apps -Superseded $true
foreach($app in $oldApps) { Remove-WtWin32App -AppId $app.GraphId }