beta/src/PSSailpoint.Beta/Model/SourceCreationErrors.ps1
# # Identity Security Cloud Beta API # Use these APIs to interact with the Identity Security Cloud platform to achieve repeatable, automated processes with greater scalability. These APIs are in beta and are subject to change. 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: 3.1.0-beta # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION No description available. .PARAMETER SourceName Source's human-readable name. .PARAMETER SourceError Source's human-readable description. .PARAMETER Created Date-time when the source was created .PARAMETER Modified Date-time when the source was last modified. .PARAMETER Operation operation category (e.g. DELETE). .OUTPUTS SourceCreationErrors<PSCustomObject> #> function Initialize-BetaSourceCreationErrors { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${SourceName}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${SourceError}, [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[System.DateTime]] ${Created}, [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[System.DateTime]] ${Modified}, [Parameter(ValueFromPipelineByPropertyName = $true)] [String] ${Operation} ) Process { 'Creating PSCustomObject: PSSailpoint.Beta => BetaSourceCreationErrors' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "source_name" = ${SourceName} "source_error" = ${SourceError} "created" = ${Created} "modified" = ${Modified} "operation" = ${Operation} } return $PSO } } <# .SYNOPSIS Convert from JSON to SourceCreationErrors<PSCustomObject> .DESCRIPTION Convert from JSON to SourceCreationErrors<PSCustomObject> .PARAMETER Json Json object .OUTPUTS SourceCreationErrors<PSCustomObject> #> function ConvertFrom-BetaJsonToSourceCreationErrors { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.Beta => BetaSourceCreationErrors' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in BetaSourceCreationErrors $AllProperties = ("multihost_id", "source_name", "source_error", "created", "modified", "operation") 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 "multihost_id"))) { #optional property not found $MultihostId = $null } else { $MultihostId = $JsonParameters.PSobject.Properties["multihost_id"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "source_name"))) { #optional property not found $SourceName = $null } else { $SourceName = $JsonParameters.PSobject.Properties["source_name"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "source_error"))) { #optional property not found $SourceError = $null } else { $SourceError = $JsonParameters.PSobject.Properties["source_error"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "created"))) { #optional property not found $Created = $null } else { $Created = $JsonParameters.PSobject.Properties["created"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "modified"))) { #optional property not found $Modified = $null } else { $Modified = $JsonParameters.PSobject.Properties["modified"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "operation"))) { #optional property not found $Operation = $null } else { $Operation = $JsonParameters.PSobject.Properties["operation"].value } $PSO = [PSCustomObject]@{ "multihost_id" = ${MultihostId} "source_name" = ${SourceName} "source_error" = ${SourceError} "created" = ${Created} "modified" = ${Modified} "operation" = ${Operation} } return $PSO } } |