Public/Set-Alert.ps1

<#
    .DESCRIPTION
    Wrapper for Nutanix API version 0.3.
 
    .NOTES
    Author: Timothy Rasiah
#>


function Set-Alert {
    [CmdletBinding()]
    param (
        $uuid,
        [ValidateSet("ACKNOWLEDGE", "RESOLVE")]
        $action
    )
    
    $data = @{
        "alert_uuid_list" = @(
            $uuid
        )
    }

    $response = Send-Request -method "POST" -endpoint "/alerts/action/$($action)" -data $data
    return $response
}