Software Distribution

免费
EPM
通过 Ivanti | 已更新 לפני שנה | Manage
返回全部教程 (3)

Create an Endpoint Manager Software Distribution Package using PowerShell

Use PowerShell to create a software distribution package and save it so it is available in the EPM console.

$data = @{
 Type = 'GENERIC_EXE'
 Name = 'Powershell Notepad++'
 Description = 'Notepad++ powershell package'
 PrimaryFile = 
'https://{YourEPMServer}/SoftwareDist/NotepadPlusPlus/npp.7.7.1.Installer.exe'
 CommandLine = '/S'
}

$body = $data | ConvertTo-json

$params = @{
ContentType = 'application/json'
Headers = @{'authorization' = 'Bearer ' + {YourEPMAccessToken} }
Method = 'Post'
 Body = $body
 Uri = 'https://{YourEPMServer}/distributionapi/api/v1/Package'
}

$response = Invoke-RestMethod @params