Add Local Security Group ​
POST /userapi/securitygrouplocal
The PowerShell example below creates a Security Group record with various fields specified.
Powershell
# PowerShell Request
#JSON data for the object
$Body = @{
SecurityGroupName = "Windows Team"
Description = "Local Security Group for Windows Team"
}
$jsonData = $Body | ConvertTo-Json
$PasswordstateURL = 'https://passwordstate/userapi'
$result = Invoke-Restmethod -Method Post -Uri $PasswordstateURL'/securitygrouplocal' -ContentType "application/json" -Body $jsonData -Header @{ "UserID" = "<UserID>" ; "APIKey" = "<APIKey>" }
Write-Output $result