v2025/src/PSSailpoint.V2025/Model/ApprovalReassignmentHistory.ps1
|
# # Identity Security Cloud V2025 API # Use these APIs to interact with the Identity Security Cloud platform to achieve repeatable, automated processes with greater scalability. We encourage you to join the SailPoint Developer Community forum at https://developer.sailpoint.com/discuss to connect with other developers using our APIs. # Version: v2025 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION ReassignmentHistoryRecord holds a history record of reassignment and escalation actions for an approval request .PARAMETER CommentID Unique identifier for the comment associated with the reassignment. .PARAMETER ReassignedFrom No description available. .PARAMETER ReassignedTo No description available. .PARAMETER Reassigner No description available. .PARAMETER ReassignmentDate Date and time when the reassignment occurred. .PARAMETER ReassignmentType Type of reassignment, such as escalation or manual reassignment. .OUTPUTS ApprovalReassignmentHistory<PSCustomObject> #> function Initialize-V2025ApprovalReassignmentHistory { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${CommentID}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${ReassignedFrom}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${ReassignedTo}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject] ${Reassigner}, [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[System.DateTime]] ${ReassignmentDate}, [Parameter(ValueFromPipelineByPropertyName = $true)] [ValidateSet("ESCALATION", "MANUAL_REASSIGNMENT", "AUTO_REASSIGNMENT")] [String] ${ReassignmentType} ) Process { 'Creating PSCustomObject: PSSailpoint.V2025 => V2025ApprovalReassignmentHistory' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "commentID" = ${CommentID} "reassignedFrom" = ${ReassignedFrom} "reassignedTo" = ${ReassignedTo} "reassigner" = ${Reassigner} "reassignmentDate" = ${ReassignmentDate} "reassignmentType" = ${ReassignmentType} } return $PSO } } <# .SYNOPSIS Convert from JSON to ApprovalReassignmentHistory<PSCustomObject> .DESCRIPTION Convert from JSON to ApprovalReassignmentHistory<PSCustomObject> .PARAMETER Json Json object .OUTPUTS ApprovalReassignmentHistory<PSCustomObject> #> function ConvertFrom-V2025JsonToApprovalReassignmentHistory { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.V2025 => V2025ApprovalReassignmentHistory' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in V2025ApprovalReassignmentHistory $AllProperties = ("commentID", "reassignedFrom", "reassignedTo", "reassigner", "reassignmentDate", "reassignmentType") foreach ($name in $JsonParameters.PsObject.Properties.Name) { if (!($AllProperties.Contains($name))) { throw "Error! JSON key '$name' not found in the properties: $($AllProperties)" } } if (!([bool]($JsonParameters.PSobject.Properties.name -match "commentID"))) { #optional property not found $CommentID = $null } else { $CommentID = $JsonParameters.PSobject.Properties["commentID"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "reassignedFrom"))) { #optional property not found $ReassignedFrom = $null } else { $ReassignedFrom = $JsonParameters.PSobject.Properties["reassignedFrom"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "reassignedTo"))) { #optional property not found $ReassignedTo = $null } else { $ReassignedTo = $JsonParameters.PSobject.Properties["reassignedTo"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "reassigner"))) { #optional property not found $Reassigner = $null } else { $Reassigner = $JsonParameters.PSobject.Properties["reassigner"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "reassignmentDate"))) { #optional property not found $ReassignmentDate = $null } else { $ReassignmentDate = $JsonParameters.PSobject.Properties["reassignmentDate"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "reassignmentType"))) { #optional property not found $ReassignmentType = $null } else { $ReassignmentType = $JsonParameters.PSobject.Properties["reassignmentType"].value } $PSO = [PSCustomObject]@{ "commentID" = ${CommentID} "reassignedFrom" = ${ReassignedFrom} "reassignedTo" = ${ReassignedTo} "reassigner" = ${Reassigner} "reassignmentDate" = ${ReassignmentDate} "reassignmentType" = ${ReassignmentType} } return $PSO } } |