Update Privileged Account Credential ​
PUT /api/privaccount
Updating an existing Privileged Account Credential entry can be achieved by making a PUT request on the URL, with appropriate fields forming the HTTP message body. You must use the Privileged Account Credential API Key.
API Key can be specified in the Header, or the Body of the PUT.
Powershell
#JSON data for the object
$Body = @{
PrivilegedAccountID = "3"
Password = "NewPas$Fraze2134"
}
$jsonData = $Body | ConvertTo-Json
$PasswordstateURL = 'https://passwordstate/api'
$result = Invoke-Restmethod -Method Put -Uri $PasswordstateURL'/privaccount' -ContentType "application/json" -Body $jsonData -Header @{ "APIKey" = "<apikey>" }
Write-Output $result