v2024/src/PSSailpoint.V2024/Model/TemplateSlackAutoApprovalData.ps1
# # Identity Security Cloud V2024 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: v2024 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION No description available. .PARAMETER IsAutoApproved No description available. .PARAMETER ItemId No description available. .PARAMETER ItemType No description available. .PARAMETER AutoApprovalMessageJSON No description available. .PARAMETER AutoApprovalTitle No description available. .OUTPUTS TemplateSlackAutoApprovalData<PSCustomObject> #> function Initialize-V2024TemplateSlackAutoApprovalData { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${IsAutoApproved}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${ItemId}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${ItemType}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${AutoApprovalMessageJSON}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${AutoApprovalTitle} ) Process { 'Creating PSCustomObject: PSSailpoint.V2024 => V2024TemplateSlackAutoApprovalData' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "isAutoApproved" = ${IsAutoApproved} "itemId" = ${ItemId} "itemType" = ${ItemType} "autoApprovalMessageJSON" = ${AutoApprovalMessageJSON} "autoApprovalTitle" = ${AutoApprovalTitle} } return $PSO } } <# .SYNOPSIS Convert from JSON to TemplateSlackAutoApprovalData<PSCustomObject> .DESCRIPTION Convert from JSON to TemplateSlackAutoApprovalData<PSCustomObject> .PARAMETER Json Json object .OUTPUTS TemplateSlackAutoApprovalData<PSCustomObject> #> function ConvertFrom-V2024JsonToTemplateSlackAutoApprovalData { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.V2024 => V2024TemplateSlackAutoApprovalData' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in V2024TemplateSlackAutoApprovalData $AllProperties = ("isAutoApproved", "itemId", "itemType", "autoApprovalMessageJSON", "autoApprovalTitle") 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 "isAutoApproved"))) { #optional property not found $IsAutoApproved = $null } else { $IsAutoApproved = $JsonParameters.PSobject.Properties["isAutoApproved"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "itemId"))) { #optional property not found $ItemId = $null } else { $ItemId = $JsonParameters.PSobject.Properties["itemId"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "itemType"))) { #optional property not found $ItemType = $null } else { $ItemType = $JsonParameters.PSobject.Properties["itemType"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "autoApprovalMessageJSON"))) { #optional property not found $AutoApprovalMessageJSON = $null } else { $AutoApprovalMessageJSON = $JsonParameters.PSobject.Properties["autoApprovalMessageJSON"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "autoApprovalTitle"))) { #optional property not found $AutoApprovalTitle = $null } else { $AutoApprovalTitle = $JsonParameters.PSobject.Properties["autoApprovalTitle"].value } $PSO = [PSCustomObject]@{ "isAutoApproved" = ${IsAutoApproved} "itemId" = ${ItemId} "itemType" = ${ItemType} "autoApprovalMessageJSON" = ${AutoApprovalMessageJSON} "autoApprovalTitle" = ${AutoApprovalTitle} } return $PSO } } |