v2025/src/PSSailpoint.V2025/Model/ApprovalIdentity.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 Approval Identity Object .PARAMETER Email Email address. .PARAMETER IdentityID Identity ID. .PARAMETER Members List of members of a governance group. Will be omitted if the identity is not a governance group. .PARAMETER Name Name of the identity. .PARAMETER OwnerOf List of owned items. For example, will show the items in which a ROLE_OWNER owns. Omitted if not an owner of anything. .PARAMETER SerialOrder The serial step of the identity in the approval. For example serialOrder 1 is the first identity to action in an approval request chain. Parallel approvals are set to 0. .PARAMETER Type Type of identity. .OUTPUTS ApprovalIdentity<PSCustomObject> #> function Initialize-V2025ApprovalIdentity { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${Email}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${IdentityID}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject[]] ${Members}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${Name}, [Parameter(ValueFromPipelineByPropertyName = $true)] [PSCustomObject[]] ${OwnerOf}, [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[Int64]] ${SerialOrder}, [Parameter(ValueFromPipelineByPropertyName = $true)] [ValidateSet("IDENTITY", "MANAGER_OF", "GOVERNANCE_GROUP", "SOURCE_OWNER", "ROLE_OWNER", "ACCESS_PROFILE_OWNER", "ENTITLEMENT_OWNER", "APPLICATION_OWNER")] [String] ${Type} ) Process { 'Creating PSCustomObject: PSSailpoint.V2025 => V2025ApprovalIdentity' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "email" = ${Email} "identityID" = ${IdentityID} "members" = ${Members} "name" = ${Name} "ownerOf" = ${OwnerOf} "serialOrder" = ${SerialOrder} "type" = ${Type} } return $PSO } } <# .SYNOPSIS Convert from JSON to ApprovalIdentity<PSCustomObject> .DESCRIPTION Convert from JSON to ApprovalIdentity<PSCustomObject> .PARAMETER Json Json object .OUTPUTS ApprovalIdentity<PSCustomObject> #> function ConvertFrom-V2025JsonToApprovalIdentity { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.V2025 => V2025ApprovalIdentity' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in V2025ApprovalIdentity $AllProperties = ("email", "identityID", "members", "name", "ownerOf", "serialOrder", "type") 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 "email"))) { #optional property not found $Email = $null } else { $Email = $JsonParameters.PSobject.Properties["email"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "identityID"))) { #optional property not found $IdentityID = $null } else { $IdentityID = $JsonParameters.PSobject.Properties["identityID"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "members"))) { #optional property not found $Members = $null } else { $Members = $JsonParameters.PSobject.Properties["members"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "name"))) { #optional property not found $Name = $null } else { $Name = $JsonParameters.PSobject.Properties["name"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "ownerOf"))) { #optional property not found $OwnerOf = $null } else { $OwnerOf = $JsonParameters.PSobject.Properties["ownerOf"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "serialOrder"))) { #optional property not found $SerialOrder = $null } else { $SerialOrder = $JsonParameters.PSobject.Properties["serialOrder"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "type"))) { #optional property not found $Type = $null } else { $Type = $JsonParameters.PSobject.Properties["type"].value } $PSO = [PSCustomObject]@{ "email" = ${Email} "identityID" = ${IdentityID} "members" = ${Members} "name" = ${Name} "ownerOf" = ${OwnerOf} "serialOrder" = ${SerialOrder} "type" = ${Type} } return $PSO } } |