Public/adc-functions-conf-network.ps1

function Invoke-ADCUpdateAppalgparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for AppAlg Param resource.
    .PARAMETER Pptpgreidletimeout
        Interval in sec, after which data sessions of PPTP GRE is cleared.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateAppalgparam
        An example how to update appalgparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateAppalgparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/appalgparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 9000)]
        [double]$Pptpgreidletimeout 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateAppalgparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('pptpgreidletimeout') ) { $payload.Add('pptpgreidletimeout', $pptpgreidletimeout) }
            if ( $PSCmdlet.ShouldProcess("appalgparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type appalgparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateAppalgparam: Finished"
    }
}

function Invoke-ADCUnsetAppalgparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for AppAlg Param resource.
    .PARAMETER Pptpgreidletimeout
        Interval in sec, after which data sessions of PPTP GRE is cleared.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetAppalgparam
        An example how to unset appalgparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetAppalgparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/appalgparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$pptpgreidletimeout 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetAppalgparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('pptpgreidletimeout') ) { $payload.Add('pptpgreidletimeout', $pptpgreidletimeout) }
            if ( $PSCmdlet.ShouldProcess("appalgparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type appalgparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetAppalgparam: Finished"
    }
}

function Invoke-ADCGetAppalgparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for AppAlg Param resource.
    .PARAMETER GetAll
        Retrieve all appalgparam object(s).
    .PARAMETER Count
        If specified, the count of the appalgparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetAppalgparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetAppalgparam -GetAll
        Get all appalgparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetAppalgparam -name <string>
        Get appalgparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetAppalgparam -Filter @{ 'name'='<value>' }
        Get appalgparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetAppalgparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/appalgparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetAppalgparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all appalgparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type appalgparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for appalgparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type appalgparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving appalgparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type appalgparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving appalgparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving appalgparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type appalgparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetAppalgparam: Ended"
    }
}

function Invoke-ADCAddArp {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for arp resource.
    .PARAMETER Ipaddress
        IP address of the network device that you want to add to the ARP table.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Mac
        MAC address of the network device.
    .PARAMETER Ifnum
        Interface through which the network device is accessible. Specify the interface in (slot/port) notation. For example, 1/3.
    .PARAMETER Vxlan
        ID of the VXLAN on which the IP address of this ARP entry is reachable.
    .PARAMETER Vtep
        IP address of the VXLAN tunnel endpoint (VTEP) through which the IP address of this ARP entry is reachable.
    .PARAMETER Vlan
        The VLAN ID through which packets are to be sent after matching the ARP entry. This is a numeric value.
    .PARAMETER Ownernode
        The owner node for the Arp entry.
    .EXAMPLE
        PS C:\>Invoke-ADCAddArp -ipaddress <string> -mac <string>
        An example how to add arp configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddArp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(Mandatory)]
        [string]$Mac,

        [string]$Ifnum,

        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Vtep,

        [double]$Vlan,

        [ValidateRange(0, 31)]
        [double]$Ownernode 
    )
    begin {
        Write-Verbose "Invoke-ADCAddArp: Starting"
    }
    process {
        try {
            $payload = @{ ipaddress = $ipaddress
                mac                 = $mac
            }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('vtep') ) { $payload.Add('vtep', $vtep) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("arp", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type arp -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddArp: Finished"
    }
}

function Invoke-ADCDeleteArp {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for arp resource.
    .PARAMETER Ipaddress
        IP address of the network device that you want to add to the ARP table.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER All
        Remove all ARP entries from the ARP table of the Citrix ADC.
    .PARAMETER Ownernode
        The owner node for the Arp entry.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteArp -Ipaddress <string>
        An example how to delete arp configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteArp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Ipaddress,

        [double]$Td,

        [boolean]$All,

        [double]$Ownernode 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteArp: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('All') ) { $arguments.Add('all', $All) }
            if ( $PSBoundParameters.ContainsKey('Ownernode') ) { $arguments.Add('ownernode', $Ownernode) }
            if ( $PSCmdlet.ShouldProcess("$ipaddress", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type arp -NitroPath nitro/v1/config -Resource $ipaddress -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteArp: Finished"
    }
}

function Invoke-ADCSendArp {
    <#
    .SYNOPSIS
        Send Network configuration Object.
    .DESCRIPTION
        Configuration for arp resource.
    .PARAMETER Ipaddress
        IP address of the network device that you want to add to the ARP table.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER All
        Remove all ARP entries from the ARP table of the Citrix ADC.
    .EXAMPLE
        PS C:\>Invoke-ADCSendArp
        An example how to send arp configuration Object(s).
    .NOTES
        File Name : Invoke-ADCSendArp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [boolean]$All 

    )
    begin {
        Write-Verbose "Invoke-ADCSendArp: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('all') ) { $payload.Add('all', $all) }
            if ( $PSCmdlet.ShouldProcess($Name, "Send Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type arp -Action send -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCSendArp: Finished"
    }
}

function Invoke-ADCGetArp {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for arp resource.
    .PARAMETER Ipaddress
        IP address of the network device that you want to add to the ARP table.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownernode
        The owner node for the Arp entry.
    .PARAMETER Nodeid
        Unique number that identifies the cluster node.
    .PARAMETER GetAll
        Retrieve all arp object(s).
    .PARAMETER Count
        If specified, the count of the arp object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArp
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArp -GetAll
        Get all arp data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArp -Count
        Get the number of arp objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArp -name <string>
        Get arp object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArp -Filter @{ 'name'='<value>' }
        Get arp data with a filter.
    .NOTES
        File Name : Invoke-ADCGetArp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 31)]
        [double]$Nodeid,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetArp: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all arp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for arp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving arp objects by arguments"
                $arguments = @{ } 
                if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $arguments.Add('ipaddress', $ipaddress) } 
                if ( $PSBoundParameters.ContainsKey('td') ) { $arguments.Add('td', $td) } 
                if ( $PSBoundParameters.ContainsKey('ownernode') ) { $arguments.Add('ownernode', $ownernode) } 
                if ( $PSBoundParameters.ContainsKey('nodeid') ) { $arguments.Add('nodeid', $nodeid) }
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arp -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving arp configuration for property ''"

            } else {
                Write-Verbose "Retrieving arp configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arp -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetArp: Ended"
    }
}

function Invoke-ADCUpdateArpparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Global arp parameters resource.
    .PARAMETER Timeout
        Time-out value (aging time) for the dynamically learned ARP entries, in seconds. The new value applies only to ARP entries that are dynamically learned after the new value is set. Previously existing ARP entries expire after the previously configured aging time.
    .PARAMETER Spoofvalidation
        enable/disable arp spoofing validation.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateArpparam
        An example how to update arpparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateArpparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arpparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(5, 1200)]
        [double]$Timeout,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Spoofvalidation 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateArpparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('timeout') ) { $payload.Add('timeout', $timeout) }
            if ( $PSBoundParameters.ContainsKey('spoofvalidation') ) { $payload.Add('spoofvalidation', $spoofvalidation) }
            if ( $PSCmdlet.ShouldProcess("arpparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type arpparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateArpparam: Finished"
    }
}

function Invoke-ADCUnsetArpparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Global arp parameters resource.
    .PARAMETER Timeout
        Time-out value (aging time) for the dynamically learned ARP entries, in seconds. The new value applies only to ARP entries that are dynamically learned after the new value is set. Previously existing ARP entries expire after the previously configured aging time.
    .PARAMETER Spoofvalidation
        enable/disable arp spoofing validation.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetArpparam
        An example how to unset arpparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetArpparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arpparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$timeout,

        [Boolean]$spoofvalidation 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetArpparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('timeout') ) { $payload.Add('timeout', $timeout) }
            if ( $PSBoundParameters.ContainsKey('spoofvalidation') ) { $payload.Add('spoofvalidation', $spoofvalidation) }
            if ( $PSCmdlet.ShouldProcess("arpparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type arpparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetArpparam: Finished"
    }
}

function Invoke-ADCGetArpparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Global arp parameters resource.
    .PARAMETER GetAll
        Retrieve all arpparam object(s).
    .PARAMETER Count
        If specified, the count of the arpparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArpparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArpparam -GetAll
        Get all arpparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArpparam -name <string>
        Get arpparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetArpparam -Filter @{ 'name'='<value>' }
        Get arpparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetArpparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/arpparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetArpparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all arpparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arpparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for arpparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arpparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving arpparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arpparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving arpparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving arpparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type arpparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetArpparam: Ended"
    }
}

function Invoke-ADCAddBridgegroup {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for bridge group resource.
    .PARAMETER Id
        An integer that uniquely identifies the bridge group.
    .PARAMETER Dynamicrouting
        Enable dynamic routing for this bridgegroup.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on all VLANs bound to this bridgegroup. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created bridgegroup item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddBridgegroup -id <double>
        An example how to add bridgegroup configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddBridgegroup
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddBridgegroup: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSCmdlet.ShouldProcess("bridgegroup", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type bridgegroup -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetBridgegroup -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddBridgegroup: Finished"
    }
}

function Invoke-ADCDeleteBridgegroup {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for bridge group resource.
    .PARAMETER Id
        An integer that uniquely identifies the bridge group.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteBridgegroup -Id <double>
        An example how to delete bridgegroup configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteBridgegroup
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteBridgegroup: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type bridgegroup -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteBridgegroup: Finished"
    }
}

function Invoke-ADCUpdateBridgegroup {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for bridge group resource.
    .PARAMETER Id
        An integer that uniquely identifies the bridge group.
    .PARAMETER Dynamicrouting
        Enable dynamic routing for this bridgegroup.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on all VLANs bound to this bridgegroup. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created bridgegroup item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateBridgegroup -id <double>
        An example how to update bridgegroup configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateBridgegroup
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateBridgegroup: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSCmdlet.ShouldProcess("bridgegroup", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type bridgegroup -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetBridgegroup -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateBridgegroup: Finished"
    }
}

function Invoke-ADCUnsetBridgegroup {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for bridge group resource.
    .PARAMETER Id
        An integer that uniquely identifies the bridge group.
    .PARAMETER Dynamicrouting
        Enable dynamic routing for this bridgegroup.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on all VLANs bound to this bridgegroup. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetBridgegroup -id <double>
        An example how to unset bridgegroup configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetBridgegroup
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 1000)]
        [double]$Id,

        [Boolean]$dynamicrouting,

        [Boolean]$ipv6dynamicrouting 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetBridgegroup: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type bridgegroup -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetBridgegroup: Finished"
    }
}

function Invoke-ADCGetBridgegroup {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for bridge group resource.
    .PARAMETER Id
        An integer that uniquely identifies the bridge group.
    .PARAMETER GetAll
        Retrieve all bridgegroup object(s).
    .PARAMETER Count
        If specified, the count of the bridgegroup object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroup
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroup -GetAll
        Get all bridgegroup data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroup -Count
        Get the number of bridgegroup objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroup -name <string>
        Get bridgegroup object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroup -Filter @{ 'name'='<value>' }
        Get bridgegroup data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgegroup
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgegroup: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all bridgegroup objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgegroup objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgegroup objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgegroup configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving bridgegroup configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgegroup: Ended"
    }
}

function Invoke-ADCGetBridgegroupbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to bridgegroup.
    .PARAMETER Id
        The name of the bridge group.
    .PARAMETER GetAll
        Retrieve all bridgegroup_binding object(s).
    .PARAMETER Count
        If specified, the count of the bridgegroup_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupbinding -GetAll
        Get all bridgegroup_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupbinding -name <string>
        Get bridgegroup_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupbinding -Filter @{ 'name'='<value>' }
        Get bridgegroup_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgegroupbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 1000)]
        [double]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgegroupbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all bridgegroup_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgegroup_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgegroup_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgegroup_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving bridgegroup_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgegroupbinding: Ended"
    }
}

function Invoke-ADCAddBridgegroupnsip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Ipaddress
        The IP address assigned to the bridge group.
    .PARAMETER Netmask
        A subnet mask associated with the network address.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created bridgegroup_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddBridgegroupnsip6binding -id <double>
        An example how to add bridgegroup_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddBridgegroupnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [string]$Ipaddress,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddBridgegroupnsip6binding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("bridgegroup_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type bridgegroup_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetBridgegroupnsip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddBridgegroupnsip6binding: Finished"
    }
}

function Invoke-ADCDeleteBridgegroupnsip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Ipaddress
        The IP address assigned to the bridge group.
    .PARAMETER Netmask
        A subnet mask associated with the network address.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteBridgegroupnsip6binding -Id <double>
        An example how to delete bridgegroup_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteBridgegroupnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteBridgegroupnsip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteBridgegroupnsip6binding: Finished"
    }
}

function Invoke-ADCGetBridgegroupnsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER GetAll
        Retrieve all bridgegroup_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the bridgegroup_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsip6binding -GetAll
        Get all bridgegroup_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsip6binding -Count
        Get the number of bridgegroup_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsip6binding -name <string>
        Get bridgegroup_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsip6binding -Filter @{ 'name'='<value>' }
        Get bridgegroup_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgegroupnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgegroupnsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all bridgegroup_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgegroup_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgegroup_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgegroup_nsip6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving bridgegroup_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgegroupnsip6binding: Ended"
    }
}

function Invoke-ADCAddBridgegroupnsipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Ipaddress
        The IP address assigned to the bridge group.
    .PARAMETER Netmask
        The network mask for the subnet defined for the bridge group.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created bridgegroup_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddBridgegroupnsipbinding -id <double>
        An example how to add bridgegroup_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddBridgegroupnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddBridgegroupnsipbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("bridgegroup_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type bridgegroup_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetBridgegroupnsipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddBridgegroupnsipbinding: Finished"
    }
}

function Invoke-ADCDeleteBridgegroupnsipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Ipaddress
        The IP address assigned to the bridge group.
    .PARAMETER Netmask
        The network mask for the subnet defined for the bridge group.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteBridgegroupnsipbinding -Id <double>
        An example how to delete bridgegroup_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteBridgegroupnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteBridgegroupnsipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteBridgegroupnsipbinding: Finished"
    }
}

function Invoke-ADCGetBridgegroupnsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER GetAll
        Retrieve all bridgegroup_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the bridgegroup_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsipbinding -GetAll
        Get all bridgegroup_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsipbinding -Count
        Get the number of bridgegroup_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsipbinding -name <string>
        Get bridgegroup_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupnsipbinding -Filter @{ 'name'='<value>' }
        Get bridgegroup_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgegroupnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgegroupnsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all bridgegroup_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgegroup_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgegroup_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgegroup_nsip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving bridgegroup_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgegroupnsipbinding: Ended"
    }
}

function Invoke-ADCAddBridgegroupvlanbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the vlan that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Vlan
        Names of all member VLANs.
    .PARAMETER PassThru
        Return details about the created bridgegroup_vlan_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddBridgegroupvlanbinding -id <double>
        An example how to add bridgegroup_vlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddBridgegroupvlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [double]$Vlan,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddBridgegroupvlanbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSCmdlet.ShouldProcess("bridgegroup_vlan_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type bridgegroup_vlan_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetBridgegroupvlanbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddBridgegroupvlanbinding: Finished"
    }
}

function Invoke-ADCDeleteBridgegroupvlanbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the vlan that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER Vlan
        Names of all member VLANs.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteBridgegroupvlanbinding -Id <double>
        An example how to delete bridgegroup_vlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteBridgegroupvlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [double]$Vlan 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteBridgegroupvlanbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Vlan') ) { $arguments.Add('vlan', $Vlan) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteBridgegroupvlanbinding: Finished"
    }
}

function Invoke-ADCGetBridgegroupvlanbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the vlan that can be bound to bridgegroup.
    .PARAMETER Id
        The integer that uniquely identifies the bridge group.
    .PARAMETER GetAll
        Retrieve all bridgegroup_vlan_binding object(s).
    .PARAMETER Count
        If specified, the count of the bridgegroup_vlan_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupvlanbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupvlanbinding -GetAll
        Get all bridgegroup_vlan_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupvlanbinding -Count
        Get the number of bridgegroup_vlan_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupvlanbinding -name <string>
        Get bridgegroup_vlan_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgegroupvlanbinding -Filter @{ 'name'='<value>' }
        Get bridgegroup_vlan_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgegroupvlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgegroup_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 1000)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgegroupvlanbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all bridgegroup_vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgegroup_vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgegroup_vlan_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgegroup_vlan_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving bridgegroup_vlan_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgegroup_vlan_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgegroupvlanbinding: Ended"
    }
}

function Invoke-ADCAddBridgetable {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Mac
        The MAC address of the target.
    .PARAMETER Vxlan
        The VXLAN to which this address is associated.
    .PARAMETER Vtep
        The IP address of the destination VXLAN tunnel endpoint where the Ethernet MAC ADDRESS resides.
    .PARAMETER Vni
        The VXLAN VNI Network Identifier (or VXLAN Segment ID) to use to connect to the remote VXLAN tunnel endpoint. If omitted the value specified as vxlan will be used.
    .PARAMETER Devicevlan
        The vlan on which to send multicast packets when the VXLAN tunnel endpoint is a muticast group address.
    .EXAMPLE
        PS C:\>Invoke-ADCAddBridgetable -mac <string> -vxlan <double> -vtep <string>
        An example how to add bridgetable configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Mac,

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Vtep,

        [ValidateRange(1, 16777215)]
        [double]$Vni,

        [ValidateRange(1, 4094)]
        [double]$Devicevlan 
    )
    begin {
        Write-Verbose "Invoke-ADCAddBridgetable: Starting"
    }
    process {
        try {
            $payload = @{ mac = $mac
                vxlan         = $vxlan
                vtep          = $vtep
            }
            if ( $PSBoundParameters.ContainsKey('vni') ) { $payload.Add('vni', $vni) }
            if ( $PSBoundParameters.ContainsKey('devicevlan') ) { $payload.Add('devicevlan', $devicevlan) }
            if ( $PSCmdlet.ShouldProcess("bridgetable", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type bridgetable -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddBridgetable: Finished"
    }
}

function Invoke-ADCDeleteBridgetable {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Mac
        The MAC address of the target.
    .PARAMETER Vxlan
        The VXLAN to which this address is associated.
    .PARAMETER Vtep
        The IP address of the destination VXLAN tunnel endpoint where the Ethernet MAC ADDRESS resides.
    .PARAMETER Devicevlan
        The vlan on which to send multicast packets when the VXLAN tunnel endpoint is a muticast group address.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteBridgetable
        An example how to delete bridgetable configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Mac,

        [double]$Vxlan,

        [string]$Vtep,

        [double]$Devicevlan 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteBridgetable: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Mac') ) { $arguments.Add('mac', $Mac) }
            if ( $PSBoundParameters.ContainsKey('Vxlan') ) { $arguments.Add('vxlan', $Vxlan) }
            if ( $PSBoundParameters.ContainsKey('Vtep') ) { $arguments.Add('vtep', $Vtep) }
            if ( $PSBoundParameters.ContainsKey('Devicevlan') ) { $arguments.Add('devicevlan', $Devicevlan) }
            if ( $PSCmdlet.ShouldProcess("bridgetable", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type bridgetable -NitroPath nitro/v1/config -Resource $ -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteBridgetable: Finished"
    }
}

function Invoke-ADCUpdateBridgetable {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Bridgeage
        Time-out value for the bridge table entries, in seconds. The new value applies only to the entries that are dynamically learned after the new value is set. Previously existing bridge table entries expire after the previously configured time-out value.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateBridgetable
        An example how to update bridgetable configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(60, 300)]
        [double]$Bridgeage 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateBridgetable: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('bridgeage') ) { $payload.Add('bridgeage', $bridgeage) }
            if ( $PSCmdlet.ShouldProcess("bridgetable", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type bridgetable -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateBridgetable: Finished"
    }
}

function Invoke-ADCUnsetBridgetable {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Bridgeage
        Time-out value for the bridge table entries, in seconds. The new value applies only to the entries that are dynamically learned after the new value is set. Previously existing bridge table entries expire after the previously configured time-out value.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetBridgetable
        An example how to unset bridgetable configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$bridgeage 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetBridgetable: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('bridgeage') ) { $payload.Add('bridgeage', $bridgeage) }
            if ( $PSCmdlet.ShouldProcess("bridgetable", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type bridgetable -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetBridgetable: Finished"
    }
}

function Invoke-ADCClearBridgetable {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Vlan
        VLAN whose entries are to be removed.
    .PARAMETER Ifnum
        INTERFACE whose entries are to be removed.
    .PARAMETER Vxlan
        The VXLAN to which this address is associated.
    .EXAMPLE
        PS C:\>Invoke-ADCClearBridgetable
        An example how to clear bridgetable configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [string]$Ifnum,

        [ValidateRange(1, 16777215)]
        [double]$Vxlan 

    )
    begin {
        Write-Verbose "Invoke-ADCClearBridgetable: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type bridgetable -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearBridgetable: Finished"
    }
}

function Invoke-ADCGetBridgetable {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for bridge table entry resource.
    .PARAMETER Nodeid
        Unique number that identifies the cluster node.
    .PARAMETER GetAll
        Retrieve all bridgetable object(s).
    .PARAMETER Count
        If specified, the count of the bridgetable object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgetable
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgetable -GetAll
        Get all bridgetable data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgetable -Count
        Get the number of bridgetable objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgetable -name <string>
        Get bridgetable object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetBridgetable -Filter @{ 'name'='<value>' }
        Get bridgetable data with a filter.
    .NOTES
        File Name : Invoke-ADCGetBridgetable
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/bridgetable/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 31)]
        [double]$Nodeid,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetBridgetable: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all bridgetable objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgetable -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for bridgetable objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgetable -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving bridgetable objects by arguments"
                $arguments = @{ } 
                if ( $PSBoundParameters.ContainsKey('nodeid') ) { $arguments.Add('nodeid', $nodeid) }
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgetable -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving bridgetable configuration for property ''"

            } else {
                Write-Verbose "Retrieving bridgetable configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type bridgetable -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetBridgetable: Ended"
    }
}

function Invoke-ADCAddChannel {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for channel resource.
    .PARAMETER Id
        ID for the LA channel or cluster LA channel or LR channel to be created. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4. Cannot be changed after the LA channel is created.
    .PARAMETER Ifnum
        Interfaces to be bound to the LA channel of a Citrix ADC or to the LA channel of a cluster configuration.
        For an LA channel of a Citrix ADC, specify an interface in C/U notation (for example, 1/3).
        For an LA channel of a cluster configuration, specify an interface in N/C/U notation (for example, 2/1/3).
        where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        U is a unique integer for representing an interface in a particular port group.
        N is the ID of the node to which an interface belongs in a cluster configuration.
        Use spaces to separate multiple entries.
    .PARAMETER State
        Enable or disable the LA channel.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mode
        The initital mode for the LA channel.
        Possible values = MANUAL, AUTO
    .PARAMETER Conndistr
        The 'connection' distribution mode for the LA channel.
        Possible values = DISABLED, ENABLED
    .PARAMETER Macdistr
        The 'MAC' distribution mode for the LA channel.
        Possible values = SOURCE, DESTINATION, BOTH
    .PARAMETER Lamac
        Specifies a MAC address for the LA channels configured in Citrix ADC virtual appliances (VPX). This MAC address is persistent after each reboot.
        If you don't specify this parameter, a MAC address is generated randomly for each LA channel. These MAC addresses change after each reboot.
    .PARAMETER Speed
        Ethernet speed of the channel, in Mbps. If the speed of any bound interface is greater than or equal to the value set for this parameter, the state of the interface is UP. Otherwise, the state is INACTIVE. Bound Interfaces whose state is INACTIVE do not process any traffic.
        Possible values = AUTO, 10, 100, 1000, 10000, 25000, 40000, 50000, 100000
    .PARAMETER Flowctl
        Specifies the flow control type for this LA channel to manage the flow of frames. Flow control is a function as mentioned in clause 31 of the IEEE 802.3 standard. Flow control allows congested ports to pause traffic from the peer device. Flow control is achieved by sending PAUSE frames.
        Possible values = OFF, RX, TX, RXTX, ON
    .PARAMETER Hamonitor
        In a High Availability (HA) configuration, monitor the LA channel for failure events. Failure of any LA channel that has HA MON enabled triggers HA failover.
        Possible values = ON, OFF
    .PARAMETER Haheartbeat
        In a High Availability (HA) configuration, configure the LA channel for sending heartbeats. LA channel that has HA Heartbeat disabled should not send the heartbeats.
        Possible values = OFF, ON
    .PARAMETER Tagall
        Adds a four-byte 802.1q tag to every packet sent on this channel. The ON setting applies tags for all VLANs that are bound to this channel. OFF applies the tag for all VLANs other than the native VLAN.
        Possible values = ON, OFF
    .PARAMETER Trunk
        This is deprecated by tagall.
        Possible values = ON, OFF
    .PARAMETER Ifalias
        Alias name for the LA channel. Used only to enhance readability. To perform any operations, you have to specify the LA channel ID.
    .PARAMETER Throughput
        Low threshold value for the throughput of the LA channel, in Mbps. In an high availability (HA) configuration, failover is triggered when the LA channel has HA MON enabled and the throughput is below the specified threshold.
    .PARAMETER Bandwidthhigh
        High threshold value for the bandwidth usage of the LA channel, in Mbps. The Citrix ADC generates an SNMP trap message when the bandwidth usage of the LA channel is greater than or equal to the specified high threshold value.
    .PARAMETER Bandwidthnormal
        Normal threshold value for the bandwidth usage of the LA channel, in Mbps. When the bandwidth usage of the LA channel returns to less than or equal to the specified normal threshold after exceeding the high threshold, the Citrix ADC generates an SNMP trap message to indicate that the bandwidth usage has returned to normal.
    .PARAMETER PassThru
        Return details about the created channel item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddChannel -id <string>
        An example how to add channel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddChannel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [string[]]$Ifnum,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$State = 'ENABLED',

        [ValidateSet('MANUAL', 'AUTO')]
        [string]$Mode,

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Conndistr,

        [ValidateSet('SOURCE', 'DESTINATION', 'BOTH')]
        [string]$Macdistr,

        [string]$Lamac,

        [ValidateSet('AUTO', '10', '100', '1000', '10000', '25000', '40000', '50000', '100000')]
        [string]$Speed = 'AUTO',

        [ValidateSet('OFF', 'RX', 'TX', 'RXTX', 'ON')]
        [string]$Flowctl = 'OFF',

        [ValidateSet('ON', 'OFF')]
        [string]$Hamonitor = 'ON',

        [ValidateSet('OFF', 'ON')]
        [string]$Haheartbeat = 'ON',

        [ValidateSet('ON', 'OFF')]
        [string]$Tagall = 'OFF',

        [ValidateSet('ON', 'OFF')]
        [string]$Trunk = 'OFF',

        [string]$Ifalias = '" "',

        [ValidateRange(0, 160000)]
        [double]$Throughput,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthhigh,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthnormal,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddChannel: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('state') ) { $payload.Add('state', $state) }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSBoundParameters.ContainsKey('conndistr') ) { $payload.Add('conndistr', $conndistr) }
            if ( $PSBoundParameters.ContainsKey('macdistr') ) { $payload.Add('macdistr', $macdistr) }
            if ( $PSBoundParameters.ContainsKey('lamac') ) { $payload.Add('lamac', $lamac) }
            if ( $PSBoundParameters.ContainsKey('speed') ) { $payload.Add('speed', $speed) }
            if ( $PSBoundParameters.ContainsKey('flowctl') ) { $payload.Add('flowctl', $flowctl) }
            if ( $PSBoundParameters.ContainsKey('hamonitor') ) { $payload.Add('hamonitor', $hamonitor) }
            if ( $PSBoundParameters.ContainsKey('haheartbeat') ) { $payload.Add('haheartbeat', $haheartbeat) }
            if ( $PSBoundParameters.ContainsKey('tagall') ) { $payload.Add('tagall', $tagall) }
            if ( $PSBoundParameters.ContainsKey('trunk') ) { $payload.Add('trunk', $trunk) }
            if ( $PSBoundParameters.ContainsKey('ifalias') ) { $payload.Add('ifalias', $ifalias) }
            if ( $PSBoundParameters.ContainsKey('throughput') ) { $payload.Add('throughput', $throughput) }
            if ( $PSBoundParameters.ContainsKey('bandwidthhigh') ) { $payload.Add('bandwidthhigh', $bandwidthhigh) }
            if ( $PSBoundParameters.ContainsKey('bandwidthnormal') ) { $payload.Add('bandwidthnormal', $bandwidthnormal) }
            if ( $PSCmdlet.ShouldProcess("channel", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type channel -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetChannel -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddChannel: Finished"
    }
}

function Invoke-ADCDeleteChannel {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for channel resource.
    .PARAMETER Id
        ID for the LA channel or cluster LA channel or LR channel to be created. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4. Cannot be changed after the LA channel is created.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteChannel -Id <string>
        An example how to delete channel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteChannel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteChannel: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type channel -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteChannel: Finished"
    }
}

function Invoke-ADCUpdateChannel {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for channel resource.
    .PARAMETER Id
        ID for the LA channel or cluster LA channel or LR channel to be created. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4. Cannot be changed after the LA channel is created.
    .PARAMETER State
        Enable or disable the LA channel.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mode
        The initital mode for the LA channel.
        Possible values = MANUAL, AUTO
    .PARAMETER Conndistr
        The 'connection' distribution mode for the LA channel.
        Possible values = DISABLED, ENABLED
    .PARAMETER Macdistr
        The 'MAC' distribution mode for the LA channel.
        Possible values = SOURCE, DESTINATION, BOTH
    .PARAMETER Lamac
        Specifies a MAC address for the LA channels configured in Citrix ADC virtual appliances (VPX). This MAC address is persistent after each reboot.
        If you don't specify this parameter, a MAC address is generated randomly for each LA channel. These MAC addresses change after each reboot.
    .PARAMETER Speed
        Ethernet speed of the channel, in Mbps. If the speed of any bound interface is greater than or equal to the value set for this parameter, the state of the interface is UP. Otherwise, the state is INACTIVE. Bound Interfaces whose state is INACTIVE do not process any traffic.
        Possible values = AUTO, 10, 100, 1000, 10000, 25000, 40000, 50000, 100000
    .PARAMETER Mtu
        The Maximum Transmission Unit (MTU) is the largest packet size, measured in bytes excluding 14 bytes ethernet header and 4 bytes CRC, that can be transmitted and received by an interface. The default value of MTU is 1500 on all the interface of Citrix ADC, some Cloud Platforms will restrict Citrix ADC to use the lesser default value. Any MTU value more than 1500 is called Jumbo MTU and will make the interface as jumbo enabled. The Maximum Jumbo MTU in Citrix ADC is 9216, however, some Virtualized / Cloud Platforms will have lesser Maximum Jumbo MTU Value (9000). In the case of Cluster, the Backplane interface requires an MTU value of 78 bytes more than the Max MTU configured on any other Data-Plane Interface. When the Data plane interfaces are all at default 1500 MTU, Cluster Back Plane will be automatically set to 1578 (1500 + 78) MTU. If a Backplane interface is reset to Data Plane Interface, then the 1578 MTU will be automatically reset to the default MTU of 1500(or whatever lesser default value). If any data plane interface of a Cluster is configured with a Jumbo MTU ( > 1500), then all backplane interfaces require to be configured with a minimum MTU of 'Highest Data Plane MTU in the Cluster + 78'. That makes the maximum Jumbo MTU for any Data-Plane Interface in a Cluster System to be '9138 (9216 - 78)., where 9216 is the maximum Jumbo MTU. On certain Virtualized / Cloud Platforms, the maximum possible MTU is restricted to a lesser value, Similar calculation can be applied, Maximum Data Plane MTU in Cluster = (Maximum possible MTU - 78). .
    .PARAMETER Flowctl
        Specifies the flow control type for this LA channel to manage the flow of frames. Flow control is a function as mentioned in clause 31 of the IEEE 802.3 standard. Flow control allows congested ports to pause traffic from the peer device. Flow control is achieved by sending PAUSE frames.
        Possible values = OFF, RX, TX, RXTX, ON
    .PARAMETER Hamonitor
        In a High Availability (HA) configuration, monitor the LA channel for failure events. Failure of any LA channel that has HA MON enabled triggers HA failover.
        Possible values = ON, OFF
    .PARAMETER Haheartbeat
        In a High Availability (HA) configuration, configure the LA channel for sending heartbeats. LA channel that has HA Heartbeat disabled should not send the heartbeats.
        Possible values = OFF, ON
    .PARAMETER Tagall
        Adds a four-byte 802.1q tag to every packet sent on this channel. The ON setting applies tags for all VLANs that are bound to this channel. OFF applies the tag for all VLANs other than the native VLAN.
        Possible values = ON, OFF
    .PARAMETER Trunk
        This is deprecated by tagall.
        Possible values = ON, OFF
    .PARAMETER Ifalias
        Alias name for the LA channel. Used only to enhance readability. To perform any operations, you have to specify the LA channel ID.
    .PARAMETER Throughput
        Low threshold value for the throughput of the LA channel, in Mbps. In an high availability (HA) configuration, failover is triggered when the LA channel has HA MON enabled and the throughput is below the specified threshold.
    .PARAMETER Lrminthroughput
        Specifies the minimum throughput threshold (in Mbps) to be met by the active subchannel. Setting this parameter automatically divides an LACP channel into logical subchannels, with one subchannel active and the others in standby mode. When the maximum supported throughput of the active channel falls below the lrMinThroughput value, link failover occurs and a standby subchannel becomes active.
    .PARAMETER Linkredundancy
        Link Redundancy for Cluster LAG.
        Possible values = ON, OFF
    .PARAMETER Bandwidthhigh
        High threshold value for the bandwidth usage of the LA channel, in Mbps. The Citrix ADC generates an SNMP trap message when the bandwidth usage of the LA channel is greater than or equal to the specified high threshold value.
    .PARAMETER Bandwidthnormal
        Normal threshold value for the bandwidth usage of the LA channel, in Mbps. When the bandwidth usage of the LA channel returns to less than or equal to the specified normal threshold after exceeding the high threshold, the Citrix ADC generates an SNMP trap message to indicate that the bandwidth usage has returned to normal.
    .PARAMETER PassThru
        Return details about the created channel item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateChannel -id <string>
        An example how to update channel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateChannel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$State,

        [ValidateSet('MANUAL', 'AUTO')]
        [string]$Mode,

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Conndistr,

        [ValidateSet('SOURCE', 'DESTINATION', 'BOTH')]
        [string]$Macdistr,

        [string]$Lamac,

        [ValidateSet('AUTO', '10', '100', '1000', '10000', '25000', '40000', '50000', '100000')]
        [string]$Speed,

        [ValidateRange(1500, 9216)]
        [double]$Mtu,

        [ValidateSet('OFF', 'RX', 'TX', 'RXTX', 'ON')]
        [string]$Flowctl,

        [ValidateSet('ON', 'OFF')]
        [string]$Hamonitor,

        [ValidateSet('OFF', 'ON')]
        [string]$Haheartbeat,

        [ValidateSet('ON', 'OFF')]
        [string]$Tagall,

        [ValidateSet('ON', 'OFF')]
        [string]$Trunk,

        [string]$Ifalias,

        [ValidateRange(0, 160000)]
        [double]$Throughput,

        [ValidateRange(0, 80000)]
        [double]$Lrminthroughput,

        [ValidateSet('ON', 'OFF')]
        [string]$Linkredundancy,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthhigh,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthnormal,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateChannel: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('state') ) { $payload.Add('state', $state) }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSBoundParameters.ContainsKey('conndistr') ) { $payload.Add('conndistr', $conndistr) }
            if ( $PSBoundParameters.ContainsKey('macdistr') ) { $payload.Add('macdistr', $macdistr) }
            if ( $PSBoundParameters.ContainsKey('lamac') ) { $payload.Add('lamac', $lamac) }
            if ( $PSBoundParameters.ContainsKey('speed') ) { $payload.Add('speed', $speed) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('flowctl') ) { $payload.Add('flowctl', $flowctl) }
            if ( $PSBoundParameters.ContainsKey('hamonitor') ) { $payload.Add('hamonitor', $hamonitor) }
            if ( $PSBoundParameters.ContainsKey('haheartbeat') ) { $payload.Add('haheartbeat', $haheartbeat) }
            if ( $PSBoundParameters.ContainsKey('tagall') ) { $payload.Add('tagall', $tagall) }
            if ( $PSBoundParameters.ContainsKey('trunk') ) { $payload.Add('trunk', $trunk) }
            if ( $PSBoundParameters.ContainsKey('ifalias') ) { $payload.Add('ifalias', $ifalias) }
            if ( $PSBoundParameters.ContainsKey('throughput') ) { $payload.Add('throughput', $throughput) }
            if ( $PSBoundParameters.ContainsKey('lrminthroughput') ) { $payload.Add('lrminthroughput', $lrminthroughput) }
            if ( $PSBoundParameters.ContainsKey('linkredundancy') ) { $payload.Add('linkredundancy', $linkredundancy) }
            if ( $PSBoundParameters.ContainsKey('bandwidthhigh') ) { $payload.Add('bandwidthhigh', $bandwidthhigh) }
            if ( $PSBoundParameters.ContainsKey('bandwidthnormal') ) { $payload.Add('bandwidthnormal', $bandwidthnormal) }
            if ( $PSCmdlet.ShouldProcess("channel", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type channel -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetChannel -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateChannel: Finished"
    }
}

function Invoke-ADCUnsetChannel {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for channel resource.
    .PARAMETER Id
        ID for the LA channel or cluster LA channel or LR channel to be created. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4. Cannot be changed after the LA channel is created.
    .PARAMETER State
        Enable or disable the LA channel.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mode
        The initital mode for the LA channel.
        Possible values = MANUAL, AUTO
    .PARAMETER Conndistr
        The 'connection' distribution mode for the LA channel.
        Possible values = DISABLED, ENABLED
    .PARAMETER Macdistr
        The 'MAC' distribution mode for the LA channel.
        Possible values = SOURCE, DESTINATION, BOTH
    .PARAMETER Speed
        Ethernet speed of the channel, in Mbps. If the speed of any bound interface is greater than or equal to the value set for this parameter, the state of the interface is UP. Otherwise, the state is INACTIVE. Bound Interfaces whose state is INACTIVE do not process any traffic.
        Possible values = AUTO, 10, 100, 1000, 10000, 25000, 40000, 50000, 100000
    .PARAMETER Mtu
        The Maximum Transmission Unit (MTU) is the largest packet size, measured in bytes excluding 14 bytes ethernet header and 4 bytes CRC, that can be transmitted and received by an interface. The default value of MTU is 1500 on all the interface of Citrix ADC, some Cloud Platforms will restrict Citrix ADC to use the lesser default value. Any MTU value more than 1500 is called Jumbo MTU and will make the interface as jumbo enabled. The Maximum Jumbo MTU in Citrix ADC is 9216, however, some Virtualized / Cloud Platforms will have lesser Maximum Jumbo MTU Value (9000). In the case of Cluster, the Backplane interface requires an MTU value of 78 bytes more than the Max MTU configured on any other Data-Plane Interface. When the Data plane interfaces are all at default 1500 MTU, Cluster Back Plane will be automatically set to 1578 (1500 + 78) MTU. If a Backplane interface is reset to Data Plane Interface, then the 1578 MTU will be automatically reset to the default MTU of 1500(or whatever lesser default value). If any data plane interface of a Cluster is configured with a Jumbo MTU ( > 1500), then all backplane interfaces require to be configured with a minimum MTU of 'Highest Data Plane MTU in the Cluster + 78'. That makes the maximum Jumbo MTU for any Data-Plane Interface in a Cluster System to be '9138 (9216 - 78)., where 9216 is the maximum Jumbo MTU. On certain Virtualized / Cloud Platforms, the maximum possible MTU is restricted to a lesser value, Similar calculation can be applied, Maximum Data Plane MTU in Cluster = (Maximum possible MTU - 78). .
    .PARAMETER Flowctl
        Specifies the flow control type for this LA channel to manage the flow of frames. Flow control is a function as mentioned in clause 31 of the IEEE 802.3 standard. Flow control allows congested ports to pause traffic from the peer device. Flow control is achieved by sending PAUSE frames.
        Possible values = OFF, RX, TX, RXTX, ON
    .PARAMETER Hamonitor
        In a High Availability (HA) configuration, monitor the LA channel for failure events. Failure of any LA channel that has HA MON enabled triggers HA failover.
        Possible values = ON, OFF
    .PARAMETER Haheartbeat
        In a High Availability (HA) configuration, configure the LA channel for sending heartbeats. LA channel that has HA Heartbeat disabled should not send the heartbeats.
        Possible values = OFF, ON
    .PARAMETER Tagall
        Adds a four-byte 802.1q tag to every packet sent on this channel. The ON setting applies tags for all VLANs that are bound to this channel. OFF applies the tag for all VLANs other than the native VLAN.
        Possible values = ON, OFF
    .PARAMETER Trunk
        This is deprecated by tagall.
        Possible values = ON, OFF
    .PARAMETER Ifalias
        Alias name for the LA channel. Used only to enhance readability. To perform any operations, you have to specify the LA channel ID.
    .PARAMETER Throughput
        Low threshold value for the throughput of the LA channel, in Mbps. In an high availability (HA) configuration, failover is triggered when the LA channel has HA MON enabled and the throughput is below the specified threshold.
    .PARAMETER Lrminthroughput
        Specifies the minimum throughput threshold (in Mbps) to be met by the active subchannel. Setting this parameter automatically divides an LACP channel into logical subchannels, with one subchannel active and the others in standby mode. When the maximum supported throughput of the active channel falls below the lrMinThroughput value, link failover occurs and a standby subchannel becomes active.
    .PARAMETER Linkredundancy
        Link Redundancy for Cluster LAG.
        Possible values = ON, OFF
    .PARAMETER Bandwidthhigh
        High threshold value for the bandwidth usage of the LA channel, in Mbps. The Citrix ADC generates an SNMP trap message when the bandwidth usage of the LA channel is greater than or equal to the specified high threshold value.
    .PARAMETER Bandwidthnormal
        Normal threshold value for the bandwidth usage of the LA channel, in Mbps. When the bandwidth usage of the LA channel returns to less than or equal to the specified normal threshold after exceeding the high threshold, the Citrix ADC generates an SNMP trap message to indicate that the bandwidth usage has returned to normal.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetChannel -id <string>
        An example how to unset channel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetChannel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Id,

        [Boolean]$state,

        [Boolean]$mode,

        [Boolean]$conndistr,

        [Boolean]$macdistr,

        [Boolean]$speed,

        [Boolean]$mtu,

        [Boolean]$flowctl,

        [Boolean]$hamonitor,

        [Boolean]$haheartbeat,

        [Boolean]$tagall,

        [Boolean]$trunk,

        [Boolean]$ifalias,

        [Boolean]$throughput,

        [Boolean]$lrminthroughput,

        [Boolean]$linkredundancy,

        [Boolean]$bandwidthhigh,

        [Boolean]$bandwidthnormal 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetChannel: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('state') ) { $payload.Add('state', $state) }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSBoundParameters.ContainsKey('conndistr') ) { $payload.Add('conndistr', $conndistr) }
            if ( $PSBoundParameters.ContainsKey('macdistr') ) { $payload.Add('macdistr', $macdistr) }
            if ( $PSBoundParameters.ContainsKey('speed') ) { $payload.Add('speed', $speed) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('flowctl') ) { $payload.Add('flowctl', $flowctl) }
            if ( $PSBoundParameters.ContainsKey('hamonitor') ) { $payload.Add('hamonitor', $hamonitor) }
            if ( $PSBoundParameters.ContainsKey('haheartbeat') ) { $payload.Add('haheartbeat', $haheartbeat) }
            if ( $PSBoundParameters.ContainsKey('tagall') ) { $payload.Add('tagall', $tagall) }
            if ( $PSBoundParameters.ContainsKey('trunk') ) { $payload.Add('trunk', $trunk) }
            if ( $PSBoundParameters.ContainsKey('ifalias') ) { $payload.Add('ifalias', $ifalias) }
            if ( $PSBoundParameters.ContainsKey('throughput') ) { $payload.Add('throughput', $throughput) }
            if ( $PSBoundParameters.ContainsKey('lrminthroughput') ) { $payload.Add('lrminthroughput', $lrminthroughput) }
            if ( $PSBoundParameters.ContainsKey('linkredundancy') ) { $payload.Add('linkredundancy', $linkredundancy) }
            if ( $PSBoundParameters.ContainsKey('bandwidthhigh') ) { $payload.Add('bandwidthhigh', $bandwidthhigh) }
            if ( $PSBoundParameters.ContainsKey('bandwidthnormal') ) { $payload.Add('bandwidthnormal', $bandwidthnormal) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type channel -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetChannel: Finished"
    }
}

function Invoke-ADCGetChannel {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for channel resource.
    .PARAMETER Id
        ID for the LA channel or cluster LA channel or LR channel to be created. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4. Cannot be changed after the LA channel is created.
    .PARAMETER GetAll
        Retrieve all channel object(s).
    .PARAMETER Count
        If specified, the count of the channel object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannel
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannel -GetAll
        Get all channel data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannel -Count
        Get the number of channel objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannel -name <string>
        Get channel object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannel -Filter @{ 'name'='<value>' }
        Get channel data with a filter.
    .NOTES
        File Name : Invoke-ADCGetChannel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetChannel: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all channel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for channel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving channel objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving channel configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving channel configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetChannel: Ended"
    }
}

function Invoke-ADCGetChannelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to channel.
    .PARAMETER Id
        ID of an LA channel or LA channel in cluster configuration whose details you want the Citrix ADC to display.
        Specify an LA channel in LA/x notation, where x can range from 1 to 8 or a cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4.
    .PARAMETER GetAll
        Retrieve all channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelbinding -GetAll
        Get all channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelbinding -name <string>
        Get channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelbinding -Filter @{ 'name'='<value>' }
        Get channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetChannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetChannelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving channel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetChannelbinding: Ended"
    }
}

function Invoke-ADCAddChannelinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to channel.
    .PARAMETER Id
        ID of the LA channel or the cluster LA channel to which you want to bind interfaces. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or a cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4.
    .PARAMETER Ifnum
        Interfaces to be bound to the LA channel of a Citrix ADC or to the LA channel of a cluster configuration. For an LA channel of a Citrix ADC, specify an interface in C/U notation (for example, 1/3). For an LA channel of a cluster configuration, specify an interface in N/C/U notation (for example, 2/1/3). where C can take one of the following values: * 0 - Indicates a management interface. * 1 - Indicates a 1 Gbps port. * 10 - Indicates a 10 Gbps port. U is a unique integer for representing an interface in a particular port group. N is the ID of the node to which an interface belongs in a cluster configuration. Use spaces to separate multiple entries.
    .PARAMETER PassThru
        Return details about the created channel_interface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddChannelinterfacebinding -id <string> -ifnum <string[]>
        An example how to add channel_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddChannelinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [Parameter(Mandatory)]
        [string[]]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddChannelinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id
                ifnum        = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("channel_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type channel_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetChannelinterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddChannelinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteChannelinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to channel.
    .PARAMETER Id
        ID of the LA channel or the cluster LA channel to which you want to bind interfaces. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or a cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4.
    .PARAMETER Ifnum
        Interfaces to be bound to the LA channel of a Citrix ADC or to the LA channel of a cluster configuration. For an LA channel of a Citrix ADC, specify an interface in C/U notation (for example, 1/3). For an LA channel of a cluster configuration, specify an interface in N/C/U notation (for example, 2/1/3). where C can take one of the following values: * 0 - Indicates a management interface. * 1 - Indicates a 1 Gbps port. * 10 - Indicates a 10 Gbps port. U is a unique integer for representing an interface in a particular port group. N is the ID of the node to which an interface belongs in a cluster configuration. Use spaces to separate multiple entries.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteChannelinterfacebinding -Id <string>
        An example how to delete channel_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteChannelinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [string[]]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteChannelinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type channel_interface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteChannelinterfacebinding: Finished"
    }
}

function Invoke-ADCGetChannelinterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the interface that can be bound to channel.
    .PARAMETER Id
        ID of the LA channel or the cluster LA channel to which you want to bind interfaces. Specify an LA channel in LA/x notation, where x can range from 1 to 8 or a cluster LA channel in CLA/x notation or Link redundant channel in LR/x notation, where x can range from 1 to 4.
    .PARAMETER GetAll
        Retrieve all channel_interface_binding object(s).
    .PARAMETER Count
        If specified, the count of the channel_interface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelinterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelinterfacebinding -GetAll
        Get all channel_interface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelinterfacebinding -Count
        Get the number of channel_interface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelinterfacebinding -name <string>
        Get channel_interface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetChannelinterfacebinding -Filter @{ 'name'='<value>' }
        Get channel_interface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetChannelinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/channel_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetChannelinterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all channel_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for channel_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving channel_interface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_interface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving channel_interface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_interface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving channel_interface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type channel_interface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetChannelinterfacebinding: Ended"
    }
}

function Invoke-ADCGetCi {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for "CI" resource.
    .PARAMETER GetAll
        Retrieve all ci object(s).
    .PARAMETER Count
        If specified, the count of the ci object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetCi
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetCi -GetAll
        Get all ci data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetCi -Count
        Get the number of ci objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetCi -name <string>
        Get ci object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetCi -Filter @{ 'name'='<value>' }
        Get ci data with a filter.
    .NOTES
        File Name : Invoke-ADCGetCi
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ci/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetCi: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ci objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ci -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ci objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ci -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ci objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ci -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ci configuration for property ''"

            } else {
                Write-Verbose "Retrieving ci configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ci -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetCi: Ended"
    }
}

function Invoke-ADCAddFis {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for "FIS" resource.
    .PARAMETER Name
        Name for the FIS to be created. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ). Note: In a cluster setup, the FIS name on each node must be unique.
    .PARAMETER Ownernode
        ID of the cluster node for which you are creating the FIS. Can be configured only through the cluster IP address.
    .PARAMETER PassThru
        Return details about the created fis item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddFis -name <string>
        An example how to add fis configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddFis
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddFis: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("fis", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type fis -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetFis -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddFis: Finished"
    }
}

function Invoke-ADCDeleteFis {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for "FIS" resource.
    .PARAMETER Name
        Name for the FIS to be created. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ). Note: In a cluster setup, the FIS name on each node must be unique.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteFis -Name <string>
        An example how to delete fis configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteFis
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteFis: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type fis -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteFis: Finished"
    }
}

function Invoke-ADCGetFis {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for "FIS" resource.
    .PARAMETER Name
        Name for the FIS to be created. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ). Note: In a cluster setup, the FIS name on each node must be unique.
    .PARAMETER GetAll
        Retrieve all fis object(s).
    .PARAMETER Count
        If specified, the count of the fis object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFis
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFis -GetAll
        Get all fis data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFis -Count
        Get the number of fis objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFis -name <string>
        Get fis object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFis -Filter @{ 'name'='<value>' }
        Get fis data with a filter.
    .NOTES
        File Name : Invoke-ADCGetFis
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetFis: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all fis objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for fis objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving fis objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving fis configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving fis configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetFis: Ended"
    }
}

function Invoke-ADCGetFisbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to fis.
    .PARAMETER Name
        The name of the FIS configured on the appliance. .
    .PARAMETER GetAll
        Retrieve all fis_binding object(s).
    .PARAMETER Count
        If specified, the count of the fis_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFisbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFisbinding -GetAll
        Get all fis_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFisbinding -name <string>
        Get fis_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFisbinding -Filter @{ 'name'='<value>' }
        Get fis_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetFisbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetFisbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all fis_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for fis_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving fis_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving fis_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving fis_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetFisbinding: Ended"
    }
}

function Invoke-ADCAddFischannelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to fis.
    .PARAMETER Name
        The name of the FIS to which you want to bind interfaces.
    .PARAMETER Ifnum
        Interface to be bound to the FIS, specified in slot/port notation (for example, 1/3).
    .PARAMETER PassThru
        Return details about the created fis_channel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddFischannelbinding -name <string> -ifnum <string>
        An example how to add fis_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddFischannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddFischannelbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                ifnum          = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("fis_channel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type fis_channel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetFischannelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddFischannelbinding: Finished"
    }
}

function Invoke-ADCDeleteFischannelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to fis.
    .PARAMETER Name
        The name of the FIS to which you want to bind interfaces.
    .PARAMETER Ifnum
        Interface to be bound to the FIS, specified in slot/port notation (for example, 1/3).
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteFischannelbinding -Name <string>
        An example how to delete fis_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteFischannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteFischannelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type fis_channel_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteFischannelbinding: Finished"
    }
}

function Invoke-ADCGetFischannelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the channel that can be bound to fis.
    .PARAMETER Name
        The name of the FIS to which you want to bind interfaces.
    .PARAMETER GetAll
        Retrieve all fis_channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the fis_channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFischannelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFischannelbinding -GetAll
        Get all fis_channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFischannelbinding -Count
        Get the number of fis_channel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFischannelbinding -name <string>
        Get fis_channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetFischannelbinding -Filter @{ 'name'='<value>' }
        Get fis_channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetFischannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetFischannelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all fis_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for fis_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving fis_channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving fis_channel_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_channel_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving fis_channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type fis_channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetFischannelbinding: Ended"
    }
}

function Invoke-ADCAddFisinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to fis.
    .PARAMETER Name
        The name of the FIS to which you want to bind interfaces.
    .PARAMETER Ifnum
        Interface to be bound to the FIS, specified in slot/port notation (for example, 1/3).
    .EXAMPLE
        PS C:\>Invoke-ADCAddFisinterfacebinding -name <string> -ifnum <string>
        An example how to add fis_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddFisinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCAddFisinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                ifnum          = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("fis_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type fis_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddFisinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteFisinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to fis.
    .PARAMETER Name
        The name of the FIS to which you want to bind interfaces.
    .PARAMETER Ifnum
        Interface to be bound to the FIS, specified in slot/port notation (for example, 1/3).
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteFisinterfacebinding -Name <string>
        An example how to delete fis_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteFisinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/fis_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteFisinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type fis_interface_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteFisinterfacebinding: Finished"
    }
}

function Invoke-ADCAddForwardingsession {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for session forward resource.
    .PARAMETER Name
        Name for the forwarding session rule. Can begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created.
    .PARAMETER Network
        An IPv4 network address or IPv6 prefix of a network from which the forwarded traffic originates or to which it is destined.
    .PARAMETER Netmask
        Subnet mask associated with the network.
    .PARAMETER Acl6name
        Name of any configured ACL6 whose action is ALLOW. The rule of the ACL6 is used as a forwarding session rule.
    .PARAMETER Aclname
        Name of any configured ACL whose action is ALLOW. The rule of the ACL is used as a forwarding session rule.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the forwarding session.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sourceroutecache
        Cache the source ip address and mac address of the DA servers.
        Possible values = ENABLED, DISABLED
    .PARAMETER Processlocal
        Enabling this option on forwarding session will not steer the packet to flow processor. Instead, packet will be routed.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created forwardingsession item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddForwardingsession -name <string>
        An example how to add forwardingsession configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddForwardingsession
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/forwardingsession/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Acl6name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sourceroutecache = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Processlocal = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddForwardingsession: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('acl6name') ) { $payload.Add('acl6name', $acl6name) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSBoundParameters.ContainsKey('sourceroutecache') ) { $payload.Add('sourceroutecache', $sourceroutecache) }
            if ( $PSBoundParameters.ContainsKey('processlocal') ) { $payload.Add('processlocal', $processlocal) }
            if ( $PSCmdlet.ShouldProcess("forwardingsession", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type forwardingsession -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetForwardingsession -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddForwardingsession: Finished"
    }
}

function Invoke-ADCUpdateForwardingsession {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for session forward resource.
    .PARAMETER Name
        Name for the forwarding session rule. Can begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created.
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the forwarding session.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sourceroutecache
        Cache the source ip address and mac address of the DA servers.
        Possible values = ENABLED, DISABLED
    .PARAMETER Processlocal
        Enabling this option on forwarding session will not steer the packet to flow processor. Instead, packet will be routed.
        Possible values = ENABLED, DISABLED
    .PARAMETER Acl6name
        Name of any configured ACL6 whose action is ALLOW. The rule of the ACL6 is used as a forwarding session rule.
    .PARAMETER Aclname
        Name of any configured ACL whose action is ALLOW. The rule of the ACL is used as a forwarding session rule.
    .PARAMETER PassThru
        Return details about the created forwardingsession item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateForwardingsession -name <string>
        An example how to update forwardingsession configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateForwardingsession
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/forwardingsession/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sourceroutecache,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Processlocal,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Acl6name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateForwardingsession: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSBoundParameters.ContainsKey('sourceroutecache') ) { $payload.Add('sourceroutecache', $sourceroutecache) }
            if ( $PSBoundParameters.ContainsKey('processlocal') ) { $payload.Add('processlocal', $processlocal) }
            if ( $PSBoundParameters.ContainsKey('acl6name') ) { $payload.Add('acl6name', $acl6name) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSCmdlet.ShouldProcess("forwardingsession", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type forwardingsession -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetForwardingsession -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateForwardingsession: Finished"
    }
}

function Invoke-ADCDeleteForwardingsession {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for session forward resource.
    .PARAMETER Name
        Name for the forwarding session rule. Can begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteForwardingsession -Name <string>
        An example how to delete forwardingsession configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteForwardingsession
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/forwardingsession/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteForwardingsession: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type forwardingsession -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteForwardingsession: Finished"
    }
}

function Invoke-ADCGetForwardingsession {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for session forward resource.
    .PARAMETER Name
        Name for the forwarding session rule. Can begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created.
    .PARAMETER GetAll
        Retrieve all forwardingsession object(s).
    .PARAMETER Count
        If specified, the count of the forwardingsession object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetForwardingsession
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetForwardingsession -GetAll
        Get all forwardingsession data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetForwardingsession -Count
        Get the number of forwardingsession objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetForwardingsession -name <string>
        Get forwardingsession object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetForwardingsession -Filter @{ 'name'='<value>' }
        Get forwardingsession data with a filter.
    .NOTES
        File Name : Invoke-ADCGetForwardingsession
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/forwardingsession/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetForwardingsession: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all forwardingsession objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type forwardingsession -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for forwardingsession objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type forwardingsession -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving forwardingsession objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type forwardingsession -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving forwardingsession configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type forwardingsession -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving forwardingsession configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type forwardingsession -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetForwardingsession: Ended"
    }
}

function Invoke-ADCAddInat {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for inbound nat resource.
    .PARAMETER Name
        Name for the Inbound NAT (INAT) entry. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER Publicip
        Public IP address of packets received on the Citrix ADC. Can be aNetScaler-owned VIP or VIP6 address.
    .PARAMETER Privateip
        IP address of the server to which the packet is sent by the Citrix ADC. Can be an IPv4 or IPv6 address.
    .PARAMETER Mode
        Stateless translation.
        Possible values = STATELESS
    .PARAMETER Tcpproxy
        Enable TCP proxy, which enables the Citrix ADC to optimize the RNAT TCP traffic by using Layer 4 features.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ftp
        Enable the FTP protocol on the server for transferring files between the client and the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tftp
        To enable/disable TFTP (Default DISABLED).
        Possible values = ENABLED, DISABLED
    .PARAMETER Usip
        Enable the Citrix ADC to retain the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Usnip
        Enable the Citrix ADC to use a SNIP address as the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Proxyip
        Unique IP address used as the source IP address in packets sent to the server. Must be a MIP or SNIP address.
    .PARAMETER Useproxyport
        Enable the Citrix ADC to proxy the source port of packets before sending the packets to the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the INAT session.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created inat item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddInat -name <string> -publicip <string> -privateip <string>
        An example how to add inat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddInat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Publicip,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Privateip,

        [ValidateSet('STATELESS')]
        [string]$Mode,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tcpproxy = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ftp = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tftp = 'DISABLED',

        [ValidateSet('ON', 'OFF')]
        [string]$Usip,

        [ValidateSet('ON', 'OFF')]
        [string]$Usnip,

        [string]$Proxyip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Useproxyport = 'ENABLED',

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddInat: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                publicip       = $publicip
                privateip      = $privateip
            }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSBoundParameters.ContainsKey('tcpproxy') ) { $payload.Add('tcpproxy', $tcpproxy) }
            if ( $PSBoundParameters.ContainsKey('ftp') ) { $payload.Add('ftp', $ftp) }
            if ( $PSBoundParameters.ContainsKey('tftp') ) { $payload.Add('tftp', $tftp) }
            if ( $PSBoundParameters.ContainsKey('usip') ) { $payload.Add('usip', $usip) }
            if ( $PSBoundParameters.ContainsKey('usnip') ) { $payload.Add('usnip', $usnip) }
            if ( $PSBoundParameters.ContainsKey('proxyip') ) { $payload.Add('proxyip', $proxyip) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSCmdlet.ShouldProcess("inat", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type inat -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetInat -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddInat: Finished"
    }
}

function Invoke-ADCDeleteInat {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for inbound nat resource.
    .PARAMETER Name
        Name for the Inbound NAT (INAT) entry. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteInat -Name <string>
        An example how to delete inat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteInat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteInat: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type inat -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteInat: Finished"
    }
}

function Invoke-ADCUpdateInat {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for inbound nat resource.
    .PARAMETER Name
        Name for the Inbound NAT (INAT) entry. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER Privateip
        IP address of the server to which the packet is sent by the Citrix ADC. Can be an IPv4 or IPv6 address.
    .PARAMETER Tcpproxy
        Enable TCP proxy, which enables the Citrix ADC to optimize the RNAT TCP traffic by using Layer 4 features.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ftp
        Enable the FTP protocol on the server for transferring files between the client and the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tftp
        To enable/disable TFTP (Default DISABLED).
        Possible values = ENABLED, DISABLED
    .PARAMETER Usip
        Enable the Citrix ADC to retain the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Usnip
        Enable the Citrix ADC to use a SNIP address as the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Proxyip
        Unique IP address used as the source IP address in packets sent to the server. Must be a MIP or SNIP address.
    .PARAMETER Useproxyport
        Enable the Citrix ADC to proxy the source port of packets before sending the packets to the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the INAT session.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mode
        Stateless translation.
        Possible values = STATELESS
    .PARAMETER PassThru
        Return details about the created inat item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateInat -name <string>
        An example how to update inat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateInat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Privateip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tcpproxy,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ftp,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tftp,

        [ValidateSet('ON', 'OFF')]
        [string]$Usip,

        [ValidateSet('ON', 'OFF')]
        [string]$Usnip,

        [string]$Proxyip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Useproxyport,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover,

        [ValidateSet('STATELESS')]
        [string]$Mode,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateInat: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('privateip') ) { $payload.Add('privateip', $privateip) }
            if ( $PSBoundParameters.ContainsKey('tcpproxy') ) { $payload.Add('tcpproxy', $tcpproxy) }
            if ( $PSBoundParameters.ContainsKey('ftp') ) { $payload.Add('ftp', $ftp) }
            if ( $PSBoundParameters.ContainsKey('tftp') ) { $payload.Add('tftp', $tftp) }
            if ( $PSBoundParameters.ContainsKey('usip') ) { $payload.Add('usip', $usip) }
            if ( $PSBoundParameters.ContainsKey('usnip') ) { $payload.Add('usnip', $usnip) }
            if ( $PSBoundParameters.ContainsKey('proxyip') ) { $payload.Add('proxyip', $proxyip) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSCmdlet.ShouldProcess("inat", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type inat -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetInat -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateInat: Finished"
    }
}

function Invoke-ADCUnsetInat {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for inbound nat resource.
    .PARAMETER Name
        Name for the Inbound NAT (INAT) entry. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER Tcpproxy
        Enable TCP proxy, which enables the Citrix ADC to optimize the RNAT TCP traffic by using Layer 4 features.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ftp
        Enable the FTP protocol on the server for transferring files between the client and the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tftp
        To enable/disable TFTP (Default DISABLED).
        Possible values = ENABLED, DISABLED
    .PARAMETER Usip
        Enable the Citrix ADC to retain the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Usnip
        Enable the Citrix ADC to use a SNIP address as the source IP address of packets before sending the packets to the server.
        Possible values = ON, OFF
    .PARAMETER Proxyip
        Unique IP address used as the source IP address in packets sent to the server. Must be a MIP or SNIP address.
    .PARAMETER Useproxyport
        Enable the Citrix ADC to proxy the source port of packets before sending the packets to the server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the INAT session.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mode
        Stateless translation.
        Possible values = STATELESS
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetInat -name <string>
        An example how to unset inat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetInat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inat
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Boolean]$tcpproxy,

        [Boolean]$ftp,

        [Boolean]$tftp,

        [Boolean]$usip,

        [Boolean]$usnip,

        [Boolean]$proxyip,

        [Boolean]$useproxyport,

        [Boolean]$connfailover,

        [Boolean]$mode 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetInat: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('tcpproxy') ) { $payload.Add('tcpproxy', $tcpproxy) }
            if ( $PSBoundParameters.ContainsKey('ftp') ) { $payload.Add('ftp', $ftp) }
            if ( $PSBoundParameters.ContainsKey('tftp') ) { $payload.Add('tftp', $tftp) }
            if ( $PSBoundParameters.ContainsKey('usip') ) { $payload.Add('usip', $usip) }
            if ( $PSBoundParameters.ContainsKey('usnip') ) { $payload.Add('usnip', $usnip) }
            if ( $PSBoundParameters.ContainsKey('proxyip') ) { $payload.Add('proxyip', $proxyip) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSBoundParameters.ContainsKey('mode') ) { $payload.Add('mode', $mode) }
            if ( $PSCmdlet.ShouldProcess("$name", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type inat -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetInat: Finished"
    }
}

function Invoke-ADCGetInat {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for inbound nat resource.
    .PARAMETER Name
        Name for the Inbound NAT (INAT) entry. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER GetAll
        Retrieve all inat object(s).
    .PARAMETER Count
        If specified, the count of the inat object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInat
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInat -GetAll
        Get all inat data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInat -Count
        Get the number of inat objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInat -name <string>
        Get inat object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInat -Filter @{ 'name'='<value>' }
        Get inat data with a filter.
    .NOTES
        File Name : Invoke-ADCGetInat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetInat: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all inat objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inat -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for inat objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inat -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving inat objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inat -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving inat configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inat -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving inat configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inat -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetInat: Ended"
    }
}

function Invoke-ADCUpdateInatparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for INAT parameter resource.
    .PARAMETER Nat46v6prefix
        The prefix used for translating packets received from private IPv6 servers into IPv4 packets. This prefix has a length of 96 bits (128-32 = 96). The IPv6 servers embed the destination IP address of the IPv4 servers or hosts in the last 32 bits of the destination IP address field of the IPv6 packets. The first 96 bits of the destination IP address field are set as the IPv6 NAT prefix. IPv6 packets addressed to this prefix have to be routed to the Citrix ADC to ensure that the IPv6-IPv4 translation is done by the appliance.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Nat46ignoretos
        Ignore TOS.
        Possible values = YES, NO
    .PARAMETER Nat46zerochecksum
        Calculate checksum for UDP packets with zero checksum.
        Possible values = ENABLED, DISABLED
    .PARAMETER Nat46v6mtu
        MTU setting for the IPv6 side. If the incoming IPv4 packet greater than this, either fragment or send icmp need fragmentation error.
    .PARAMETER Nat46fragheader
        When disabled, translator will not insert IPv6 fragmentation header for non fragmented IPv4 packets.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created inatparam item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateInatparam
        An example how to update inatparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateInatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inatparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Nat46v6prefix,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('YES', 'NO')]
        [string]$Nat46ignoretos,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Nat46zerochecksum,

        [ValidateRange(1280, 9216)]
        [double]$Nat46v6mtu,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Nat46fragheader,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateInatparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('nat46v6prefix') ) { $payload.Add('nat46v6prefix', $nat46v6prefix) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('nat46ignoretos') ) { $payload.Add('nat46ignoretos', $nat46ignoretos) }
            if ( $PSBoundParameters.ContainsKey('nat46zerochecksum') ) { $payload.Add('nat46zerochecksum', $nat46zerochecksum) }
            if ( $PSBoundParameters.ContainsKey('nat46v6mtu') ) { $payload.Add('nat46v6mtu', $nat46v6mtu) }
            if ( $PSBoundParameters.ContainsKey('nat46fragheader') ) { $payload.Add('nat46fragheader', $nat46fragheader) }
            if ( $PSCmdlet.ShouldProcess("inatparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type inatparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetInatparam -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateInatparam: Finished"
    }
}

function Invoke-ADCUnsetInatparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for INAT parameter resource.
    .PARAMETER Nat46v6prefix
        The prefix used for translating packets received from private IPv6 servers into IPv4 packets. This prefix has a length of 96 bits (128-32 = 96). The IPv6 servers embed the destination IP address of the IPv4 servers or hosts in the last 32 bits of the destination IP address field of the IPv6 packets. The first 96 bits of the destination IP address field are set as the IPv6 NAT prefix. IPv6 packets addressed to this prefix have to be routed to the Citrix ADC to ensure that the IPv6-IPv4 translation is done by the appliance.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetInatparam
        An example how to unset inatparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetInatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inatparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$nat46v6prefix,

        [Boolean]$td 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetInatparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('nat46v6prefix') ) { $payload.Add('nat46v6prefix', $nat46v6prefix) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSCmdlet.ShouldProcess("inatparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type inatparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetInatparam: Finished"
    }
}

function Invoke-ADCGetInatparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for INAT parameter resource.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER GetAll
        Retrieve all inatparam object(s).
    .PARAMETER Count
        If specified, the count of the inatparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInatparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInatparam -GetAll
        Get all inatparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInatparam -Count
        Get the number of inatparam objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInatparam -name <string>
        Get inatparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInatparam -Filter @{ 'name'='<value>' }
        Get inatparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetInatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/inatparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetInatparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all inatparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inatparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for inatparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inatparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving inatparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inatparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving inatparam configuration for property 'td'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inatparam -NitroPath nitro/v1/config -Resource $td -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving inatparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type inatparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetInatparam: Ended"
    }
}

function Invoke-ADCClearInterface {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .EXAMPLE
        PS C:\>Invoke-ADCClearInterface -id <string>
        An example how to clear Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 

    )
    begin {
        Write-Verbose "Invoke-ADCClearInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }

            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type interface -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearInterface: Finished"
    }
}

function Invoke-ADCUpdateInterface {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .PARAMETER Speed
        Ethernet speed of the interface, in Mbps.
        Notes:
        * If you set the speed as AUTO, the Citrix ADC attempts to auto-negotiate or auto-sense the link speed of the interface when it is UP. You must enable auto negotiation on the interface.
        * If you set a speed other than AUTO, you must specify the same speed for the peer network device. Mismatched speed and duplex settings between the peer devices of a link lead to link errors, packet loss, and other errors.
        Some interfaces do not support certain speeds. If you specify an unsupported speed, an error message appears.
        Possible values = AUTO, 10, 100, 1000, 10000, 25000, 40000, 50000, 100000
    .PARAMETER Duplex
        The duplex mode for the interface. Notes:* If you set the duplex mode to AUTO, the Citrix ADC attempts to auto-negotiate the duplex mode of the interface when it is UP. You must enable auto negotiation on the interface. If you set a duplex mode other than AUTO, you must specify the same duplex mode for the peer network device. Mismatched speed and duplex settings between the peer devices of a link lead to link errors, packet loss, and other errors.
        Possible values = AUTO, HALF, FULL
    .PARAMETER Flowctl
        802.3x flow control setting for the interface. The 802.3x specification does not define flow control for 10 Mbps and 100 Mbps speeds, but if a Gigabit Ethernet interface operates at those speeds, the flow control settings can be applied. The flow control setting that is finally applied to an interface depends on auto-negotiation. With the ON option, the peer negotiates the flow control, but the appliance then forces two-way flow control for the interface.
        Possible values = OFF, RX, TX, RXTX, ON
    .PARAMETER Autoneg
        Auto-negotiation state of the interface. With the ENABLED setting, the Citrix ADC auto-negotiates the speed and duplex settings with the peer network device on the link. The Citrix ADC appliance auto-negotiates the settings of only those parameters (speed or duplex mode) for which the value is set as AUTO.
        Possible values = DISABLED, ENABLED
    .PARAMETER Hamonitor
        In a High Availability (HA) configuration, monitor the interface for failure events. In an HA configuration, an interface that has HA MON enabled and is not bound to any Failover Interface Set (FIS), is a critical interface. Failure or disabling of any critical interface triggers HA failover.
        Possible values = ON, OFF
    .PARAMETER Haheartbeat
        In a High Availability (HA) or Cluster configuration, configure the interface for sending heartbeats. In an HA or Cluster configuration, an interface that has HA Heartbeat disabled should not send the heartbeats.
        Possible values = OFF, ON
    .PARAMETER Mtu
        The Maximum Transmission Unit (MTU) is the largest packet size, measured in bytes excluding 14 bytes ethernet header and 4 bytes CRC, that can be transmitted and received by an interface. The default value of MTU is 1500 on all the interface of Citrix ADC, some Cloud Platforms will restrict Citrix ADC to use the lesser default value. Any MTU value more than 1500 is called Jumbo MTU and will make the interface as jumbo enabled. The Maximum Jumbo MTU in Citrix ADC is 9216, however, some Virtualized / Cloud Platforms will have lesser Maximum Jumbo MTU Value (9000). In the case of Cluster, the Backplane interface requires an MTU value of 78 bytes more than the Max MTU configured on any other Data-Plane Interface. When the Data plane interfaces are all at default 1500 MTU, Cluster Back Plane will be automatically set to 1578 (1500 + 78) MTU. If a Backplane interface is reset to Data Plane Interface, then the 1578 MTU will be automatically reset to the default MTU of 1500(or whatever lesser default value). If any data plane interface of a Cluster is configured with a Jumbo MTU ( > 1500), then all backplane interfaces require to be configured with a minimum MTU of 'Highest Data Plane MTU in the Cluster + 78'. That makes the maximum Jumbo MTU for any Data-Plane Interface in a Cluster System to be '9138 (9216 - 78)., where 9216 is the maximum Jumbo MTU. On certain Virtualized / Cloud Platforms, the maximum possible MTU is restricted to a lesser value, Similar calculation can be applied, Maximum Data Plane MTU in Cluster = (Maximum possible MTU - 78).
    .PARAMETER Ringsize
        The receive ringsize of the interface. A higher number provides more number of buffers in handling incoming traffic.
    .PARAMETER Ringtype
        The receive ringtype of the interface (Fixed or Elastic). A fixed ring type pre-allocates configured number of buffers irrespective of traffic rate. In contrast, an elastic ring, expands and shrinks based on incoming traffic rate.
        Possible values = Elastic, Fixed
    .PARAMETER Tagall
        Add a four-byte 802.1q tag to every packet sent on this interface. The ON setting applies the tag for this interface's native VLAN. OFF applies the tag for all VLANs other than the native VLAN.
        Possible values = ON, OFF
    .PARAMETER Trunk
        This argument is deprecated by tagall.
        Possible values = ON, OFF
    .PARAMETER Trunkmode
        Accept and send 802.1q VLAN tagged packets, based on Allowed Vlan List of this interface.
        Possible values = ON, OFF
    .PARAMETER Trunkallowedvlan
        VLAN ID or range of VLAN IDs will be allowed on this trunk interface. In the command line interface, separate the range with a hyphen. For example: 40-90.
    .PARAMETER Lacpmode
        Bind the interface to a LA channel created by the Link Aggregation control protocol (LACP).
        Available settings function as follows:
        * Active - The LA channel port of the Citrix ADC generates LACPDU messages on a regular basis, regardless of any need expressed by its peer device to receive them.
        * Passive - The LA channel port of the Citrix ADC does not transmit LACPDU messages unless the peer device port is in the active mode. That is, the port does not speak unless spoken to.
        * Disabled - Unbinds the interface from the LA channel. If this is the only interface in the LA channel, the LA channel is removed.
        Possible values = DISABLED, ACTIVE, PASSIVE
    .PARAMETER Lacpkey
        Integer identifying the LACP LA channel to which the interface is to be bound.
        For an LA channel of the Citrix ADC, this digit specifies the variable x of an LA channel in LA/x notation, where x can range from 1 to 8. For example, if you specify 3 as the LACP key for an LA channel, the interface is bound to the LA channel LA/3.
        For an LA channel of a cluster configuration, this digit specifies the variable y of a cluster LA channel in CLA/(y-4) notation, where y can range from 5 to 8. For example, if you specify 6 as the LACP key for a cluster LA channel, the interface is bound to the cluster LA channel CLA/2.
    .PARAMETER Lagtype
        Type of entity (Citrix ADC or cluster configuration) for which to create the channel.
        Possible values = NODE, CLUSTER
    .PARAMETER Lacppriority
        LACP port priority, expressed as an integer. The lower the number, the higher the priority. The Citrix ADC limits the number of interfaces in an LA channel to sixteen.
    .PARAMETER Lacptimeout
        Interval at which the Citrix ADC sends LACPDU messages to the peer device on the LA channel.
        Available settings function as follows:
        LONG - 30 seconds.
        SHORT - 1 second.
        Possible values = LONG, SHORT
    .PARAMETER Ifalias
        Alias name for the interface. Used only to enhance readability. To perform any operations, you have to specify the interface ID.
    .PARAMETER Throughput
        Low threshold value for the throughput of the interface, in Mbps. In an HA configuration, failover is triggered if the interface has HA MON enabled and the throughput is below the specified the threshold.
    .PARAMETER Linkredundancy
        Link Redundancy for Cluster LAG.
        Possible values = ON, OFF
    .PARAMETER Bandwidthhigh
        High threshold value for the bandwidth usage of the interface, in Mbps. The Citrix ADC generates an SNMP trap message when the bandwidth usage of the interface is greater than or equal to the specified high threshold value.
    .PARAMETER Bandwidthnormal
        Normal threshold value for the bandwidth usage of the interface, in Mbps. When the bandwidth usage of the interface becomes less than or equal to the specified normal threshold after exceeding the high threshold, the Citrix ADC generates an SNMP trap message to indicate that the bandwidth usage has returned to normal.
    .PARAMETER Lldpmode
        Link Layer Discovery Protocol (LLDP) mode for an interface. The resultant LLDP mode of an interface depends on the LLDP mode configured at the global and the interface levels.
        Possible values = NONE, TRANSMITTER, RECEIVER, TRANSCEIVER
    .PARAMETER Lrsetpriority
        LRSET port priority, expressed as an integer ranging from 1 to 1024. The highest priority is 1. The Citrix ADC limits the number of interfaces in an LRSET to 8. Within a LRSET the highest LR Priority Interface is considered as the first candidate for the Active interface, if the interface is UP.
    .PARAMETER PassThru
        Return details about the created interface item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateInterface -id <string>
        An example how to update Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [ValidateSet('AUTO', '10', '100', '1000', '10000', '25000', '40000', '50000', '100000')]
        [string]$Speed,

        [ValidateSet('AUTO', 'HALF', 'FULL')]
        [string]$Duplex,

        [ValidateSet('OFF', 'RX', 'TX', 'RXTX', 'ON')]
        [string]$Flowctl,

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Autoneg,

        [ValidateSet('ON', 'OFF')]
        [string]$Hamonitor,

        [ValidateSet('OFF', 'ON')]
        [string]$Haheartbeat,

        [ValidateRange(1500, 9216)]
        [double]$Mtu,

        [ValidateRange(512, 16384)]
        [double]$Ringsize,

        [ValidateSet('Elastic', 'Fixed')]
        [string]$Ringtype,

        [ValidateSet('ON', 'OFF')]
        [string]$Tagall,

        [ValidateSet('ON', 'OFF')]
        [string]$Trunk,

        [ValidateSet('ON', 'OFF')]
        [string]$Trunkmode,

        [ValidateLength(1, 4094)]
        [string[]]$Trunkallowedvlan,

        [ValidateSet('DISABLED', 'ACTIVE', 'PASSIVE')]
        [string]$Lacpmode,

        [ValidateRange(1, 8)]
        [double]$Lacpkey,

        [ValidateSet('NODE', 'CLUSTER')]
        [string]$Lagtype,

        [ValidateRange(1, 65535)]
        [double]$Lacppriority,

        [ValidateSet('LONG', 'SHORT')]
        [string]$Lacptimeout,

        [string]$Ifalias,

        [ValidateRange(0, 160000)]
        [double]$Throughput,

        [ValidateSet('ON', 'OFF')]
        [string]$Linkredundancy,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthhigh,

        [ValidateRange(0, 160000)]
        [double]$Bandwidthnormal,

        [ValidateSet('NONE', 'TRANSMITTER', 'RECEIVER', 'TRANSCEIVER')]
        [string]$Lldpmode,

        [ValidateRange(1, 1024)]
        [double]$Lrsetpriority,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('speed') ) { $payload.Add('speed', $speed) }
            if ( $PSBoundParameters.ContainsKey('duplex') ) { $payload.Add('duplex', $duplex) }
            if ( $PSBoundParameters.ContainsKey('flowctl') ) { $payload.Add('flowctl', $flowctl) }
            if ( $PSBoundParameters.ContainsKey('autoneg') ) { $payload.Add('autoneg', $autoneg) }
            if ( $PSBoundParameters.ContainsKey('hamonitor') ) { $payload.Add('hamonitor', $hamonitor) }
            if ( $PSBoundParameters.ContainsKey('haheartbeat') ) { $payload.Add('haheartbeat', $haheartbeat) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('ringsize') ) { $payload.Add('ringsize', $ringsize) }
            if ( $PSBoundParameters.ContainsKey('ringtype') ) { $payload.Add('ringtype', $ringtype) }
            if ( $PSBoundParameters.ContainsKey('tagall') ) { $payload.Add('tagall', $tagall) }
            if ( $PSBoundParameters.ContainsKey('trunk') ) { $payload.Add('trunk', $trunk) }
            if ( $PSBoundParameters.ContainsKey('trunkmode') ) { $payload.Add('trunkmode', $trunkmode) }
            if ( $PSBoundParameters.ContainsKey('trunkallowedvlan') ) { $payload.Add('trunkallowedvlan', $trunkallowedvlan) }
            if ( $PSBoundParameters.ContainsKey('lacpmode') ) { $payload.Add('lacpmode', $lacpmode) }
            if ( $PSBoundParameters.ContainsKey('lacpkey') ) { $payload.Add('lacpkey', $lacpkey) }
            if ( $PSBoundParameters.ContainsKey('lagtype') ) { $payload.Add('lagtype', $lagtype) }
            if ( $PSBoundParameters.ContainsKey('lacppriority') ) { $payload.Add('lacppriority', $lacppriority) }
            if ( $PSBoundParameters.ContainsKey('lacptimeout') ) { $payload.Add('lacptimeout', $lacptimeout) }
            if ( $PSBoundParameters.ContainsKey('ifalias') ) { $payload.Add('ifalias', $ifalias) }
            if ( $PSBoundParameters.ContainsKey('throughput') ) { $payload.Add('throughput', $throughput) }
            if ( $PSBoundParameters.ContainsKey('linkredundancy') ) { $payload.Add('linkredundancy', $linkredundancy) }
            if ( $PSBoundParameters.ContainsKey('bandwidthhigh') ) { $payload.Add('bandwidthhigh', $bandwidthhigh) }
            if ( $PSBoundParameters.ContainsKey('bandwidthnormal') ) { $payload.Add('bandwidthnormal', $bandwidthnormal) }
            if ( $PSBoundParameters.ContainsKey('lldpmode') ) { $payload.Add('lldpmode', $lldpmode) }
            if ( $PSBoundParameters.ContainsKey('lrsetpriority') ) { $payload.Add('lrsetpriority', $lrsetpriority) }
            if ( $PSCmdlet.ShouldProcess("interface", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type interface -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetInterface -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateInterface: Finished"
    }
}

function Invoke-ADCUnsetInterface {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .PARAMETER Speed
        Ethernet speed of the interface, in Mbps.
        Notes:
        * If you set the speed as AUTO, the Citrix ADC attempts to auto-negotiate or auto-sense the link speed of the interface when it is UP. You must enable auto negotiation on the interface.
        * If you set a speed other than AUTO, you must specify the same speed for the peer network device. Mismatched speed and duplex settings between the peer devices of a link lead to link errors, packet loss, and other errors.
        Some interfaces do not support certain speeds. If you specify an unsupported speed, an error message appears.
        Possible values = AUTO, 10, 100, 1000, 10000, 25000, 40000, 50000, 100000
    .PARAMETER Duplex
        The duplex mode for the interface. Notes:* If you set the duplex mode to AUTO, the Citrix ADC attempts to auto-negotiate the duplex mode of the interface when it is UP. You must enable auto negotiation on the interface. If you set a duplex mode other than AUTO, you must specify the same duplex mode for the peer network device. Mismatched speed and duplex settings between the peer devices of a link lead to link errors, packet loss, and other errors.
        Possible values = AUTO, HALF, FULL
    .PARAMETER Flowctl
        802.3x flow control setting for the interface. The 802.3x specification does not define flow control for 10 Mbps and 100 Mbps speeds, but if a Gigabit Ethernet interface operates at those speeds, the flow control settings can be applied. The flow control setting that is finally applied to an interface depends on auto-negotiation. With the ON option, the peer negotiates the flow control, but the appliance then forces two-way flow control for the interface.
        Possible values = OFF, RX, TX, RXTX, ON
    .PARAMETER Autoneg
        Auto-negotiation state of the interface. With the ENABLED setting, the Citrix ADC auto-negotiates the speed and duplex settings with the peer network device on the link. The Citrix ADC appliance auto-negotiates the settings of only those parameters (speed or duplex mode) for which the value is set as AUTO.
        Possible values = DISABLED, ENABLED
    .PARAMETER Hamonitor
        In a High Availability (HA) configuration, monitor the interface for failure events. In an HA configuration, an interface that has HA MON enabled and is not bound to any Failover Interface Set (FIS), is a critical interface. Failure or disabling of any critical interface triggers HA failover.
        Possible values = ON, OFF
    .PARAMETER Haheartbeat
        In a High Availability (HA) or Cluster configuration, configure the interface for sending heartbeats. In an HA or Cluster configuration, an interface that has HA Heartbeat disabled should not send the heartbeats.
        Possible values = OFF, ON
    .PARAMETER Mtu
        The Maximum Transmission Unit (MTU) is the largest packet size, measured in bytes excluding 14 bytes ethernet header and 4 bytes CRC, that can be transmitted and received by an interface. The default value of MTU is 1500 on all the interface of Citrix ADC, some Cloud Platforms will restrict Citrix ADC to use the lesser default value. Any MTU value more than 1500 is called Jumbo MTU and will make the interface as jumbo enabled. The Maximum Jumbo MTU in Citrix ADC is 9216, however, some Virtualized / Cloud Platforms will have lesser Maximum Jumbo MTU Value (9000). In the case of Cluster, the Backplane interface requires an MTU value of 78 bytes more than the Max MTU configured on any other Data-Plane Interface. When the Data plane interfaces are all at default 1500 MTU, Cluster Back Plane will be automatically set to 1578 (1500 + 78) MTU. If a Backplane interface is reset to Data Plane Interface, then the 1578 MTU will be automatically reset to the default MTU of 1500(or whatever lesser default value). If any data plane interface of a Cluster is configured with a Jumbo MTU ( > 1500), then all backplane interfaces require to be configured with a minimum MTU of 'Highest Data Plane MTU in the Cluster + 78'. That makes the maximum Jumbo MTU for any Data-Plane Interface in a Cluster System to be '9138 (9216 - 78)., where 9216 is the maximum Jumbo MTU. On certain Virtualized / Cloud Platforms, the maximum possible MTU is restricted to a lesser value, Similar calculation can be applied, Maximum Data Plane MTU in Cluster = (Maximum possible MTU - 78).
    .PARAMETER Ringsize
        The receive ringsize of the interface. A higher number provides more number of buffers in handling incoming traffic.
    .PARAMETER Ringtype
        The receive ringtype of the interface (Fixed or Elastic). A fixed ring type pre-allocates configured number of buffers irrespective of traffic rate. In contrast, an elastic ring, expands and shrinks based on incoming traffic rate.
        Possible values = Elastic, Fixed
    .PARAMETER Tagall
        Add a four-byte 802.1q tag to every packet sent on this interface. The ON setting applies the tag for this interface's native VLAN. OFF applies the tag for all VLANs other than the native VLAN.
        Possible values = ON, OFF
    .PARAMETER Trunk
        This argument is deprecated by tagall.
        Possible values = ON, OFF
    .PARAMETER Trunkmode
        Accept and send 802.1q VLAN tagged packets, based on Allowed Vlan List of this interface.
        Possible values = ON, OFF
    .PARAMETER Trunkallowedvlan
        VLAN ID or range of VLAN IDs will be allowed on this trunk interface. In the command line interface, separate the range with a hyphen. For example: 40-90.
    .PARAMETER Lacpmode
        Bind the interface to a LA channel created by the Link Aggregation control protocol (LACP).
        Available settings function as follows:
        * Active - The LA channel port of the Citrix ADC generates LACPDU messages on a regular basis, regardless of any need expressed by its peer device to receive them.
        * Passive - The LA channel port of the Citrix ADC does not transmit LACPDU messages unless the peer device port is in the active mode. That is, the port does not speak unless spoken to.
        * Disabled - Unbinds the interface from the LA channel. If this is the only interface in the LA channel, the LA channel is removed.
        Possible values = DISABLED, ACTIVE, PASSIVE
    .PARAMETER Lacppriority
        LACP port priority, expressed as an integer. The lower the number, the higher the priority. The Citrix ADC limits the number of interfaces in an LA channel to sixteen.
    .PARAMETER Lacptimeout
        Interval at which the Citrix ADC sends LACPDU messages to the peer device on the LA channel.
        Available settings function as follows:
        LONG - 30 seconds.
        SHORT - 1 second.
        Possible values = LONG, SHORT
    .PARAMETER Ifalias
        Alias name for the interface. Used only to enhance readability. To perform any operations, you have to specify the interface ID.
    .PARAMETER Throughput
        Low threshold value for the throughput of the interface, in Mbps. In an HA configuration, failover is triggered if the interface has HA MON enabled and the throughput is below the specified the threshold.
    .PARAMETER Linkredundancy
        Link Redundancy for Cluster LAG.
        Possible values = ON, OFF
    .PARAMETER Bandwidthhigh
        High threshold value for the bandwidth usage of the interface, in Mbps. The Citrix ADC generates an SNMP trap message when the bandwidth usage of the interface is greater than or equal to the specified high threshold value.
    .PARAMETER Bandwidthnormal
        Normal threshold value for the bandwidth usage of the interface, in Mbps. When the bandwidth usage of the interface becomes less than or equal to the specified normal threshold after exceeding the high threshold, the Citrix ADC generates an SNMP trap message to indicate that the bandwidth usage has returned to normal.
    .PARAMETER Lldpmode
        Link Layer Discovery Protocol (LLDP) mode for an interface. The resultant LLDP mode of an interface depends on the LLDP mode configured at the global and the interface levels.
        Possible values = NONE, TRANSMITTER, RECEIVER, TRANSCEIVER
    .PARAMETER Lrsetpriority
        LRSET port priority, expressed as an integer ranging from 1 to 1024. The highest priority is 1. The Citrix ADC limits the number of interfaces in an LRSET to 8. Within a LRSET the highest LR Priority Interface is considered as the first candidate for the Active interface, if the interface is UP.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetInterface -id <string>
        An example how to unset Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Id,

        [Boolean]$speed,

        [Boolean]$duplex,

        [Boolean]$flowctl,

        [Boolean]$autoneg,

        [Boolean]$hamonitor,

        [Boolean]$haheartbeat,

        [Boolean]$mtu,

        [Boolean]$ringsize,

        [Boolean]$ringtype,

        [Boolean]$tagall,

        [Boolean]$trunk,

        [Boolean]$trunkmode,

        [Boolean]$trunkallowedvlan,

        [Boolean]$lacpmode,

        [Boolean]$lacppriority,

        [Boolean]$lacptimeout,

        [Boolean]$ifalias,

        [Boolean]$throughput,

        [Boolean]$linkredundancy,

        [Boolean]$bandwidthhigh,

        [Boolean]$bandwidthnormal,

        [Boolean]$lldpmode,

        [Boolean]$lrsetpriority 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('speed') ) { $payload.Add('speed', $speed) }
            if ( $PSBoundParameters.ContainsKey('duplex') ) { $payload.Add('duplex', $duplex) }
            if ( $PSBoundParameters.ContainsKey('flowctl') ) { $payload.Add('flowctl', $flowctl) }
            if ( $PSBoundParameters.ContainsKey('autoneg') ) { $payload.Add('autoneg', $autoneg) }
            if ( $PSBoundParameters.ContainsKey('hamonitor') ) { $payload.Add('hamonitor', $hamonitor) }
            if ( $PSBoundParameters.ContainsKey('haheartbeat') ) { $payload.Add('haheartbeat', $haheartbeat) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('ringsize') ) { $payload.Add('ringsize', $ringsize) }
            if ( $PSBoundParameters.ContainsKey('ringtype') ) { $payload.Add('ringtype', $ringtype) }
            if ( $PSBoundParameters.ContainsKey('tagall') ) { $payload.Add('tagall', $tagall) }
            if ( $PSBoundParameters.ContainsKey('trunk') ) { $payload.Add('trunk', $trunk) }
            if ( $PSBoundParameters.ContainsKey('trunkmode') ) { $payload.Add('trunkmode', $trunkmode) }
            if ( $PSBoundParameters.ContainsKey('trunkallowedvlan') ) { $payload.Add('trunkallowedvlan', $trunkallowedvlan) }
            if ( $PSBoundParameters.ContainsKey('lacpmode') ) { $payload.Add('lacpmode', $lacpmode) }
            if ( $PSBoundParameters.ContainsKey('lacppriority') ) { $payload.Add('lacppriority', $lacppriority) }
            if ( $PSBoundParameters.ContainsKey('lacptimeout') ) { $payload.Add('lacptimeout', $lacptimeout) }
            if ( $PSBoundParameters.ContainsKey('ifalias') ) { $payload.Add('ifalias', $ifalias) }
            if ( $PSBoundParameters.ContainsKey('throughput') ) { $payload.Add('throughput', $throughput) }
            if ( $PSBoundParameters.ContainsKey('linkredundancy') ) { $payload.Add('linkredundancy', $linkredundancy) }
            if ( $PSBoundParameters.ContainsKey('bandwidthhigh') ) { $payload.Add('bandwidthhigh', $bandwidthhigh) }
            if ( $PSBoundParameters.ContainsKey('bandwidthnormal') ) { $payload.Add('bandwidthnormal', $bandwidthnormal) }
            if ( $PSBoundParameters.ContainsKey('lldpmode') ) { $payload.Add('lldpmode', $lldpmode) }
            if ( $PSBoundParameters.ContainsKey('lrsetpriority') ) { $payload.Add('lrsetpriority', $lrsetpriority) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type interface -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetInterface: Finished"
    }
}

function Invoke-ADCEnableInterface {
    <#
    .SYNOPSIS
        Enable Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .EXAMPLE
        PS C:\>Invoke-ADCEnableInterface -id <string>
        An example how to enable Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCEnableInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 

    )
    begin {
        Write-Verbose "Invoke-ADCEnableInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }

            if ( $PSCmdlet.ShouldProcess($Name, "Enable Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type interface -Action enable -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCEnableInterface: Finished"
    }
}

function Invoke-ADCDisableInterface {
    <#
    .SYNOPSIS
        Disable Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .EXAMPLE
        PS C:\>Invoke-ADCDisableInterface -id <string>
        An example how to disable Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDisableInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 

    )
    begin {
        Write-Verbose "Invoke-ADCDisableInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }

            if ( $PSCmdlet.ShouldProcess($Name, "Disable Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type interface -Action disable -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDisableInterface: Finished"
    }
}

function Invoke-ADCResetInterface {
    <#
    .SYNOPSIS
        Reset Network configuration Object.
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .EXAMPLE
        PS C:\>Invoke-ADCResetInterface -id <string>
        An example how to reset Interface configuration Object(s).
    .NOTES
        File Name : Invoke-ADCResetInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 

    )
    begin {
        Write-Verbose "Invoke-ADCResetInterface: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }

            if ( $PSCmdlet.ShouldProcess($Name, "Reset Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type interface -Action reset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCResetInterface: Finished"
    }
}

function Invoke-ADCGetInterface {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for interface resource.
    .PARAMETER Id
        Interface number, in C/U format, where C can take one of the following values:
        * 0 - Indicates a management interface.
        * 1 - Indicates a 1 Gbps port.
        * 10 - Indicates a 10 Gbps port.
        * LA - Indicates a link aggregation port.
        * LO - Indicates a loop back port.
        U is a unique integer for representing an interface in a particular port group.
    .PARAMETER GetAll
        Retrieve all Interface object(s).
    .PARAMETER Count
        If specified, the count of the Interface object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterface
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterface -GetAll
        Get all Interface data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterface -Count
        Get the number of Interface objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterface -name <string>
        Get Interface object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterface -Filter @{ 'name'='<value>' }
        Get Interface data with a filter.
    .NOTES
        File Name : Invoke-ADCGetInterface
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/Interface/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetInterface: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all Interface objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type Interface -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for Interface objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type Interface -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving Interface objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type Interface -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving Interface configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type Interface -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving Interface configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type Interface -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetInterface: Ended"
    }
}

function Invoke-ADCAddInterfacepair {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for "Interface Pair" resource.
    .PARAMETER Id
        The Interface pair id.
    .PARAMETER Ifnum
        The constituent interfaces in the interface pair.
    .PARAMETER PassThru
        Return details about the created interfacepair item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddInterfacepair -id <double> -ifnum <string[]>
        An example how to add interfacepair configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddInterfacepair
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/interfacepair/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string[]]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddInterfacepair: Starting"
    }
    process {
        try {
            $payload = @{ id = $id
                ifnum        = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("interfacepair", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type interfacepair -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetInterfacepair -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddInterfacepair: Finished"
    }
}

function Invoke-ADCDeleteInterfacepair {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for "Interface Pair" resource.
    .PARAMETER Id
        The Interface pair id.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteInterfacepair -Id <double>
        An example how to delete interfacepair configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteInterfacepair
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/interfacepair/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteInterfacepair: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type interfacepair -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteInterfacepair: Finished"
    }
}

function Invoke-ADCGetInterfacepair {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for "Interface Pair" resource.
    .PARAMETER Id
        The Interface pair id.
    .PARAMETER GetAll
        Retrieve all interfacepair object(s).
    .PARAMETER Count
        If specified, the count of the interfacepair object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterfacepair
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterfacepair -GetAll
        Get all interfacepair data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterfacepair -Count
        Get the number of interfacepair objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterfacepair -name <string>
        Get interfacepair object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetInterfacepair -Filter @{ 'name'='<value>' }
        Get interfacepair data with a filter.
    .NOTES
        File Name : Invoke-ADCGetInterfacepair
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/interfacepair/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetInterfacepair: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all interfacepair objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type interfacepair -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for interfacepair objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type interfacepair -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving interfacepair objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type interfacepair -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving interfacepair configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type interfacepair -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving interfacepair configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type interfacepair -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetInterfacepair: Ended"
    }
}

function Invoke-ADCAddIp6tunnel {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for ip6 Tunnel resource.
    .PARAMETER Name
        Name for the IPv6 Tunnel. Cannot be changed after the service group is created. Must begin with a number or letter, and can consist of letters, numbers, and the @ _ - . (period) : (colon) # and space ( ) characters.
    .PARAMETER Remote
        An IPv6 address of the remote Citrix ADC used to set up the tunnel.
    .PARAMETER Local
        An IPv6 address of the local Citrix ADC used to set up the tunnel.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for the tunnel.
    .PARAMETER PassThru
        Return details about the created ip6tunnel item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddIp6tunnel -name <string> -remote <string> -local <string>
        An example how to add ip6tunnel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddIp6tunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateLength(1, 31)]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Remote,

        [Parameter(Mandatory)]
        [string]$Local,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddIp6tunnel: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                remote         = $remote
                local          = $local
            }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("ip6tunnel", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type ip6tunnel -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIp6tunnel -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddIp6tunnel: Finished"
    }
}

function Invoke-ADCDeleteIp6tunnel {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for ip6 Tunnel resource.
    .PARAMETER Name
        Name for the IPv6 Tunnel. Cannot be changed after the service group is created. Must begin with a number or letter, and can consist of letters, numbers, and the @ _ - . (period) : (colon) # and space ( ) characters.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteIp6tunnel -Name <string>
        An example how to delete ip6tunnel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteIp6tunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteIp6tunnel: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type ip6tunnel -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteIp6tunnel: Finished"
    }
}

function Invoke-ADCGetIp6tunnel {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for ip6 Tunnel resource.
    .PARAMETER Name
        Name for the IPv6 Tunnel. Cannot be changed after the service group is created. Must begin with a number or letter, and can consist of letters, numbers, and the @ _ - . (period) : (colon) # and space ( ) characters.
    .PARAMETER GetAll
        Retrieve all ip6tunnel object(s).
    .PARAMETER Count
        If specified, the count of the ip6tunnel object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnel
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnel -GetAll
        Get all ip6tunnel data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnel -Count
        Get the number of ip6tunnel objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnel -name <string>
        Get ip6tunnel object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnel -Filter @{ 'name'='<value>' }
        Get ip6tunnel data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIp6tunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateLength(1, 31)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetIp6tunnel: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ip6tunnel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ip6tunnel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ip6tunnel objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnel -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ip6tunnel configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnel -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ip6tunnel configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnel -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIp6tunnel: Ended"
    }
}

function Invoke-ADCUpdateIp6tunnelparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for ip6 tunnel parameter resource.
    .PARAMETER Srcip
        Common source IPv6 address for all IPv6 tunnels. Must be a SNIP6 or VIP6 address.
    .PARAMETER Dropfrag
        Drop any packet that requires fragmentation.
        Possible values = YES, NO
    .PARAMETER Dropfragcputhreshold
        Threshold value, as a percentage of CPU usage, at which to drop packets that require fragmentation. Applies only if dropFragparameter is set to NO.
    .PARAMETER Srciproundrobin
        Use a different source IPv6 address for each new session through a particular IPv6 tunnel, as determined by round robin selection of one of the SNIP6 addresses. This setting is ignored if a common global source IPv6 address has been specified for all the IPv6 tunnels. This setting does not apply to a tunnel for which a source IPv6 address has been specified.
        Possible values = YES, NO
    .PARAMETER Useclientsourceipv6
        Use client source IPv6 address as source IPv6 address for outer tunnel IPv6 header.
        Possible values = YES, NO
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateIp6tunnelparam
        An example how to update ip6tunnelparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateIp6tunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnelparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Srcip,

        [ValidateSet('YES', 'NO')]
        [string]$Dropfrag,

        [ValidateRange(1, 100)]
        [double]$Dropfragcputhreshold,

        [ValidateSet('YES', 'NO')]
        [string]$Srciproundrobin,

        [ValidateSet('YES', 'NO')]
        [string]$Useclientsourceipv6 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateIp6tunnelparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('dropfrag') ) { $payload.Add('dropfrag', $dropfrag) }
            if ( $PSBoundParameters.ContainsKey('dropfragcputhreshold') ) { $payload.Add('dropfragcputhreshold', $dropfragcputhreshold) }
            if ( $PSBoundParameters.ContainsKey('srciproundrobin') ) { $payload.Add('srciproundrobin', $srciproundrobin) }
            if ( $PSBoundParameters.ContainsKey('useclientsourceipv6') ) { $payload.Add('useclientsourceipv6', $useclientsourceipv6) }
            if ( $PSCmdlet.ShouldProcess("ip6tunnelparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type ip6tunnelparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateIp6tunnelparam: Finished"
    }
}

function Invoke-ADCUnsetIp6tunnelparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for ip6 tunnel parameter resource.
    .PARAMETER Srcip
        Common source IPv6 address for all IPv6 tunnels. Must be a SNIP6 or VIP6 address.
    .PARAMETER Dropfrag
        Drop any packet that requires fragmentation.
        Possible values = YES, NO
    .PARAMETER Dropfragcputhreshold
        Threshold value, as a percentage of CPU usage, at which to drop packets that require fragmentation. Applies only if dropFragparameter is set to NO.
    .PARAMETER Srciproundrobin
        Use a different source IPv6 address for each new session through a particular IPv6 tunnel, as determined by round robin selection of one of the SNIP6 addresses. This setting is ignored if a common global source IPv6 address has been specified for all the IPv6 tunnels. This setting does not apply to a tunnel for which a source IPv6 address has been specified.
        Possible values = YES, NO
    .PARAMETER Useclientsourceipv6
        Use client source IPv6 address as source IPv6 address for outer tunnel IPv6 header.
        Possible values = YES, NO
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetIp6tunnelparam
        An example how to unset ip6tunnelparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetIp6tunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnelparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$srcip,

        [Boolean]$dropfrag,

        [Boolean]$dropfragcputhreshold,

        [Boolean]$srciproundrobin,

        [Boolean]$useclientsourceipv6 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetIp6tunnelparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('dropfrag') ) { $payload.Add('dropfrag', $dropfrag) }
            if ( $PSBoundParameters.ContainsKey('dropfragcputhreshold') ) { $payload.Add('dropfragcputhreshold', $dropfragcputhreshold) }
            if ( $PSBoundParameters.ContainsKey('srciproundrobin') ) { $payload.Add('srciproundrobin', $srciproundrobin) }
            if ( $PSBoundParameters.ContainsKey('useclientsourceipv6') ) { $payload.Add('useclientsourceipv6', $useclientsourceipv6) }
            if ( $PSCmdlet.ShouldProcess("ip6tunnelparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type ip6tunnelparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetIp6tunnelparam: Finished"
    }
}

function Invoke-ADCGetIp6tunnelparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for ip6 tunnel parameter resource.
    .PARAMETER GetAll
        Retrieve all ip6tunnelparam object(s).
    .PARAMETER Count
        If specified, the count of the ip6tunnelparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnelparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnelparam -GetAll
        Get all ip6tunnelparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnelparam -name <string>
        Get ip6tunnelparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIp6tunnelparam -Filter @{ 'name'='<value>' }
        Get ip6tunnelparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIp6tunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ip6tunnelparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetIp6tunnelparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ip6tunnelparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnelparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ip6tunnelparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnelparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ip6tunnelparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnelparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ip6tunnelparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving ip6tunnelparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ip6tunnelparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIp6tunnelparam: Ended"
    }
}

function Invoke-ADCAddIpset {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for network ipset resource.
    .PARAMETER Name
        Name for the IP set. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the IP set is created. Choose a name that helps identify the IP set.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER PassThru
        Return details about the created ipset item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddIpset -name <string>
        An example how to add ipset configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddIpset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddIpset: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSCmdlet.ShouldProcess("ipset", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type ipset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIpset -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddIpset: Finished"
    }
}

function Invoke-ADCDeleteIpset {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for network ipset resource.
    .PARAMETER Name
        Name for the IP set. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the IP set is created. Choose a name that helps identify the IP set.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteIpset -Name <string>
        An example how to delete ipset configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteIpset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteIpset: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type ipset -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteIpset: Finished"
    }
}

function Invoke-ADCGetIpset {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for network ipset resource.
    .PARAMETER Name
        Name for the IP set. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the IP set is created. Choose a name that helps identify the IP set.
    .PARAMETER GetAll
        Retrieve all ipset object(s).
    .PARAMETER Count
        If specified, the count of the ipset object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpset
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpset -GetAll
        Get all ipset data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpset -Count
        Get the number of ipset objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpset -name <string>
        Get ipset object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpset -Filter @{ 'name'='<value>' }
        Get ipset data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIpset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetIpset: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ipset objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ipset objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ipset objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ipset configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ipset configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIpset: Ended"
    }
}

function Invoke-ADCGetIpsetbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to ipset.
    .PARAMETER Name
        Name of the IP set whose details you want to display.
    .PARAMETER GetAll
        Retrieve all ipset_binding object(s).
    .PARAMETER Count
        If specified, the count of the ipset_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetbinding -GetAll
        Get all ipset_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetbinding -name <string>
        Get ipset_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetbinding -Filter @{ 'name'='<value>' }
        Get ipset_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIpsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetIpsetbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all ipset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ipset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ipset_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ipset_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ipset_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIpsetbinding: Ended"
    }
}

function Invoke-ADCAddIpsetnsip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER Ipaddress
        One or more IP addresses bound to the IP set.
    .PARAMETER PassThru
        Return details about the created ipset_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddIpsetnsip6binding -name <string> -ipaddress <string>
        An example how to add ipset_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddIpsetnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddIpsetnsip6binding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                ipaddress      = $ipaddress
            }

            if ( $PSCmdlet.ShouldProcess("ipset_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type ipset_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIpsetnsip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddIpsetnsip6binding: Finished"
    }
}

function Invoke-ADCDeleteIpsetnsip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER Ipaddress
        One or more IP addresses bound to the IP set.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteIpsetnsip6binding -Name <string>
        An example how to delete ipset_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteIpsetnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ipaddress 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteIpsetnsip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteIpsetnsip6binding: Finished"
    }
}

function Invoke-ADCGetIpsetnsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER GetAll
        Retrieve all ipset_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the ipset_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsip6binding -GetAll
        Get all ipset_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsip6binding -Count
        Get the number of ipset_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsip6binding -name <string>
        Get ipset_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsip6binding -Filter @{ 'name'='<value>' }
        Get ipset_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIpsetnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetIpsetnsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all ipset_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ipset_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ipset_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ipset_nsip6_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ipset_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIpsetnsip6binding: Ended"
    }
}

function Invoke-ADCAddIpsetnsipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER Ipaddress
        One or more IP addresses bound to the IP set.
    .PARAMETER PassThru
        Return details about the created ipset_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddIpsetnsipbinding -name <string> -ipaddress <string>
        An example how to add ipset_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddIpsetnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddIpsetnsipbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                ipaddress      = $ipaddress
            }

            if ( $PSCmdlet.ShouldProcess("ipset_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type ipset_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIpsetnsipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddIpsetnsipbinding: Finished"
    }
}

function Invoke-ADCDeleteIpsetnsipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER Ipaddress
        One or more IP addresses bound to the IP set.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteIpsetnsipbinding -Name <string>
        An example how to delete ipset_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteIpsetnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ipaddress 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteIpsetnsipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type ipset_nsip_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteIpsetnsipbinding: Finished"
    }
}

function Invoke-ADCGetIpsetnsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to ipset.
    .PARAMETER Name
        Name of the IP set to which to bind IP addresses.
    .PARAMETER GetAll
        Retrieve all ipset_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the ipset_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsipbinding -GetAll
        Get all ipset_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsipbinding -Count
        Get the number of ipset_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsipbinding -name <string>
        Get ipset_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpsetnsipbinding -Filter @{ 'name'='<value>' }
        Get ipset_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIpsetnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipset_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetIpsetnsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all ipset_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ipset_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ipset_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ipset_nsip_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ipset_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipset_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIpsetnsipbinding: Ended"
    }
}

function Invoke-ADCAddIptunnel {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for ip Tunnel resource.
    .PARAMETER Name
        Name for the IP tunnel. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER Remote
        Public IPv4 address, of the remote device, used to set up the tunnel. For this parameter, you can alternatively specify a network address.
    .PARAMETER Remotesubnetmask
        Subnet mask of the remote IP address of the tunnel.
    .PARAMETER Local
        Type of Citrix ADC owned public IPv4 address, configured on the local Citrix ADC and used to set up the tunnel.
    .PARAMETER Protocol
        Name of the protocol to be used on this tunnel.
        Possible values = IPIP, GRE, IPSEC, UDP
    .PARAMETER Grepayload
        The payload GRE will carry.
        Possible values = ETHERNETwithDOT1Q, ETHERNET, IP
    .PARAMETER Ipsecprofilename
        Name of IPSec profile to be associated.
    .PARAMETER Vlan
        The vlan for mulicast packets.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for the iptunnel.
    .PARAMETER PassThru
        Return details about the created iptunnel item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddIptunnel -name <string> -remote <string> -remotesubnetmask <string> -local <string>
        An example how to add iptunnel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddIptunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Remote,

        [Parameter(Mandatory)]
        [string]$Remotesubnetmask,

        [Parameter(Mandatory)]
        [string]$Local,

        [ValidateSet('IPIP', 'GRE', 'IPSEC', 'UDP')]
        [string]$Protocol = 'IPIP',

        [ValidateSet('ETHERNETwithDOT1Q', 'ETHERNET', 'IP')]
        [string]$Grepayload = 'ETHERNETwithDOT1Q',

        [string]$Ipsecprofilename = '"ns_ipsec_default_profile"',

        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddIptunnel: Starting"
    }
    process {
        try {
            $payload = @{ name   = $name
                remote           = $remote
                remotesubnetmask = $remotesubnetmask
                local            = $local
            }
            if ( $PSBoundParameters.ContainsKey('protocol') ) { $payload.Add('protocol', $protocol) }
            if ( $PSBoundParameters.ContainsKey('grepayload') ) { $payload.Add('grepayload', $grepayload) }
            if ( $PSBoundParameters.ContainsKey('ipsecprofilename') ) { $payload.Add('ipsecprofilename', $ipsecprofilename) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("iptunnel", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type iptunnel -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIptunnel -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddIptunnel: Finished"
    }
}

function Invoke-ADCDeleteIptunnel {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for ip Tunnel resource.
    .PARAMETER Name
        Name for the IP tunnel. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteIptunnel -Name <string>
        An example how to delete iptunnel configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteIptunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteIptunnel: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type iptunnel -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteIptunnel: Finished"
    }
}

function Invoke-ADCGetIptunnel {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for ip Tunnel resource.
    .PARAMETER Name
        Name for the IP tunnel. Leading character must be a number or letter. Other characters allowed, after the first character, are @ _ - . (period) : (colon) # and space ( ).
    .PARAMETER GetAll
        Retrieve all iptunnel object(s).
    .PARAMETER Count
        If specified, the count of the iptunnel object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnel
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnel -GetAll
        Get all iptunnel data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnel -Count
        Get the number of iptunnel objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnel -name <string>
        Get iptunnel object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnel -Filter @{ 'name'='<value>' }
        Get iptunnel data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIptunnel
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnel/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetIptunnel: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all iptunnel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for iptunnel objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnel -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving iptunnel objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnel -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving iptunnel configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnel -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving iptunnel configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnel -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIptunnel: Ended"
    }
}

function Invoke-ADCUpdateIptunnelparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for ip tunnel parameter resource.
    .PARAMETER Srcip
        Common source-IP address for all tunnels. For a specific tunnel, this global setting is overridden if you have specified another source IP address. Must be a MIP or SNIP address.
    .PARAMETER Dropfrag
        Drop any IP packet that requires fragmentation before it is sent through the tunnel.
        Possible values = YES, NO
    .PARAMETER Dropfragcputhreshold
        Threshold value, as a percentage of CPU usage, at which to drop packets that require fragmentation to use the IP tunnel. Applies only if dropFragparameter is set to NO. The default value, 0, specifies that this parameter is not set.
    .PARAMETER Srciproundrobin
        Use a different source IP address for each new session through a particular IP tunnel, as determined by round robin selection of one of the SNIP addresses. This setting is ignored if a common global source IP address has been specified for all the IP tunnels. This setting does not apply to a tunnel for which a source IP address has been specified.
        Possible values = YES, NO
    .PARAMETER Enablestrictrx
        Strict PBR check for IPSec packets received through tunnel.
        Possible values = YES, NO
    .PARAMETER Enablestricttx
        Strict PBR check for packets to be sent IPSec protected.
        Possible values = YES, NO
    .PARAMETER Mac
        The shared MAC used for shared IP between cluster nodes/HA peers.
    .PARAMETER Useclientsourceip
        Use client source IP as source IP for outer tunnel IP header.
        Possible values = YES, NO
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateIptunnelparam
        An example how to update iptunnelparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateIptunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnelparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Srcip,

        [ValidateSet('YES', 'NO')]
        [string]$Dropfrag,

        [ValidateRange(1, 100)]
        [double]$Dropfragcputhreshold,

        [ValidateSet('YES', 'NO')]
        [string]$Srciproundrobin,

        [ValidateSet('YES', 'NO')]
        [string]$Enablestrictrx,

        [ValidateSet('YES', 'NO')]
        [string]$Enablestricttx,

        [string]$Mac,

        [ValidateSet('YES', 'NO')]
        [string]$Useclientsourceip 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateIptunnelparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('dropfrag') ) { $payload.Add('dropfrag', $dropfrag) }
            if ( $PSBoundParameters.ContainsKey('dropfragcputhreshold') ) { $payload.Add('dropfragcputhreshold', $dropfragcputhreshold) }
            if ( $PSBoundParameters.ContainsKey('srciproundrobin') ) { $payload.Add('srciproundrobin', $srciproundrobin) }
            if ( $PSBoundParameters.ContainsKey('enablestrictrx') ) { $payload.Add('enablestrictrx', $enablestrictrx) }
            if ( $PSBoundParameters.ContainsKey('enablestricttx') ) { $payload.Add('enablestricttx', $enablestricttx) }
            if ( $PSBoundParameters.ContainsKey('mac') ) { $payload.Add('mac', $mac) }
            if ( $PSBoundParameters.ContainsKey('useclientsourceip') ) { $payload.Add('useclientsourceip', $useclientsourceip) }
            if ( $PSCmdlet.ShouldProcess("iptunnelparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type iptunnelparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateIptunnelparam: Finished"
    }
}

function Invoke-ADCUnsetIptunnelparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for ip tunnel parameter resource.
    .PARAMETER Srcip
        Common source-IP address for all tunnels. For a specific tunnel, this global setting is overridden if you have specified another source IP address. Must be a MIP or SNIP address.
    .PARAMETER Dropfrag
        Drop any IP packet that requires fragmentation before it is sent through the tunnel.
        Possible values = YES, NO
    .PARAMETER Dropfragcputhreshold
        Threshold value, as a percentage of CPU usage, at which to drop packets that require fragmentation to use the IP tunnel. Applies only if dropFragparameter is set to NO. The default value, 0, specifies that this parameter is not set.
    .PARAMETER Srciproundrobin
        Use a different source IP address for each new session through a particular IP tunnel, as determined by round robin selection of one of the SNIP addresses. This setting is ignored if a common global source IP address has been specified for all the IP tunnels. This setting does not apply to a tunnel for which a source IP address has been specified.
        Possible values = YES, NO
    .PARAMETER Enablestrictrx
        Strict PBR check for IPSec packets received through tunnel.
        Possible values = YES, NO
    .PARAMETER Enablestricttx
        Strict PBR check for packets to be sent IPSec protected.
        Possible values = YES, NO
    .PARAMETER Mac
        The shared MAC used for shared IP between cluster nodes/HA peers.
    .PARAMETER Useclientsourceip
        Use client source IP as source IP for outer tunnel IP header.
        Possible values = YES, NO
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetIptunnelparam
        An example how to unset iptunnelparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetIptunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnelparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$srcip,

        [Boolean]$dropfrag,

        [Boolean]$dropfragcputhreshold,

        [Boolean]$srciproundrobin,

        [Boolean]$enablestrictrx,

        [Boolean]$enablestricttx,

        [Boolean]$mac,

        [Boolean]$useclientsourceip 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetIptunnelparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('dropfrag') ) { $payload.Add('dropfrag', $dropfrag) }
            if ( $PSBoundParameters.ContainsKey('dropfragcputhreshold') ) { $payload.Add('dropfragcputhreshold', $dropfragcputhreshold) }
            if ( $PSBoundParameters.ContainsKey('srciproundrobin') ) { $payload.Add('srciproundrobin', $srciproundrobin) }
            if ( $PSBoundParameters.ContainsKey('enablestrictrx') ) { $payload.Add('enablestrictrx', $enablestrictrx) }
            if ( $PSBoundParameters.ContainsKey('enablestricttx') ) { $payload.Add('enablestricttx', $enablestricttx) }
            if ( $PSBoundParameters.ContainsKey('mac') ) { $payload.Add('mac', $mac) }
            if ( $PSBoundParameters.ContainsKey('useclientsourceip') ) { $payload.Add('useclientsourceip', $useclientsourceip) }
            if ( $PSCmdlet.ShouldProcess("iptunnelparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type iptunnelparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetIptunnelparam: Finished"
    }
}

function Invoke-ADCGetIptunnelparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for ip tunnel parameter resource.
    .PARAMETER GetAll
        Retrieve all iptunnelparam object(s).
    .PARAMETER Count
        If specified, the count of the iptunnelparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnelparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnelparam -GetAll
        Get all iptunnelparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnelparam -name <string>
        Get iptunnelparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIptunnelparam -Filter @{ 'name'='<value>' }
        Get iptunnelparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIptunnelparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/iptunnelparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetIptunnelparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all iptunnelparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnelparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for iptunnelparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnelparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving iptunnelparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnelparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving iptunnelparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving iptunnelparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type iptunnelparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIptunnelparam: Ended"
    }
}

function Invoke-ADCUpdateIpv6 {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for ip v6 resource.
    .PARAMETER Ralearning
        Enable the Citrix ADC to learn about various routes from Router Advertisement (RA) and Router Solicitation (RS) messages sent by the routers.
        Possible values = ENABLED, DISABLED
    .PARAMETER Routerredirection
        Enable the Citrix ADC to do Router Redirection.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ndbasereachtime
        Base reachable time of the Neighbor Discovery (ND6) protocol. The time, in milliseconds, that the Citrix ADC assumes an adjacent device is reachable after receiving a reachability confirmation.
    .PARAMETER Ndretransmissiontime
        Retransmission time of the Neighbor Discovery (ND6) protocol. The time, in milliseconds, between retransmitted Neighbor Solicitation (NS) messages, to an adjacent device.
    .PARAMETER Natprefix
        Prefix used for translating packets from private IPv6 servers to IPv4 packets. This prefix has a length of 96 bits (128-32 = 96). The IPv6 servers embed the destination IP address of the IPv4 servers or hosts in the last 32 bits of the destination IP address field of the IPv6 packets. The first 96 bits of the destination IP address field are set as the IPv6 NAT prefix. IPv6 packets addressed to this prefix have to be routed to the Citrix ADC to ensure that the IPv6-IPv4 translation is done by the appliance.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Dodad
        Enable the Citrix ADC to do Duplicate Address
        Detection (DAD) for all the Citrix ADC owned IPv6 addresses regardless of whether they are obtained through stateless auto configuration, DHCPv6, or manual configuration.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usipnatprefix
        IPV6 NATPREFIX used in NAT46 scenario when USIP is turned on.
    .PARAMETER PassThru
        Return details about the created ipv6 item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateIpv6
        An example how to update ipv6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateIpv6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipv6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ralearning,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Routerredirection,

        [double]$Ndbasereachtime,

        [double]$Ndretransmissiontime,

        [string]$Natprefix,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dodad,

        [string]$Usipnatprefix,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateIpv6: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('ralearning') ) { $payload.Add('ralearning', $ralearning) }
            if ( $PSBoundParameters.ContainsKey('routerredirection') ) { $payload.Add('routerredirection', $routerredirection) }
            if ( $PSBoundParameters.ContainsKey('ndbasereachtime') ) { $payload.Add('ndbasereachtime', $ndbasereachtime) }
            if ( $PSBoundParameters.ContainsKey('ndretransmissiontime') ) { $payload.Add('ndretransmissiontime', $ndretransmissiontime) }
            if ( $PSBoundParameters.ContainsKey('natprefix') ) { $payload.Add('natprefix', $natprefix) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('dodad') ) { $payload.Add('dodad', $dodad) }
            if ( $PSBoundParameters.ContainsKey('usipnatprefix') ) { $payload.Add('usipnatprefix', $usipnatprefix) }
            if ( $PSCmdlet.ShouldProcess("ipv6", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type ipv6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetIpv6 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateIpv6: Finished"
    }
}

function Invoke-ADCUnsetIpv6 {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for ip v6 resource.
    .PARAMETER Ralearning
        Enable the Citrix ADC to learn about various routes from Router Advertisement (RA) and Router Solicitation (RS) messages sent by the routers.
        Possible values = ENABLED, DISABLED
    .PARAMETER Routerredirection
        Enable the Citrix ADC to do Router Redirection.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ndbasereachtime
        Base reachable time of the Neighbor Discovery (ND6) protocol. The time, in milliseconds, that the Citrix ADC assumes an adjacent device is reachable after receiving a reachability confirmation.
    .PARAMETER Ndretransmissiontime
        Retransmission time of the Neighbor Discovery (ND6) protocol. The time, in milliseconds, between retransmitted Neighbor Solicitation (NS) messages, to an adjacent device.
    .PARAMETER Natprefix
        Prefix used for translating packets from private IPv6 servers to IPv4 packets. This prefix has a length of 96 bits (128-32 = 96). The IPv6 servers embed the destination IP address of the IPv4 servers or hosts in the last 32 bits of the destination IP address field of the IPv6 packets. The first 96 bits of the destination IP address field are set as the IPv6 NAT prefix. IPv6 packets addressed to this prefix have to be routed to the Citrix ADC to ensure that the IPv6-IPv4 translation is done by the appliance.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Dodad
        Enable the Citrix ADC to do Duplicate Address
        Detection (DAD) for all the Citrix ADC owned IPv6 addresses regardless of whether they are obtained through stateless auto configuration, DHCPv6, or manual configuration.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usipnatprefix
        IPV6 NATPREFIX used in NAT46 scenario when USIP is turned on.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetIpv6
        An example how to unset ipv6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetIpv6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipv6
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$ralearning,

        [Boolean]$routerredirection,

        [Boolean]$ndbasereachtime,

        [Boolean]$ndretransmissiontime,

        [Boolean]$natprefix,

        [Boolean]$td,

        [Boolean]$dodad,

        [Boolean]$usipnatprefix 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetIpv6: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('ralearning') ) { $payload.Add('ralearning', $ralearning) }
            if ( $PSBoundParameters.ContainsKey('routerredirection') ) { $payload.Add('routerredirection', $routerredirection) }
            if ( $PSBoundParameters.ContainsKey('ndbasereachtime') ) { $payload.Add('ndbasereachtime', $ndbasereachtime) }
            if ( $PSBoundParameters.ContainsKey('ndretransmissiontime') ) { $payload.Add('ndretransmissiontime', $ndretransmissiontime) }
            if ( $PSBoundParameters.ContainsKey('natprefix') ) { $payload.Add('natprefix', $natprefix) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('dodad') ) { $payload.Add('dodad', $dodad) }
            if ( $PSBoundParameters.ContainsKey('usipnatprefix') ) { $payload.Add('usipnatprefix', $usipnatprefix) }
            if ( $PSCmdlet.ShouldProcess("ipv6", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type ipv6 -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetIpv6: Finished"
    }
}

function Invoke-ADCGetIpv6 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for ip v6 resource.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER GetAll
        Retrieve all ipv6 object(s).
    .PARAMETER Count
        If specified, the count of the ipv6 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpv6
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpv6 -GetAll
        Get all ipv6 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpv6 -Count
        Get the number of ipv6 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpv6 -name <string>
        Get ipv6 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetIpv6 -Filter @{ 'name'='<value>' }
        Get ipv6 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetIpv6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ipv6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetIpv6: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ipv6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipv6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ipv6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipv6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ipv6 objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipv6 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ipv6 configuration for property 'td'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipv6 -NitroPath nitro/v1/config -Resource $td -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving ipv6 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ipv6 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetIpv6: Ended"
    }
}

function Invoke-ADCUpdateL2param {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 2 related parameter resource.
    .PARAMETER Mbfpeermacupdate
        When mbf_instant_learning is enabled, learn any changes in peer's MAC after this time interval, which is in 10ms ticks.
    .PARAMETER Maxbridgecollision
        Maximum bridge collision for loop detection .
    .PARAMETER Bdggrpproxyarp
        Set/reset proxy ARP in bridge group deployment.
        Possible values = ENABLED, DISABLED
    .PARAMETER Bdgsetting
        Bridging settings for C2C behavior. If enabled, each PE will learn MAC entries independently. Otherwise, when L2 mode is ON, learned MAC entries on a PE will be broadcasted to all other PEs.
        Possible values = ENABLED, DISABLED
    .PARAMETER Garponvridintf
        Send GARP messagess on VRID-configured interfaces upon failover .
        Possible values = ENABLED, DISABLED
    .PARAMETER Macmodefwdmypkt
        Allows MAC mode vserver to pick and forward the packets even if it is destined to Citrix ADC owned VIP.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usemymac
        Use Citrix ADC MAC for all outgoing packets.
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyarp
        Proxies the ARP as Citrix ADC MAC for FreeBSD.
        Possible values = ENABLED, DISABLED
    .PARAMETER Garpreply
        Set/reset REPLY form of GARP .
        Possible values = ENABLED, DISABLED
    .PARAMETER Mbfinstlearning
        Enable instant learning of MAC changes in MBF mode.
        Possible values = ENABLED, DISABLED
    .PARAMETER Rstintfonhafo
        Enable the reset interface upon HA failover.
        Possible values = ENABLED, DISABLED
    .PARAMETER Skipproxyingbsdtraffic
        Control source parameters (IP and Port) for FreeBSD initiated traffic. If Enabled, source parameters are retained. Else proxy the source parameters based on next hop.
        Possible values = ENABLED, DISABLED
    .PARAMETER Returntoethernetsender
        Return to ethernet sender.
        Possible values = ENABLED, DISABLED
    .PARAMETER Stopmacmoveupdate
        Stop Update of server mac change to NAT sessions.
        Possible values = ENABLED, DISABLED
    .PARAMETER Bridgeagetimeout
        Time-out value for the bridge table entries, in seconds. The new value applies only to the entries that are dynamically learned after the new value is set. Previously existing bridge table entries expire after the previously configured time-out value.
    .PARAMETER Usenetprofilebsdtraffic
        Control source parameters (IP and Port) for FreeBSD initiated traffic. If enabled proxy the source parameters based on netprofile source ip. If netprofile does not have ip configured, then it will continue to use NSIP as earlier.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateL2param
        An example how to update l2param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateL2param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l2param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [double]$Mbfpeermacupdate,

        [double]$Maxbridgecollision,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Bdggrpproxyarp,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Bdgsetting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Garponvridintf,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Macmodefwdmypkt,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Usemymac,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Proxyarp,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Garpreply,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Mbfinstlearning,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Rstintfonhafo,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Skipproxyingbsdtraffic,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Returntoethernetsender,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Stopmacmoveupdate,

        [ValidateRange(60, 300)]
        [double]$Bridgeagetimeout,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Usenetprofilebsdtraffic 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateL2param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('mbfpeermacupdate') ) { $payload.Add('mbfpeermacupdate', $mbfpeermacupdate) }
            if ( $PSBoundParameters.ContainsKey('maxbridgecollision') ) { $payload.Add('maxbridgecollision', $maxbridgecollision) }
            if ( $PSBoundParameters.ContainsKey('bdggrpproxyarp') ) { $payload.Add('bdggrpproxyarp', $bdggrpproxyarp) }
            if ( $PSBoundParameters.ContainsKey('bdgsetting') ) { $payload.Add('bdgsetting', $bdgsetting) }
            if ( $PSBoundParameters.ContainsKey('garponvridintf') ) { $payload.Add('garponvridintf', $garponvridintf) }
            if ( $PSBoundParameters.ContainsKey('macmodefwdmypkt') ) { $payload.Add('macmodefwdmypkt', $macmodefwdmypkt) }
            if ( $PSBoundParameters.ContainsKey('usemymac') ) { $payload.Add('usemymac', $usemymac) }
            if ( $PSBoundParameters.ContainsKey('proxyarp') ) { $payload.Add('proxyarp', $proxyarp) }
            if ( $PSBoundParameters.ContainsKey('garpreply') ) { $payload.Add('garpreply', $garpreply) }
            if ( $PSBoundParameters.ContainsKey('mbfinstlearning') ) { $payload.Add('mbfinstlearning', $mbfinstlearning) }
            if ( $PSBoundParameters.ContainsKey('rstintfonhafo') ) { $payload.Add('rstintfonhafo', $rstintfonhafo) }
            if ( $PSBoundParameters.ContainsKey('skipproxyingbsdtraffic') ) { $payload.Add('skipproxyingbsdtraffic', $skipproxyingbsdtraffic) }
            if ( $PSBoundParameters.ContainsKey('returntoethernetsender') ) { $payload.Add('returntoethernetsender', $returntoethernetsender) }
            if ( $PSBoundParameters.ContainsKey('stopmacmoveupdate') ) { $payload.Add('stopmacmoveupdate', $stopmacmoveupdate) }
            if ( $PSBoundParameters.ContainsKey('bridgeagetimeout') ) { $payload.Add('bridgeagetimeout', $bridgeagetimeout) }
            if ( $PSBoundParameters.ContainsKey('usenetprofilebsdtraffic') ) { $payload.Add('usenetprofilebsdtraffic', $usenetprofilebsdtraffic) }
            if ( $PSCmdlet.ShouldProcess("l2param", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type l2param -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateL2param: Finished"
    }
}

function Invoke-ADCUnsetL2param {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 2 related parameter resource.
    .PARAMETER Mbfpeermacupdate
        When mbf_instant_learning is enabled, learn any changes in peer's MAC after this time interval, which is in 10ms ticks.
    .PARAMETER Maxbridgecollision
        Maximum bridge collision for loop detection .
    .PARAMETER Bdggrpproxyarp
        Set/reset proxy ARP in bridge group deployment.
        Possible values = ENABLED, DISABLED
    .PARAMETER Bdgsetting
        Bridging settings for C2C behavior. If enabled, each PE will learn MAC entries independently. Otherwise, when L2 mode is ON, learned MAC entries on a PE will be broadcasted to all other PEs.
        Possible values = ENABLED, DISABLED
    .PARAMETER Garponvridintf
        Send GARP messagess on VRID-configured interfaces upon failover .
        Possible values = ENABLED, DISABLED
    .PARAMETER Macmodefwdmypkt
        Allows MAC mode vserver to pick and forward the packets even if it is destined to Citrix ADC owned VIP.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usemymac
        Use Citrix ADC MAC for all outgoing packets.
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyarp
        Proxies the ARP as Citrix ADC MAC for FreeBSD.
        Possible values = ENABLED, DISABLED
    .PARAMETER Garpreply
        Set/reset REPLY form of GARP .
        Possible values = ENABLED, DISABLED
    .PARAMETER Mbfinstlearning
        Enable instant learning of MAC changes in MBF mode.
        Possible values = ENABLED, DISABLED
    .PARAMETER Rstintfonhafo
        Enable the reset interface upon HA failover.
        Possible values = ENABLED, DISABLED
    .PARAMETER Skipproxyingbsdtraffic
        Control source parameters (IP and Port) for FreeBSD initiated traffic. If Enabled, source parameters are retained. Else proxy the source parameters based on next hop.
        Possible values = ENABLED, DISABLED
    .PARAMETER Returntoethernetsender
        Return to ethernet sender.
        Possible values = ENABLED, DISABLED
    .PARAMETER Stopmacmoveupdate
        Stop Update of server mac change to NAT sessions.
        Possible values = ENABLED, DISABLED
    .PARAMETER Bridgeagetimeout
        Time-out value for the bridge table entries, in seconds. The new value applies only to the entries that are dynamically learned after the new value is set. Previously existing bridge table entries expire after the previously configured time-out value.
    .PARAMETER Usenetprofilebsdtraffic
        Control source parameters (IP and Port) for FreeBSD initiated traffic. If enabled proxy the source parameters based on netprofile source ip. If netprofile does not have ip configured, then it will continue to use NSIP as earlier.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetL2param
        An example how to unset l2param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetL2param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l2param
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$mbfpeermacupdate,

        [Boolean]$maxbridgecollision,

        [Boolean]$bdggrpproxyarp,

        [Boolean]$bdgsetting,

        [Boolean]$garponvridintf,

        [Boolean]$macmodefwdmypkt,

        [Boolean]$usemymac,

        [Boolean]$proxyarp,

        [Boolean]$garpreply,

        [Boolean]$mbfinstlearning,

        [Boolean]$rstintfonhafo,

        [Boolean]$skipproxyingbsdtraffic,

        [Boolean]$returntoethernetsender,

        [Boolean]$stopmacmoveupdate,

        [Boolean]$bridgeagetimeout,

        [Boolean]$usenetprofilebsdtraffic 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetL2param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('mbfpeermacupdate') ) { $payload.Add('mbfpeermacupdate', $mbfpeermacupdate) }
            if ( $PSBoundParameters.ContainsKey('maxbridgecollision') ) { $payload.Add('maxbridgecollision', $maxbridgecollision) }
            if ( $PSBoundParameters.ContainsKey('bdggrpproxyarp') ) { $payload.Add('bdggrpproxyarp', $bdggrpproxyarp) }
            if ( $PSBoundParameters.ContainsKey('bdgsetting') ) { $payload.Add('bdgsetting', $bdgsetting) }
            if ( $PSBoundParameters.ContainsKey('garponvridintf') ) { $payload.Add('garponvridintf', $garponvridintf) }
            if ( $PSBoundParameters.ContainsKey('macmodefwdmypkt') ) { $payload.Add('macmodefwdmypkt', $macmodefwdmypkt) }
            if ( $PSBoundParameters.ContainsKey('usemymac') ) { $payload.Add('usemymac', $usemymac) }
            if ( $PSBoundParameters.ContainsKey('proxyarp') ) { $payload.Add('proxyarp', $proxyarp) }
            if ( $PSBoundParameters.ContainsKey('garpreply') ) { $payload.Add('garpreply', $garpreply) }
            if ( $PSBoundParameters.ContainsKey('mbfinstlearning') ) { $payload.Add('mbfinstlearning', $mbfinstlearning) }
            if ( $PSBoundParameters.ContainsKey('rstintfonhafo') ) { $payload.Add('rstintfonhafo', $rstintfonhafo) }
            if ( $PSBoundParameters.ContainsKey('skipproxyingbsdtraffic') ) { $payload.Add('skipproxyingbsdtraffic', $skipproxyingbsdtraffic) }
            if ( $PSBoundParameters.ContainsKey('returntoethernetsender') ) { $payload.Add('returntoethernetsender', $returntoethernetsender) }
            if ( $PSBoundParameters.ContainsKey('stopmacmoveupdate') ) { $payload.Add('stopmacmoveupdate', $stopmacmoveupdate) }
            if ( $PSBoundParameters.ContainsKey('bridgeagetimeout') ) { $payload.Add('bridgeagetimeout', $bridgeagetimeout) }
            if ( $PSBoundParameters.ContainsKey('usenetprofilebsdtraffic') ) { $payload.Add('usenetprofilebsdtraffic', $usenetprofilebsdtraffic) }
            if ( $PSCmdlet.ShouldProcess("l2param", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type l2param -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetL2param: Finished"
    }
}

function Invoke-ADCGetL2param {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Layer 2 related parameter resource.
    .PARAMETER GetAll
        Retrieve all l2param object(s).
    .PARAMETER Count
        If specified, the count of the l2param object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL2param
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL2param -GetAll
        Get all l2param data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL2param -name <string>
        Get l2param object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL2param -Filter @{ 'name'='<value>' }
        Get l2param data with a filter.
    .NOTES
        File Name : Invoke-ADCGetL2param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l2param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetL2param: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all l2param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l2param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for l2param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l2param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving l2param objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l2param -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving l2param configuration for property ''"

            } else {
                Write-Verbose "Retrieving l2param configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l2param -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetL2param: Ended"
    }
}

function Invoke-ADCUpdateL3param {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 3 related parameter resource.
    .PARAMETER Srcnat
        Perform NAT if only the source is in the private network.
        Possible values = ENABLED, DISABLED
    .PARAMETER Icmpgenratethreshold
        NS generated ICMP pkts per 10ms rate threshold.
    .PARAMETER Overridernat
        USNIP/USIP settings override RNAT settings for configured
        service/virtual server traffic.. .
        Possible values = ENABLED, DISABLED
    .PARAMETER Dropdfflag
        Enable dropping the IP DF flag.
        Possible values = ENABLED, DISABLED
    .PARAMETER Miproundrobin
        Enable round robin usage of mapped IPs.
        Possible values = ENABLED, DISABLED
    .PARAMETER Externalloopback
        Enable external loopback.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tnlpmtuwoconn
        Enable/Disable learning PMTU of IP tunnel when ICMP error does not contain connection information.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usipserverstraypkt
        Enable detection of stray server side pkts in USIP mode.
        Possible values = ENABLED, DISABLED
    .PARAMETER Forwardicmpfragments
        Enable forwarding of ICMP fragments.
        Possible values = ENABLED, DISABLED
    .PARAMETER Dropipfragments
        Enable dropping of IP fragments.
        Possible values = ENABLED, DISABLED
    .PARAMETER Acllogtime
        Parameter to tune acl logging time.
    .PARAMETER Implicitaclallow
        Do not apply ACLs for internal ports.
        Possible values = ENABLED, DISABLED
    .PARAMETER Dynamicrouting
        Enable/Disable Dynamic routing on partition. This configuration is not applicable to default partition.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable/Disable IPv6 Dynamic routing.
        Possible values = ENABLED, DISABLED
    .PARAMETER Allowclasseipv4
        Enable/Disable IPv4 Class E address clients.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateL3param
        An example how to update l3param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateL3param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l3param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcnat,

        [double]$Icmpgenratethreshold,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Overridernat,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dropdfflag,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Miproundrobin,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Externalloopback,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tnlpmtuwoconn,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Usipserverstraypkt,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Forwardicmpfragments,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dropipfragments,

        [double]$Acllogtime,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Implicitaclallow,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Allowclasseipv4 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateL3param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcnat') ) { $payload.Add('srcnat', $srcnat) }
            if ( $PSBoundParameters.ContainsKey('icmpgenratethreshold') ) { $payload.Add('icmpgenratethreshold', $icmpgenratethreshold) }
            if ( $PSBoundParameters.ContainsKey('overridernat') ) { $payload.Add('overridernat', $overridernat) }
            if ( $PSBoundParameters.ContainsKey('dropdfflag') ) { $payload.Add('dropdfflag', $dropdfflag) }
            if ( $PSBoundParameters.ContainsKey('miproundrobin') ) { $payload.Add('miproundrobin', $miproundrobin) }
            if ( $PSBoundParameters.ContainsKey('externalloopback') ) { $payload.Add('externalloopback', $externalloopback) }
            if ( $PSBoundParameters.ContainsKey('tnlpmtuwoconn') ) { $payload.Add('tnlpmtuwoconn', $tnlpmtuwoconn) }
            if ( $PSBoundParameters.ContainsKey('usipserverstraypkt') ) { $payload.Add('usipserverstraypkt', $usipserverstraypkt) }
            if ( $PSBoundParameters.ContainsKey('forwardicmpfragments') ) { $payload.Add('forwardicmpfragments', $forwardicmpfragments) }
            if ( $PSBoundParameters.ContainsKey('dropipfragments') ) { $payload.Add('dropipfragments', $dropipfragments) }
            if ( $PSBoundParameters.ContainsKey('acllogtime') ) { $payload.Add('acllogtime', $acllogtime) }
            if ( $PSBoundParameters.ContainsKey('implicitaclallow') ) { $payload.Add('implicitaclallow', $implicitaclallow) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('allowclasseipv4') ) { $payload.Add('allowclasseipv4', $allowclasseipv4) }
            if ( $PSCmdlet.ShouldProcess("l3param", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type l3param -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateL3param: Finished"
    }
}

function Invoke-ADCUnsetL3param {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 3 related parameter resource.
    .PARAMETER Srcnat
        Perform NAT if only the source is in the private network.
        Possible values = ENABLED, DISABLED
    .PARAMETER Icmpgenratethreshold
        NS generated ICMP pkts per 10ms rate threshold.
    .PARAMETER Overridernat
        USNIP/USIP settings override RNAT settings for configured
        service/virtual server traffic.. .
        Possible values = ENABLED, DISABLED
    .PARAMETER Dropdfflag
        Enable dropping the IP DF flag.
        Possible values = ENABLED, DISABLED
    .PARAMETER Miproundrobin
        Enable round robin usage of mapped IPs.
        Possible values = ENABLED, DISABLED
    .PARAMETER Externalloopback
        Enable external loopback.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tnlpmtuwoconn
        Enable/Disable learning PMTU of IP tunnel when ICMP error does not contain connection information.
        Possible values = ENABLED, DISABLED
    .PARAMETER Usipserverstraypkt
        Enable detection of stray server side pkts in USIP mode.
        Possible values = ENABLED, DISABLED
    .PARAMETER Forwardicmpfragments
        Enable forwarding of ICMP fragments.
        Possible values = ENABLED, DISABLED
    .PARAMETER Dropipfragments
        Enable dropping of IP fragments.
        Possible values = ENABLED, DISABLED
    .PARAMETER Acllogtime
        Parameter to tune acl logging time.
    .PARAMETER Implicitaclallow
        Do not apply ACLs for internal ports.
        Possible values = ENABLED, DISABLED
    .PARAMETER Dynamicrouting
        Enable/Disable Dynamic routing on partition. This configuration is not applicable to default partition.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable/Disable IPv6 Dynamic routing.
        Possible values = ENABLED, DISABLED
    .PARAMETER Allowclasseipv4
        Enable/Disable IPv4 Class E address clients.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetL3param
        An example how to unset l3param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetL3param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l3param
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$srcnat,

        [Boolean]$icmpgenratethreshold,

        [Boolean]$overridernat,

        [Boolean]$dropdfflag,

        [Boolean]$miproundrobin,

        [Boolean]$externalloopback,

        [Boolean]$tnlpmtuwoconn,

        [Boolean]$usipserverstraypkt,

        [Boolean]$forwardicmpfragments,

        [Boolean]$dropipfragments,

        [Boolean]$acllogtime,

        [Boolean]$implicitaclallow,

        [Boolean]$dynamicrouting,

        [Boolean]$ipv6dynamicrouting,

        [Boolean]$allowclasseipv4 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetL3param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('srcnat') ) { $payload.Add('srcnat', $srcnat) }
            if ( $PSBoundParameters.ContainsKey('icmpgenratethreshold') ) { $payload.Add('icmpgenratethreshold', $icmpgenratethreshold) }
            if ( $PSBoundParameters.ContainsKey('overridernat') ) { $payload.Add('overridernat', $overridernat) }
            if ( $PSBoundParameters.ContainsKey('dropdfflag') ) { $payload.Add('dropdfflag', $dropdfflag) }
            if ( $PSBoundParameters.ContainsKey('miproundrobin') ) { $payload.Add('miproundrobin', $miproundrobin) }
            if ( $PSBoundParameters.ContainsKey('externalloopback') ) { $payload.Add('externalloopback', $externalloopback) }
            if ( $PSBoundParameters.ContainsKey('tnlpmtuwoconn') ) { $payload.Add('tnlpmtuwoconn', $tnlpmtuwoconn) }
            if ( $PSBoundParameters.ContainsKey('usipserverstraypkt') ) { $payload.Add('usipserverstraypkt', $usipserverstraypkt) }
            if ( $PSBoundParameters.ContainsKey('forwardicmpfragments') ) { $payload.Add('forwardicmpfragments', $forwardicmpfragments) }
            if ( $PSBoundParameters.ContainsKey('dropipfragments') ) { $payload.Add('dropipfragments', $dropipfragments) }
            if ( $PSBoundParameters.ContainsKey('acllogtime') ) { $payload.Add('acllogtime', $acllogtime) }
            if ( $PSBoundParameters.ContainsKey('implicitaclallow') ) { $payload.Add('implicitaclallow', $implicitaclallow) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('allowclasseipv4') ) { $payload.Add('allowclasseipv4', $allowclasseipv4) }
            if ( $PSCmdlet.ShouldProcess("l3param", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type l3param -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetL3param: Finished"
    }
}

function Invoke-ADCGetL3param {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Layer 3 related parameter resource.
    .PARAMETER GetAll
        Retrieve all l3param object(s).
    .PARAMETER Count
        If specified, the count of the l3param object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL3param
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL3param -GetAll
        Get all l3param data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL3param -name <string>
        Get l3param object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL3param -Filter @{ 'name'='<value>' }
        Get l3param data with a filter.
    .NOTES
        File Name : Invoke-ADCGetL3param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l3param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetL3param: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all l3param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l3param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for l3param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l3param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving l3param objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l3param -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving l3param configuration for property ''"

            } else {
                Write-Verbose "Retrieving l3param configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l3param -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetL3param: Ended"
    }
}

function Invoke-ADCUpdateL4param {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 4 related parameter resource.
    .PARAMETER L2connmethod
        Layer 2 connection method based on the combination of channel number, MAC address and VLAN. It is tuned with l2conn param of lb vserver. If l2conn of lb vserver is ON then method specified here will be used to identify a connection in addition to the 4-tuple (<source IP>:<source port>::<destination IP>:<destination port>).
        Possible values = Channel, Vlan, VlanChannel, Mac, MacChannel, MacVlan, MacVlanChannel
    .PARAMETER L4switch
        In L4 switch topology, always clients and servers are on the same side. Enable l4switch to allow such connections.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateL4param
        An example how to update l4param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateL4param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l4param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateSet('Channel', 'Vlan', 'VlanChannel', 'Mac', 'MacChannel', 'MacVlan', 'MacVlanChannel')]
        [string]$L2connmethod,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$L4switch 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateL4param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('l2connmethod') ) { $payload.Add('l2connmethod', $l2connmethod) }
            if ( $PSBoundParameters.ContainsKey('l4switch') ) { $payload.Add('l4switch', $l4switch) }
            if ( $PSCmdlet.ShouldProcess("l4param", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type l4param -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateL4param: Finished"
    }
}

function Invoke-ADCUnsetL4param {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Layer 4 related parameter resource.
    .PARAMETER L2connmethod
        Layer 2 connection method based on the combination of channel number, MAC address and VLAN. It is tuned with l2conn param of lb vserver. If l2conn of lb vserver is ON then method specified here will be used to identify a connection in addition to the 4-tuple (<source IP>:<source port>::<destination IP>:<destination port>).
        Possible values = Channel, Vlan, VlanChannel, Mac, MacChannel, MacVlan, MacVlanChannel
    .PARAMETER L4switch
        In L4 switch topology, always clients and servers are on the same side. Enable l4switch to allow such connections.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetL4param
        An example how to unset l4param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetL4param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l4param
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$l2connmethod,

        [Boolean]$l4switch 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetL4param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('l2connmethod') ) { $payload.Add('l2connmethod', $l2connmethod) }
            if ( $PSBoundParameters.ContainsKey('l4switch') ) { $payload.Add('l4switch', $l4switch) }
            if ( $PSCmdlet.ShouldProcess("l4param", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type l4param -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetL4param: Finished"
    }
}

function Invoke-ADCGetL4param {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Layer 4 related parameter resource.
    .PARAMETER GetAll
        Retrieve all l4param object(s).
    .PARAMETER Count
        If specified, the count of the l4param object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL4param
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL4param -GetAll
        Get all l4param data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL4param -name <string>
        Get l4param object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetL4param -Filter @{ 'name'='<value>' }
        Get l4param data with a filter.
    .NOTES
        File Name : Invoke-ADCGetL4param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/l4param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetL4param: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all l4param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l4param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for l4param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l4param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving l4param objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l4param -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving l4param configuration for property ''"

            } else {
                Write-Verbose "Retrieving l4param configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type l4param -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetL4param: Ended"
    }
}

function Invoke-ADCUpdateLacp {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Link aggregation control protocol resource.
    .PARAMETER Syspriority
        Priority number that determines which peer device of an LACP LA channel can have control over the LA channel. This parameter is globally applied to all LACP channels on the Citrix ADC. The lower the number, the higher the priority.
    .PARAMETER Ownernode
        The owner node in a cluster for which we want to set the lacp priority. Owner node can vary from 0 to 31. Ownernode value of 254 is used for Cluster.
    .PARAMETER PassThru
        Return details about the created lacp item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateLacp -syspriority <double>
        An example how to update lacp configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateLacp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/lacp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 65535)]
        [double]$Syspriority,

        [double]$Ownernode,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateLacp: Starting"
    }
    process {
        try {
            $payload = @{ syspriority = $syspriority }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("lacp", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type lacp -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetLacp -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateLacp: Finished"
    }
}

function Invoke-ADCGetLacp {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Link aggregation control protocol resource.
    .PARAMETER Ownernode
        The owner node in a cluster for which we want to set the lacp priority. Owner node can vary from 0 to 31. Ownernode value of 254 is used for Cluster.
    .PARAMETER GetAll
        Retrieve all lacp object(s).
    .PARAMETER Count
        If specified, the count of the lacp object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLacp
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLacp -GetAll
        Get all lacp data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLacp -Count
        Get the number of lacp objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLacp -name <string>
        Get lacp object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLacp -Filter @{ 'name'='<value>' }
        Get lacp data with a filter.
    .NOTES
        File Name : Invoke-ADCGetLacp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/lacp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [double]$Ownernode,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetLacp: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all lacp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type lacp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for lacp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type lacp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving lacp objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type lacp -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving lacp configuration for property 'ownernode'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type lacp -NitroPath nitro/v1/config -Resource $ownernode -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving lacp configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type lacp -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetLacp: Ended"
    }
}

function Invoke-ADCAddLinkset {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for link set resource.
    .PARAMETER Id
        Unique identifier for the linkset. Must be of the form LS/x, where x can be an integer from 1 to 32.
    .PARAMETER PassThru
        Return details about the created linkset item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddLinkset -id <string>
        An example how to add linkset configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddLinkset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddLinkset: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }

            if ( $PSCmdlet.ShouldProcess("linkset", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type linkset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetLinkset -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddLinkset: Finished"
    }
}

function Invoke-ADCDeleteLinkset {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for link set resource.
    .PARAMETER Id
        Unique identifier for the linkset. Must be of the form LS/x, where x can be an integer from 1 to 32.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteLinkset -Id <string>
        An example how to delete linkset configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteLinkset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteLinkset: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type linkset -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteLinkset: Finished"
    }
}

function Invoke-ADCGetLinkset {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for link set resource.
    .PARAMETER Id
        Unique identifier for the linkset. Must be of the form LS/x, where x can be an integer from 1 to 32.
    .PARAMETER GetAll
        Retrieve all linkset object(s).
    .PARAMETER Count
        If specified, the count of the linkset object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinkset
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinkset -GetAll
        Get all linkset data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinkset -Count
        Get the number of linkset objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinkset -name <string>
        Get linkset object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinkset -Filter @{ 'name'='<value>' }
        Get linkset data with a filter.
    .NOTES
        File Name : Invoke-ADCGetLinkset
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetLinkset: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all linkset objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for linkset objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving linkset objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving linkset configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving linkset configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetLinkset: Ended"
    }
}

function Invoke-ADCGetLinksetbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to linkset.
    .PARAMETER Id
        ID of the linkset for which to display information. If an ID is not provided, the display includes information about all linksets that are available in the cluster.
    .PARAMETER GetAll
        Retrieve all linkset_binding object(s).
    .PARAMETER Count
        If specified, the count of the linkset_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetbinding -GetAll
        Get all linkset_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetbinding -name <string>
        Get linkset_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetbinding -Filter @{ 'name'='<value>' }
        Get linkset_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetLinksetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetLinksetbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all linkset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for linkset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving linkset_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving linkset_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving linkset_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetLinksetbinding: Ended"
    }
}

function Invoke-ADCAddLinksetchannelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER Ifnum
        The interfaces to be bound to the linkset.
    .PARAMETER PassThru
        Return details about the created linkset_channel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddLinksetchannelbinding -id <string> -ifnum <string>
        An example how to add linkset_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddLinksetchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [Parameter(Mandatory)]
        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddLinksetchannelbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id
                ifnum        = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("linkset_channel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type linkset_channel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetLinksetchannelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddLinksetchannelbinding: Finished"
    }
}

function Invoke-ADCDeleteLinksetchannelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER Ifnum
        The interfaces to be bound to the linkset.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteLinksetchannelbinding -Id <string>
        An example how to delete linkset_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteLinksetchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteLinksetchannelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type linkset_channel_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteLinksetchannelbinding: Finished"
    }
}

function Invoke-ADCGetLinksetchannelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the channel that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER GetAll
        Retrieve all linkset_channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the linkset_channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetchannelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetchannelbinding -GetAll
        Get all linkset_channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetchannelbinding -Count
        Get the number of linkset_channel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetchannelbinding -name <string>
        Get linkset_channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetchannelbinding -Filter @{ 'name'='<value>' }
        Get linkset_channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetLinksetchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetLinksetchannelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all linkset_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for linkset_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving linkset_channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving linkset_channel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_channel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving linkset_channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetLinksetchannelbinding: Ended"
    }
}

function Invoke-ADCAddLinksetinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER Ifnum
        The interfaces to be bound to the linkset.
    .PARAMETER PassThru
        Return details about the created linkset_interface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddLinksetinterfacebinding -id <string> -ifnum <string>
        An example how to add linkset_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddLinksetinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [Parameter(Mandatory)]
        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddLinksetinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id
                ifnum        = $ifnum
            }

            if ( $PSCmdlet.ShouldProcess("linkset_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type linkset_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetLinksetinterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddLinksetinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteLinksetinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER Ifnum
        The interfaces to be bound to the linkset.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteLinksetinterfacebinding -Id <string>
        An example how to delete linkset_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteLinksetinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteLinksetinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type linkset_interface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteLinksetinterfacebinding: Finished"
    }
}

function Invoke-ADCGetLinksetinterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the interface that can be bound to linkset.
    .PARAMETER Id
        ID of the linkset to which to bind the interfaces.
    .PARAMETER GetAll
        Retrieve all linkset_interface_binding object(s).
    .PARAMETER Count
        If specified, the count of the linkset_interface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetinterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetinterfacebinding -GetAll
        Get all linkset_interface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetinterfacebinding -Count
        Get the number of linkset_interface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetinterfacebinding -name <string>
        Get linkset_interface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetLinksetinterfacebinding -Filter @{ 'name'='<value>' }
        Get linkset_interface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetLinksetinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/linkset_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetLinksetinterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all linkset_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for linkset_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving linkset_interface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_interface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving linkset_interface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_interface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving linkset_interface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type linkset_interface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetLinksetinterfacebinding: Ended"
    }
}

function Invoke-ADCAddMapbmr {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Basic Mapping rule resource.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER Ruleipv6prefix
        IPv6 prefix of Customer Edge(CE) device.MAP-T CE will send ipv6 packets with this ipv6 prefix as source ipv6 address prefix.
    .PARAMETER Psidoffset
        Start bit position of Port Set Identifier(PSID) value in Embedded Address (EA) bits.
    .PARAMETER Eabitlength
        The Embedded Address (EA) bit field encodes the CE-specific IPv4 address and port information. The EA bit field, which is unique for a
        given Rule IPv6 prefix.
    .PARAMETER Psidlength
        Length of Port Set IdentifierPort Set Identifier(PSID) in Embedded Address (EA) bits.
    .PARAMETER PassThru
        Return details about the created mapbmr item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddMapbmr -name <string> -ruleipv6prefix <string>
        An example how to add mapbmr configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddMapbmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Ruleipv6prefix,

        [ValidateRange(1, 15)]
        [double]$Psidoffset = '6',

        [ValidateRange(2, 47)]
        [double]$Eabitlength = '16',

        [ValidateRange(1, 16)]
        [double]$Psidlength = '8',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddMapbmr: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                ruleipv6prefix = $ruleipv6prefix
            }
            if ( $PSBoundParameters.ContainsKey('psidoffset') ) { $payload.Add('psidoffset', $psidoffset) }
            if ( $PSBoundParameters.ContainsKey('eabitlength') ) { $payload.Add('eabitlength', $eabitlength) }
            if ( $PSBoundParameters.ContainsKey('psidlength') ) { $payload.Add('psidlength', $psidlength) }
            if ( $PSCmdlet.ShouldProcess("mapbmr", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type mapbmr -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetMapbmr -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddMapbmr: Finished"
    }
}

function Invoke-ADCDeleteMapbmr {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Basic Mapping rule resource.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteMapbmr -Name <string>
        An example how to delete mapbmr configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteMapbmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteMapbmr: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type mapbmr -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteMapbmr: Finished"
    }
}

function Invoke-ADCGetMapbmr {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for MAP-T Basic Mapping rule resource.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER GetAll
        Retrieve all mapbmr object(s).
    .PARAMETER Count
        If specified, the count of the mapbmr object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmr
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmr -GetAll
        Get all mapbmr data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmr -Count
        Get the number of mapbmr objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmr -name <string>
        Get mapbmr object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmr -Filter @{ 'name'='<value>' }
        Get mapbmr data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapbmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetMapbmr: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all mapbmr objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapbmr objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapbmr objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapbmr configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapbmr configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapbmr: Ended"
    }
}

function Invoke-ADCGetMapbmrbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to mapbmr.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER GetAll
        Retrieve all mapbmr_binding object(s).
    .PARAMETER Count
        If specified, the count of the mapbmr_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbinding -GetAll
        Get all mapbmr_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbinding -name <string>
        Get mapbmr_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbinding -Filter @{ 'name'='<value>' }
        Get mapbmr_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapbmrbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetMapbmrbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all mapbmr_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapbmr_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapbmr_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapbmr_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapbmr_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapbmrbinding: Ended"
    }
}

function Invoke-ADCAddMapbmrbmrv4networkbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the bmrv4network that can be bound to mapbmr.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER Network
        IPv4 NAT address range of Customer Edge (CE).
    .PARAMETER Netmask
        Subnet mask for the IPv4 address specified in the Network parameter.
    .PARAMETER PassThru
        Return details about the created mapbmr_bmrv4network_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddMapbmrbmrv4networkbinding -name <string> -network <string>
        An example how to add mapbmr_bmrv4network_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddMapbmrbmrv4networkbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr_bmrv4network_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [string]$Netmask,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddMapbmrbmrv4networkbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                network        = $network
            }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSCmdlet.ShouldProcess("mapbmr_bmrv4network_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type mapbmr_bmrv4network_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetMapbmrbmrv4networkbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddMapbmrbmrv4networkbinding: Finished"
    }
}

function Invoke-ADCDeleteMapbmrbmrv4networkbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the bmrv4network that can be bound to mapbmr.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER Network
        IPv4 NAT address range of Customer Edge (CE).
    .PARAMETER Netmask
        Subnet mask for the IPv4 address specified in the Network parameter.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteMapbmrbmrv4networkbinding -Name <string>
        An example how to delete mapbmr_bmrv4network_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteMapbmrbmrv4networkbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr_bmrv4network_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Network,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteMapbmrbmrv4networkbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Network') ) { $arguments.Add('network', $Network) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteMapbmrbmrv4networkbinding: Finished"
    }
}

function Invoke-ADCGetMapbmrbmrv4networkbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the bmrv4network that can be bound to mapbmr.
    .PARAMETER Name
        Name for the Basic Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Basic Mapping Rule is created.
    .PARAMETER GetAll
        Retrieve all mapbmr_bmrv4network_binding object(s).
    .PARAMETER Count
        If specified, the count of the mapbmr_bmrv4network_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbmrv4networkbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbmrv4networkbinding -GetAll
        Get all mapbmr_bmrv4network_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbmrv4networkbinding -Count
        Get the number of mapbmr_bmrv4network_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbmrv4networkbinding -name <string>
        Get mapbmr_bmrv4network_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapbmrbmrv4networkbinding -Filter @{ 'name'='<value>' }
        Get mapbmr_bmrv4network_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapbmrbmrv4networkbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapbmr_bmrv4network_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetMapbmrbmrv4networkbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all mapbmr_bmrv4network_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapbmr_bmrv4network_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapbmr_bmrv4network_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapbmr_bmrv4network_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapbmr_bmrv4network_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapbmr_bmrv4network_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapbmrbmrv4networkbinding: Ended"
    }
}

function Invoke-ADCAddMapdmr {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Default Mapping rule resource.
    .PARAMETER Name
        Name for the Default Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Default Mapping Rule is created.
    .PARAMETER Bripv6prefix
        IPv6 prefix of Border Relay (Citrix ADC) device.MAP-T CE will send ipv6 packets to this ipv6 prefix.The DMR IPv6 prefix length SHOULD be 64 bits long by default and in any case MUST NOT exceed 96 bits.
    .PARAMETER PassThru
        Return details about the created mapdmr item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddMapdmr -name <string> -bripv6prefix <string>
        An example how to add mapdmr configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddMapdmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Bripv6prefix,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddMapdmr: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                bripv6prefix   = $bripv6prefix
            }

            if ( $PSCmdlet.ShouldProcess("mapdmr", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type mapdmr -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetMapdmr -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddMapdmr: Finished"
    }
}

function Invoke-ADCDeleteMapdmr {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Default Mapping rule resource.
    .PARAMETER Name
        Name for the Default Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Default Mapping Rule is created.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteMapdmr -Name <string>
        An example how to delete mapdmr configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteMapdmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteMapdmr: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type mapdmr -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteMapdmr: Finished"
    }
}

function Invoke-ADCGetMapdmr {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for MAP-T Default Mapping rule resource.
    .PARAMETER Name
        Name for the Default Mapping Rule. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Default Mapping Rule is created.
    .PARAMETER GetAll
        Retrieve all mapdmr object(s).
    .PARAMETER Count
        If specified, the count of the mapdmr object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdmr
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdmr -GetAll
        Get all mapdmr data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdmr -Count
        Get the number of mapdmr objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdmr -name <string>
        Get mapdmr object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdmr -Filter @{ 'name'='<value>' }
        Get mapdmr data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapdmr
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdmr/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetMapdmr: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all mapdmr objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdmr -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapdmr objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdmr -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapdmr objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdmr -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapdmr configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdmr -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapdmr configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdmr -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapdmr: Ended"
    }
}

function Invoke-ADCAddMapdomain {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Map Domain resource.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER Mapdmrname
        Default Mapping rule name.
    .PARAMETER PassThru
        Return details about the created mapdomain item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddMapdomain -name <string> -mapdmrname <string>
        An example how to add mapdomain configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddMapdomain
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Mapdmrname,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddMapdomain: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                mapdmrname     = $mapdmrname
            }

            if ( $PSCmdlet.ShouldProcess("mapdomain", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type mapdomain -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetMapdomain -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddMapdomain: Finished"
    }
}

function Invoke-ADCDeleteMapdomain {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for MAP-T Map Domain resource.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteMapdomain -Name <string>
        An example how to delete mapdomain configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteMapdomain
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteMapdomain: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type mapdomain -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteMapdomain: Finished"
    }
}

function Invoke-ADCGetMapdomain {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for MAP-T Map Domain resource.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER GetAll
        Retrieve all mapdomain object(s).
    .PARAMETER Count
        If specified, the count of the mapdomain object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomain
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomain -GetAll
        Get all mapdomain data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomain -Count
        Get the number of mapdomain objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomain -name <string>
        Get mapdomain object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomain -Filter @{ 'name'='<value>' }
        Get mapdomain data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapdomain
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetMapdomain: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all mapdomain objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapdomain objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapdomain objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapdomain configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapdomain configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapdomain: Ended"
    }
}

function Invoke-ADCGetMapdomainbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to mapdomain.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER GetAll
        Retrieve all mapdomain_binding object(s).
    .PARAMETER Count
        If specified, the count of the mapdomain_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainbinding -GetAll
        Get all mapdomain_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainbinding -name <string>
        Get mapdomain_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainbinding -Filter @{ 'name'='<value>' }
        Get mapdomain_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapdomainbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetMapdomainbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all mapdomain_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapdomain_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapdomain_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapdomain_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapdomain_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapdomainbinding: Ended"
    }
}

function Invoke-ADCAddMapdomainmapbmrbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the mapbmr that can be bound to mapdomain.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER Mapbmrname
        Basic Mapping rule name.
    .PARAMETER PassThru
        Return details about the created mapdomain_mapbmr_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddMapdomainmapbmrbinding -name <string> -mapbmrname <string>
        An example how to add mapdomain_mapbmr_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddMapdomainmapbmrbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain_mapbmr_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(Mandatory)]
        [string]$Mapbmrname,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddMapdomainmapbmrbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                mapbmrname     = $mapbmrname
            }

            if ( $PSCmdlet.ShouldProcess("mapdomain_mapbmr_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type mapdomain_mapbmr_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetMapdomainmapbmrbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddMapdomainmapbmrbinding: Finished"
    }
}

function Invoke-ADCDeleteMapdomainmapbmrbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the mapbmr that can be bound to mapdomain.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER Mapbmrname
        Basic Mapping rule name.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteMapdomainmapbmrbinding -Name <string>
        An example how to delete mapdomain_mapbmr_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteMapdomainmapbmrbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain_mapbmr_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Mapbmrname 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteMapdomainmapbmrbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Mapbmrname') ) { $arguments.Add('mapbmrname', $Mapbmrname) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteMapdomainmapbmrbinding: Finished"
    }
}

function Invoke-ADCGetMapdomainmapbmrbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the mapbmr that can be bound to mapdomain.
    .PARAMETER Name
        Name for the MAP Domain. Must begin with an ASCII alphanumeric or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Cannot be changed after the MAP Domain is created .
    .PARAMETER GetAll
        Retrieve all mapdomain_mapbmr_binding object(s).
    .PARAMETER Count
        If specified, the count of the mapdomain_mapbmr_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainmapbmrbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainmapbmrbinding -GetAll
        Get all mapdomain_mapbmr_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainmapbmrbinding -Count
        Get the number of mapdomain_mapbmr_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainmapbmrbinding -name <string>
        Get mapdomain_mapbmr_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetMapdomainmapbmrbinding -Filter @{ 'name'='<value>' }
        Get mapdomain_mapbmr_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetMapdomainmapbmrbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/mapdomain_mapbmr_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [ValidateLength(1, 127)]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetMapdomainmapbmrbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all mapdomain_mapbmr_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for mapdomain_mapbmr_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving mapdomain_mapbmr_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving mapdomain_mapbmr_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving mapdomain_mapbmr_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type mapdomain_mapbmr_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetMapdomainmapbmrbinding: Ended"
    }
}

function Invoke-ADCAddNat64 {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for nat64 config resource.
    .PARAMETER Name
        Name for the NAT64 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the NAT64 rule.
    .PARAMETER Acl6name
        Name of any configured ACL6 whose action is ALLOW. IPv6 Packets matching the condition of this ACL6 rule and destination IP address of these packets matching the NAT64 IPv6 prefix are considered for NAT64 translation.
    .PARAMETER Netprofile
        Name of the configured netprofile. The Citrix ADC selects one of the IP address in the netprofile as the source IP address of the translated IPv4 packet to be sent to the IPv4 server.
    .PARAMETER PassThru
        Return details about the created nat64 item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNat64 -name <string> -acl6name <string>
        An example how to add nat64 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNat64
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Acl6name,

        [ValidateLength(1, 127)]
        [string]$Netprofile,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNat64: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                acl6name       = $acl6name
            }
            if ( $PSBoundParameters.ContainsKey('netprofile') ) { $payload.Add('netprofile', $netprofile) }
            if ( $PSCmdlet.ShouldProcess("nat64", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type nat64 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNat64 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNat64: Finished"
    }
}

function Invoke-ADCUpdateNat64 {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for nat64 config resource.
    .PARAMETER Name
        Name for the NAT64 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the NAT64 rule.
    .PARAMETER Acl6name
        Name of any configured ACL6 whose action is ALLOW. IPv6 Packets matching the condition of this ACL6 rule and destination IP address of these packets matching the NAT64 IPv6 prefix are considered for NAT64 translation.
    .PARAMETER Netprofile
        Name of the configured netprofile. The Citrix ADC selects one of the IP address in the netprofile as the source IP address of the translated IPv4 packet to be sent to the IPv4 server.
    .PARAMETER PassThru
        Return details about the created nat64 item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateNat64 -name <string>
        An example how to update nat64 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateNat64
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Acl6name,

        [ValidateLength(1, 127)]
        [string]$Netprofile,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateNat64: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('acl6name') ) { $payload.Add('acl6name', $acl6name) }
            if ( $PSBoundParameters.ContainsKey('netprofile') ) { $payload.Add('netprofile', $netprofile) }
            if ( $PSCmdlet.ShouldProcess("nat64", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type nat64 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNat64 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateNat64: Finished"
    }
}

function Invoke-ADCUnsetNat64 {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for nat64 config resource.
    .PARAMETER Name
        Name for the NAT64 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the NAT64 rule.
    .PARAMETER Netprofile
        Name of the configured netprofile. The Citrix ADC selects one of the IP address in the netprofile as the source IP address of the translated IPv4 packet to be sent to the IPv4 server.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetNat64 -name <string>
        An example how to unset nat64 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetNat64
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Boolean]$netprofile 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetNat64: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('netprofile') ) { $payload.Add('netprofile', $netprofile) }
            if ( $PSCmdlet.ShouldProcess("$name", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type nat64 -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetNat64: Finished"
    }
}

function Invoke-ADCDeleteNat64 {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for nat64 config resource.
    .PARAMETER Name
        Name for the NAT64 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the NAT64 rule.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNat64 -Name <string>
        An example how to delete nat64 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNat64
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNat64: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type nat64 -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNat64: Finished"
    }
}

function Invoke-ADCGetNat64 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for nat64 config resource.
    .PARAMETER Name
        Name for the NAT64 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the NAT64 rule.
    .PARAMETER GetAll
        Retrieve all nat64 object(s).
    .PARAMETER Count
        If specified, the count of the nat64 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64 -GetAll
        Get all nat64 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64 -Count
        Get the number of nat64 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64 -name <string>
        Get nat64 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64 -Filter @{ 'name'='<value>' }
        Get nat64 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNat64
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNat64: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all nat64 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nat64 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nat64 objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nat64 configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64 -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving nat64 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNat64: Ended"
    }
}

function Invoke-ADCUpdateNat64param {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for NAT64 parameter resource.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Nat64ignoretos
        Ignore TOS.
        Possible values = YES, NO
    .PARAMETER Nat64zerochecksum
        Calculate checksum for UDP packets with zero checksum.
        Possible values = ENABLED, DISABLED
    .PARAMETER Nat64v6mtu
        MTU setting for the IPv6 side. If the incoming IPv4 packet greater than this, either fragment or send icmp need fragmentation error.
    .PARAMETER Nat64fragheader
        When disabled, translator will not insert IPv6 fragmentation header for non fragmented IPv4 packets.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created nat64param item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateNat64param
        An example how to update nat64param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateNat64param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('YES', 'NO')]
        [string]$Nat64ignoretos,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Nat64zerochecksum,

        [ValidateRange(1280, 9216)]
        [double]$Nat64v6mtu,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Nat64fragheader,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateNat64param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('nat64ignoretos') ) { $payload.Add('nat64ignoretos', $nat64ignoretos) }
            if ( $PSBoundParameters.ContainsKey('nat64zerochecksum') ) { $payload.Add('nat64zerochecksum', $nat64zerochecksum) }
            if ( $PSBoundParameters.ContainsKey('nat64v6mtu') ) { $payload.Add('nat64v6mtu', $nat64v6mtu) }
            if ( $PSBoundParameters.ContainsKey('nat64fragheader') ) { $payload.Add('nat64fragheader', $nat64fragheader) }
            if ( $PSCmdlet.ShouldProcess("nat64param", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type nat64param -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNat64param -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateNat64param: Finished"
    }
}

function Invoke-ADCUnsetNat64param {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for NAT64 parameter resource.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Nat64ignoretos
        Ignore TOS.
        Possible values = YES, NO
    .PARAMETER Nat64zerochecksum
        Calculate checksum for UDP packets with zero checksum.
        Possible values = ENABLED, DISABLED
    .PARAMETER Nat64v6mtu
        MTU setting for the IPv6 side. If the incoming IPv4 packet greater than this, either fragment or send icmp need fragmentation error.
    .PARAMETER Nat64fragheader
        When disabled, translator will not insert IPv6 fragmentation header for non fragmented IPv4 packets.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetNat64param
        An example how to unset nat64param configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetNat64param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64param
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$td,

        [Boolean]$nat64ignoretos,

        [Boolean]$nat64zerochecksum,

        [Boolean]$nat64v6mtu,

        [Boolean]$nat64fragheader 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetNat64param: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('nat64ignoretos') ) { $payload.Add('nat64ignoretos', $nat64ignoretos) }
            if ( $PSBoundParameters.ContainsKey('nat64zerochecksum') ) { $payload.Add('nat64zerochecksum', $nat64zerochecksum) }
            if ( $PSBoundParameters.ContainsKey('nat64v6mtu') ) { $payload.Add('nat64v6mtu', $nat64v6mtu) }
            if ( $PSBoundParameters.ContainsKey('nat64fragheader') ) { $payload.Add('nat64fragheader', $nat64fragheader) }
            if ( $PSCmdlet.ShouldProcess("nat64param", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type nat64param -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetNat64param: Finished"
    }
}

function Invoke-ADCGetNat64param {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for NAT64 parameter resource.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER GetAll
        Retrieve all nat64param object(s).
    .PARAMETER Count
        If specified, the count of the nat64param object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64param
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64param -GetAll
        Get all nat64param data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64param -Count
        Get the number of nat64param objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64param -name <string>
        Get nat64param object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNat64param -Filter @{ 'name'='<value>' }
        Get nat64param data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNat64param
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nat64param/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNat64param: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all nat64param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nat64param objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64param -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nat64param objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64param -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nat64param configuration for property 'td'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64param -NitroPath nitro/v1/config -Resource $td -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving nat64param configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nat64param -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNat64param: Ended"
    }
}

function Invoke-ADCAddNd6 {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for nd6 resource.
    .PARAMETER Neighbor
        Link-local IPv6 address of the adjacent network device to add to the ND6 table.
    .PARAMETER Mac
        MAC address of the adjacent network device.
    .PARAMETER Ifnum
        Interface through which the adjacent network device is available, specified in slot/port notation (for example, 1/3). Use spaces to separate multiple entries.
    .PARAMETER Vlan
        Integer value that uniquely identifies the VLAN on which the adjacent network device exists.
    .PARAMETER Vxlan
        ID of the VXLAN on which the IPv6 address of this ND6 entry is reachable.
    .PARAMETER Vtep
        IP address of the VXLAN tunnel endpoint (VTEP) through which the IPv6 address of this ND6 entry is reachable.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNd6 -neighbor <string> -mac <string>
        An example how to add nd6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNd6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Neighbor,

        [Parameter(Mandatory)]
        [string]$Mac,

        [string]$Ifnum,

        [ValidateRange(1, 4094)]
        [int]$Vlan,

        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Vtep,

        [ValidateRange(0, 4094)]
        [double]$Td 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNd6: Starting"
    }
    process {
        try {
            $payload = @{ neighbor = $neighbor
                mac                = $mac
            }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('vtep') ) { $payload.Add('vtep', $vtep) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSCmdlet.ShouldProcess("nd6", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type nd6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNd6: Finished"
    }
}

function Invoke-ADCClearNd6 {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for nd6 resource.
    .EXAMPLE
        PS C:\>Invoke-ADCClearNd6
        An example how to clear nd6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearNd6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession) 

    )
    begin {
        Write-Verbose "Invoke-ADCClearNd6: Starting"
    }
    process {
        try {
            $payload = @{ }

            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type nd6 -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearNd6: Finished"
    }
}

function Invoke-ADCDeleteNd6 {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for nd6 resource.
    .PARAMETER Neighbor
        Link-local IPv6 address of the adjacent network device to add to the ND6 table.
    .PARAMETER Vlan
        Integer value that uniquely identifies the VLAN on which the adjacent network device exists.
    .PARAMETER Vxlan
        ID of the VXLAN on which the IPv6 address of this ND6 entry is reachable.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNd6 -Neighbor <string>
        An example how to delete nd6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNd6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Neighbor,

        [int]$Vlan,

        [double]$Vxlan,

        [double]$Td 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNd6: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Vlan') ) { $arguments.Add('vlan', $Vlan) }
            if ( $PSBoundParameters.ContainsKey('Vxlan') ) { $arguments.Add('vxlan', $Vxlan) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSCmdlet.ShouldProcess("$neighbor", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type nd6 -NitroPath nitro/v1/config -Resource $neighbor -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNd6: Finished"
    }
}

function Invoke-ADCGetNd6 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for nd6 resource.
    .PARAMETER Neighbor
        Link-local IPv6 address of the adjacent network device to add to the ND6 table.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Nodeid
        Unique number that identifies the cluster node.
    .PARAMETER GetAll
        Retrieve all nd6 object(s).
    .PARAMETER Count
        If specified, the count of the nd6 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6 -GetAll
        Get all nd6 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6 -Count
        Get the number of nd6 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6 -name <string>
        Get nd6 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6 -Filter @{ 'name'='<value>' }
        Get nd6 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNd6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByArgument')]
        [string]$Neighbor,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 31)]
        [double]$Nodeid,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNd6: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all nd6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nd6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nd6 objects by arguments"
                $arguments = @{ } 
                if ( $PSBoundParameters.ContainsKey('neighbor') ) { $arguments.Add('neighbor', $neighbor) } 
                if ( $PSBoundParameters.ContainsKey('td') ) { $arguments.Add('td', $td) } 
                if ( $PSBoundParameters.ContainsKey('nodeid') ) { $arguments.Add('nodeid', $nodeid) }
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nd6 configuration for property ''"

            } else {
                Write-Verbose "Retrieving nd6 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNd6: Ended"
    }
}

function Invoke-ADCUpdateNd6ravariables {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for nd6 Router Advertisment configuration variables resource.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER Ceaserouteradv
        Cease router advertisements on this vlan.
        Possible values = YES, NO
    .PARAMETER Sendrouteradv
        whether the router sends periodic RAs and responds to Router Solicitations.
        Possible values = YES, NO
    .PARAMETER Srclinklayeraddroption
        Include source link layer address option in RA messages.
        Possible values = YES, NO
    .PARAMETER Onlyunicastrtadvresponse
        Send only Unicast Router Advertisements in respond to Router Solicitations.
        Possible values = YES, NO
    .PARAMETER Managedaddrconfig
        Value to be placed in the Managed address configuration flag field.
        Possible values = YES, NO
    .PARAMETER Otheraddrconfig
        Value to be placed in the Other configuration flag field.
        Possible values = YES, NO
    .PARAMETER Currhoplimit
        Current Hop limit.
    .PARAMETER Maxrtadvinterval
        Maximum time allowed between unsolicited multicast RAs, in seconds.
    .PARAMETER Minrtadvinterval
        Minimum time interval between RA messages, in seconds.
    .PARAMETER Linkmtu
        The Link MTU.
    .PARAMETER Reachabletime
        Reachable time, in milliseconds.
    .PARAMETER Retranstime
        Retransmission time, in milliseconds.
    .PARAMETER Defaultlifetime
        Default life time, in seconds.
    .PARAMETER PassThru
        Return details about the created nd6ravariables item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateNd6ravariables -vlan <double>
        An example how to update nd6ravariables configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateNd6ravariables
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [ValidateSet('YES', 'NO')]
        [string]$Ceaserouteradv,

        [ValidateSet('YES', 'NO')]
        [string]$Sendrouteradv,

        [ValidateSet('YES', 'NO')]
        [string]$Srclinklayeraddroption,

        [ValidateSet('YES', 'NO')]
        [string]$Onlyunicastrtadvresponse,

        [ValidateSet('YES', 'NO')]
        [string]$Managedaddrconfig,

        [ValidateSet('YES', 'NO')]
        [string]$Otheraddrconfig,

        [ValidateRange(0, 255)]
        [double]$Currhoplimit,

        [ValidateRange(4, 1800)]
        [double]$Maxrtadvinterval,

        [ValidateRange(3, 1350)]
        [double]$Minrtadvinterval,

        [ValidateRange(0, 1500)]
        [double]$Linkmtu,

        [ValidateRange(0, 3600000)]
        [double]$Reachabletime,

        [double]$Retranstime,

        [ValidateRange(0, 9000)]
        [int]$Defaultlifetime,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateNd6ravariables: Starting"
    }
    process {
        try {
            $payload = @{ vlan = $vlan }
            if ( $PSBoundParameters.ContainsKey('ceaserouteradv') ) { $payload.Add('ceaserouteradv', $ceaserouteradv) }
            if ( $PSBoundParameters.ContainsKey('sendrouteradv') ) { $payload.Add('sendrouteradv', $sendrouteradv) }
            if ( $PSBoundParameters.ContainsKey('srclinklayeraddroption') ) { $payload.Add('srclinklayeraddroption', $srclinklayeraddroption) }
            if ( $PSBoundParameters.ContainsKey('onlyunicastrtadvresponse') ) { $payload.Add('onlyunicastrtadvresponse', $onlyunicastrtadvresponse) }
            if ( $PSBoundParameters.ContainsKey('managedaddrconfig') ) { $payload.Add('managedaddrconfig', $managedaddrconfig) }
            if ( $PSBoundParameters.ContainsKey('otheraddrconfig') ) { $payload.Add('otheraddrconfig', $otheraddrconfig) }
            if ( $PSBoundParameters.ContainsKey('currhoplimit') ) { $payload.Add('currhoplimit', $currhoplimit) }
            if ( $PSBoundParameters.ContainsKey('maxrtadvinterval') ) { $payload.Add('maxrtadvinterval', $maxrtadvinterval) }
            if ( $PSBoundParameters.ContainsKey('minrtadvinterval') ) { $payload.Add('minrtadvinterval', $minrtadvinterval) }
            if ( $PSBoundParameters.ContainsKey('linkmtu') ) { $payload.Add('linkmtu', $linkmtu) }
            if ( $PSBoundParameters.ContainsKey('reachabletime') ) { $payload.Add('reachabletime', $reachabletime) }
            if ( $PSBoundParameters.ContainsKey('retranstime') ) { $payload.Add('retranstime', $retranstime) }
            if ( $PSBoundParameters.ContainsKey('defaultlifetime') ) { $payload.Add('defaultlifetime', $defaultlifetime) }
            if ( $PSCmdlet.ShouldProcess("nd6ravariables", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type nd6ravariables -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNd6ravariables -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateNd6ravariables: Finished"
    }
}

function Invoke-ADCUnsetNd6ravariables {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for nd6 Router Advertisment configuration variables resource.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER Ceaserouteradv
        Cease router advertisements on this vlan.
        Possible values = YES, NO
    .PARAMETER Sendrouteradv
        whether the router sends periodic RAs and responds to Router Solicitations.
        Possible values = YES, NO
    .PARAMETER Srclinklayeraddroption
        Include source link layer address option in RA messages.
        Possible values = YES, NO
    .PARAMETER Onlyunicastrtadvresponse
        Send only Unicast Router Advertisements in respond to Router Solicitations.
        Possible values = YES, NO
    .PARAMETER Managedaddrconfig
        Value to be placed in the Managed address configuration flag field.
        Possible values = YES, NO
    .PARAMETER Otheraddrconfig
        Value to be placed in the Other configuration flag field.
        Possible values = YES, NO
    .PARAMETER Currhoplimit
        Current Hop limit.
    .PARAMETER Maxrtadvinterval
        Maximum time allowed between unsolicited multicast RAs, in seconds.
    .PARAMETER Minrtadvinterval
        Minimum time interval between RA messages, in seconds.
    .PARAMETER Linkmtu
        The Link MTU.
    .PARAMETER Reachabletime
        Reachable time, in milliseconds.
    .PARAMETER Retranstime
        Retransmission time, in milliseconds.
    .PARAMETER Defaultlifetime
        Default life time, in seconds.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetNd6ravariables -vlan <double>
        An example how to unset nd6ravariables configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetNd6ravariables
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Boolean]$ceaserouteradv,

        [Boolean]$sendrouteradv,

        [Boolean]$srclinklayeraddroption,

        [Boolean]$onlyunicastrtadvresponse,

        [Boolean]$managedaddrconfig,

        [Boolean]$otheraddrconfig,

        [Boolean]$currhoplimit,

        [Boolean]$maxrtadvinterval,

        [Boolean]$minrtadvinterval,

        [Boolean]$linkmtu,

        [Boolean]$reachabletime,

        [Boolean]$retranstime,

        [Boolean]$defaultlifetime 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetNd6ravariables: Starting"
    }
    process {
        try {
            $payload = @{ vlan = $vlan }
            if ( $PSBoundParameters.ContainsKey('ceaserouteradv') ) { $payload.Add('ceaserouteradv', $ceaserouteradv) }
            if ( $PSBoundParameters.ContainsKey('sendrouteradv') ) { $payload.Add('sendrouteradv', $sendrouteradv) }
            if ( $PSBoundParameters.ContainsKey('srclinklayeraddroption') ) { $payload.Add('srclinklayeraddroption', $srclinklayeraddroption) }
            if ( $PSBoundParameters.ContainsKey('onlyunicastrtadvresponse') ) { $payload.Add('onlyunicastrtadvresponse', $onlyunicastrtadvresponse) }
            if ( $PSBoundParameters.ContainsKey('managedaddrconfig') ) { $payload.Add('managedaddrconfig', $managedaddrconfig) }
            if ( $PSBoundParameters.ContainsKey('otheraddrconfig') ) { $payload.Add('otheraddrconfig', $otheraddrconfig) }
            if ( $PSBoundParameters.ContainsKey('currhoplimit') ) { $payload.Add('currhoplimit', $currhoplimit) }
            if ( $PSBoundParameters.ContainsKey('maxrtadvinterval') ) { $payload.Add('maxrtadvinterval', $maxrtadvinterval) }
            if ( $PSBoundParameters.ContainsKey('minrtadvinterval') ) { $payload.Add('minrtadvinterval', $minrtadvinterval) }
            if ( $PSBoundParameters.ContainsKey('linkmtu') ) { $payload.Add('linkmtu', $linkmtu) }
            if ( $PSBoundParameters.ContainsKey('reachabletime') ) { $payload.Add('reachabletime', $reachabletime) }
            if ( $PSBoundParameters.ContainsKey('retranstime') ) { $payload.Add('retranstime', $retranstime) }
            if ( $PSBoundParameters.ContainsKey('defaultlifetime') ) { $payload.Add('defaultlifetime', $defaultlifetime) }
            if ( $PSCmdlet.ShouldProcess("$vlan", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type nd6ravariables -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetNd6ravariables: Finished"
    }
}

function Invoke-ADCGetNd6ravariables {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for nd6 Router Advertisment configuration variables resource.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER GetAll
        Retrieve all nd6ravariables object(s).
    .PARAMETER Count
        If specified, the count of the nd6ravariables object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariables
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariables -GetAll
        Get all nd6ravariables data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariables -Count
        Get the number of nd6ravariables objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariables -name <string>
        Get nd6ravariables object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariables -Filter @{ 'name'='<value>' }
        Get nd6ravariables data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNd6ravariables
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNd6ravariables: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all nd6ravariables objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nd6ravariables objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nd6ravariables objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nd6ravariables configuration for property 'vlan'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables -NitroPath nitro/v1/config -Resource $vlan -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving nd6ravariables configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNd6ravariables: Ended"
    }
}

function Invoke-ADCGetNd6ravariablesbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to nd6ravariables.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER GetAll
        Retrieve all nd6ravariables_binding object(s).
    .PARAMETER Count
        If specified, the count of the nd6ravariables_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesbinding -GetAll
        Get all nd6ravariables_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesbinding -name <string>
        Get nd6ravariables_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesbinding -Filter @{ 'name'='<value>' }
        Get nd6ravariables_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNd6ravariablesbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Vlan,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNd6ravariablesbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all nd6ravariables_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nd6ravariables_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nd6ravariables_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nd6ravariables_binding configuration for property 'vlan'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_binding -NitroPath nitro/v1/config -Resource $vlan -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving nd6ravariables_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNd6ravariablesbinding: Ended"
    }
}

function Invoke-ADCAddNd6ravariablesonlinkipv6prefixbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the onlinkipv6prefix that can be bound to nd6ravariables.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .PARAMETER PassThru
        Return details about the created nd6ravariables_onlinkipv6prefix_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNd6ravariablesonlinkipv6prefixbinding -vlan <double> -ipv6prefix <string>
        An example how to add nd6ravariables_onlinkipv6prefix_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNd6ravariablesonlinkipv6prefixbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables_onlinkipv6prefix_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Parameter(Mandatory)]
        [string]$Ipv6prefix,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNd6ravariablesonlinkipv6prefixbinding: Starting"
    }
    process {
        try {
            $payload = @{ vlan = $vlan
                ipv6prefix     = $ipv6prefix
            }

            if ( $PSCmdlet.ShouldProcess("nd6ravariables_onlinkipv6prefix_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type nd6ravariables_onlinkipv6prefix_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNd6ravariablesonlinkipv6prefixbinding: Finished"
    }
}

function Invoke-ADCDeleteNd6ravariablesonlinkipv6prefixbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the onlinkipv6prefix that can be bound to nd6ravariables.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNd6ravariablesonlinkipv6prefixbinding -Vlan <double>
        An example how to delete nd6ravariables_onlinkipv6prefix_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNd6ravariablesonlinkipv6prefixbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables_onlinkipv6prefix_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Vlan,

        [string]$Ipv6prefix 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNd6ravariablesonlinkipv6prefixbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipv6prefix') ) { $arguments.Add('ipv6prefix', $Ipv6prefix) }
            if ( $PSCmdlet.ShouldProcess("$vlan", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Resource $vlan -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNd6ravariablesonlinkipv6prefixbinding: Finished"
    }
}

function Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the onlinkipv6prefix that can be bound to nd6ravariables.
    .PARAMETER Vlan
        The VLAN number.
    .PARAMETER GetAll
        Retrieve all nd6ravariables_onlinkipv6prefix_binding object(s).
    .PARAMETER Count
        If specified, the count of the nd6ravariables_onlinkipv6prefix_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding -GetAll
        Get all nd6ravariables_onlinkipv6prefix_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding -Count
        Get the number of nd6ravariables_onlinkipv6prefix_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding -name <string>
        Get nd6ravariables_onlinkipv6prefix_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding -Filter @{ 'name'='<value>' }
        Get nd6ravariables_onlinkipv6prefix_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/nd6ravariables_onlinkipv6prefix_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all nd6ravariables_onlinkipv6prefix_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for nd6ravariables_onlinkipv6prefix_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving nd6ravariables_onlinkipv6prefix_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving nd6ravariables_onlinkipv6prefix_binding configuration for property 'vlan'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Resource $vlan -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving nd6ravariables_onlinkipv6prefix_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type nd6ravariables_onlinkipv6prefix_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNd6ravariablesonlinkipv6prefixbinding: Ended"
    }
}

function Invoke-ADCAddNetbridge {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for network bridge resource.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Vxlanvlanmap
        The vlan to vxlan mapping to be applied to this netbridge.
    .PARAMETER PassThru
        Return details about the created netbridge item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetbridge -name <string>
        An example how to add netbridge configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetbridge
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Vxlanvlanmap,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetbridge: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('vxlanvlanmap') ) { $payload.Add('vxlanvlanmap', $vxlanvlanmap) }
            if ( $PSCmdlet.ShouldProcess("netbridge", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type netbridge -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridge -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetbridge: Finished"
    }
}

function Invoke-ADCUpdateNetbridge {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for network bridge resource.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Vxlanvlanmap
        The vlan to vxlan mapping to be applied to this netbridge.
    .PARAMETER PassThru
        Return details about the created netbridge item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateNetbridge -name <string>
        An example how to update netbridge configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateNetbridge
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Vxlanvlanmap,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateNetbridge: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('vxlanvlanmap') ) { $payload.Add('vxlanvlanmap', $vxlanvlanmap) }
            if ( $PSCmdlet.ShouldProcess("netbridge", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netbridge -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridge -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateNetbridge: Finished"
    }
}

function Invoke-ADCUnsetNetbridge {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for network bridge resource.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Vxlanvlanmap
        The vlan to vxlan mapping to be applied to this netbridge.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetNetbridge -name <string>
        An example how to unset netbridge configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetNetbridge
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Name,

        [Boolean]$vxlanvlanmap 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetNetbridge: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('vxlanvlanmap') ) { $payload.Add('vxlanvlanmap', $vxlanvlanmap) }
            if ( $PSCmdlet.ShouldProcess("$name", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type netbridge -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetNetbridge: Finished"
    }
}

function Invoke-ADCDeleteNetbridge {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for network bridge resource.
    .PARAMETER Name
        The name of the network bridge.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetbridge -Name <string>
        An example how to delete netbridge configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetbridge
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetbridge: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netbridge -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetbridge: Finished"
    }
}

function Invoke-ADCGetNetbridge {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for network bridge resource.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge object(s).
    .PARAMETER Count
        If specified, the count of the netbridge object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridge
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridge -GetAll
        Get all netbridge data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridge -Count
        Get the number of netbridge objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridge -name <string>
        Get netbridge object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridge -Filter @{ 'name'='<value>' }
        Get netbridge data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridge
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridge: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all netbridge objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridge: Ended"
    }
}

function Invoke-ADCGetNetbridgebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge_binding object(s).
    .PARAMETER Count
        If specified, the count of the netbridge_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgebinding -GetAll
        Get all netbridge_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgebinding -name <string>
        Get netbridge_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgebinding -Filter @{ 'name'='<value>' }
        Get netbridge_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridgebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridgebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netbridge_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridgebinding: Ended"
    }
}

function Invoke-ADCAddNetbridgeiptunnelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the iptunnel that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Tunnel
        The name of the tunnel that is a part of this bridge.
    .PARAMETER PassThru
        Return details about the created netbridge_iptunnel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetbridgeiptunnelbinding -name <string>
        An example how to add netbridge_iptunnel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetbridgeiptunnelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_iptunnel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Tunnel,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetbridgeiptunnelbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('tunnel') ) { $payload.Add('tunnel', $tunnel) }
            if ( $PSCmdlet.ShouldProcess("netbridge_iptunnel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netbridge_iptunnel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridgeiptunnelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetbridgeiptunnelbinding: Finished"
    }
}

function Invoke-ADCDeleteNetbridgeiptunnelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the iptunnel that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Tunnel
        The name of the tunnel that is a part of this bridge.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetbridgeiptunnelbinding -Name <string>
        An example how to delete netbridge_iptunnel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetbridgeiptunnelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_iptunnel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Tunnel 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetbridgeiptunnelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Tunnel') ) { $arguments.Add('tunnel', $Tunnel) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetbridgeiptunnelbinding: Finished"
    }
}

function Invoke-ADCGetNetbridgeiptunnelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the iptunnel that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge_iptunnel_binding object(s).
    .PARAMETER Count
        If specified, the count of the netbridge_iptunnel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgeiptunnelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgeiptunnelbinding -GetAll
        Get all netbridge_iptunnel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgeiptunnelbinding -Count
        Get the number of netbridge_iptunnel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgeiptunnelbinding -name <string>
        Get netbridge_iptunnel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgeiptunnelbinding -Filter @{ 'name'='<value>' }
        Get netbridge_iptunnel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridgeiptunnelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_iptunnel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridgeiptunnelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netbridge_iptunnel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge_iptunnel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge_iptunnel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge_iptunnel_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge_iptunnel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_iptunnel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridgeiptunnelbinding: Ended"
    }
}

function Invoke-ADCAddNetbridgensip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Ipaddress
        The subnet that is extended by this network bridge.
    .PARAMETER Netmask
        The network mask for the subnet.
    .PARAMETER PassThru
        Return details about the created netbridge_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetbridgensip6binding -name <string>
        An example how to add netbridge_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetbridgensip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [string]$Netmask,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetbridgensip6binding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSCmdlet.ShouldProcess("netbridge_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netbridge_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridgensip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetbridgensip6binding: Finished"
    }
}

function Invoke-ADCDeleteNetbridgensip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Ipaddress
        The subnet that is extended by this network bridge.
    .PARAMETER Netmask
        The network mask for the subnet.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetbridgensip6binding -Name <string>
        An example how to delete netbridge_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetbridgensip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ipaddress,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetbridgensip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetbridgensip6binding: Finished"
    }
}

function Invoke-ADCGetNetbridgensip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the netbridge_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensip6binding -GetAll
        Get all netbridge_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensip6binding -Count
        Get the number of netbridge_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensip6binding -name <string>
        Get netbridge_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensip6binding -Filter @{ 'name'='<value>' }
        Get netbridge_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridgensip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridgensip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netbridge_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge_nsip6_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridgensip6binding: Ended"
    }
}

function Invoke-ADCAddNetbridgensipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Ipaddress
        The subnet that is extended by this network bridge.
    .PARAMETER Netmask
        The network mask for the subnet.
    .PARAMETER PassThru
        Return details about the created netbridge_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetbridgensipbinding -name <string>
        An example how to add netbridge_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetbridgensipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ipaddress,

        [string]$Netmask,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetbridgensipbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSCmdlet.ShouldProcess("netbridge_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netbridge_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridgensipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetbridgensipbinding: Finished"
    }
}

function Invoke-ADCDeleteNetbridgensipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Ipaddress
        The subnet that is extended by this network bridge.
    .PARAMETER Netmask
        The network mask for the subnet.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetbridgensipbinding -Name <string>
        An example how to delete netbridge_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetbridgensipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Ipaddress,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetbridgensipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetbridgensipbinding: Finished"
    }
}

function Invoke-ADCGetNetbridgensipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the netbridge_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensipbinding -GetAll
        Get all netbridge_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensipbinding -Count
        Get the number of netbridge_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensipbinding -name <string>
        Get netbridge_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgensipbinding -Filter @{ 'name'='<value>' }
        Get netbridge_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridgensipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridgensipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netbridge_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge_nsip_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridgensipbinding: Ended"
    }
}

function Invoke-ADCAddNetbridgevlanbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the vlan that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Vlan
        The VLAN that is extended by this network bridge.
    .PARAMETER PassThru
        Return details about the created netbridge_vlan_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetbridgevlanbinding -name <string>
        An example how to add netbridge_vlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetbridgevlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetbridgevlanbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSCmdlet.ShouldProcess("netbridge_vlan_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netbridge_vlan_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetbridgevlanbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetbridgevlanbinding: Finished"
    }
}

function Invoke-ADCDeleteNetbridgevlanbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the vlan that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER Vlan
        The VLAN that is extended by this network bridge.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetbridgevlanbinding -Name <string>
        An example how to delete netbridge_vlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetbridgevlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [double]$Vlan 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetbridgevlanbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Vlan') ) { $arguments.Add('vlan', $Vlan) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetbridgevlanbinding: Finished"
    }
}

function Invoke-ADCGetNetbridgevlanbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the vlan that can be bound to netbridge.
    .PARAMETER Name
        The name of the network bridge.
    .PARAMETER GetAll
        Retrieve all netbridge_vlan_binding object(s).
    .PARAMETER Count
        If specified, the count of the netbridge_vlan_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgevlanbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgevlanbinding -GetAll
        Get all netbridge_vlan_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgevlanbinding -Count
        Get the number of netbridge_vlan_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgevlanbinding -name <string>
        Get netbridge_vlan_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetbridgevlanbinding -Filter @{ 'name'='<value>' }
        Get netbridge_vlan_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetbridgevlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netbridge_vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetbridgevlanbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netbridge_vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netbridge_vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netbridge_vlan_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netbridge_vlan_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netbridge_vlan_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netbridge_vlan_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetbridgevlanbinding: Ended"
    }
}

function Invoke-ADCAddNetprofile {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for Network profile resource.
    .PARAMETER Name
        Name for the net profile. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. Choose a name that helps identify the net profile.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Srcip
        IP address or the name of an IP set.
    .PARAMETER Srcippersistency
        When the net profile is associated with a virtual server or its bound services, this option enables the Citrix ADC to use the same address, specified in the net profile, to communicate to servers for all sessions initiated from a particular client to the virtual server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Overridelsn
        USNIP/USIP settings override LSN settings for configured
        service/virtual server traffic.. .
        Possible values = ENABLED, DISABLED
    .PARAMETER Mbf
        Response will be sent using learnt info if enabled. When creating a netprofile, if you do not set this parameter, the netprofile inherits the global MBF setting (available in the enable ns mode and disable ns mode CLI commands, or in the System > Settings > Configure modes > Configure Modes dialog box). However, you can override this setting after you create the netprofile.
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocol
        Proxy Protocol Action (Enabled/Disabled).
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocoltxversion
        Proxy Protocol Version (V1/V2).
        Possible values = V1, V2
    .PARAMETER Proxyprotocolaftertlshandshake
        ADC doesnt look for proxy header before TLS handshake, if enabled. Proxy protocol parsed after TLS handshake.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created netprofile item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetprofile -name <string>
        An example how to add netprofile configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetprofile
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [string]$Srcip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Overridelsn = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Mbf,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Proxyprotocol = 'DISABLED',

        [ValidateSet('V1', 'V2')]
        [string]$Proxyprotocoltxversion = 'V1',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Proxyprotocolaftertlshandshake = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetprofile: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('overridelsn') ) { $payload.Add('overridelsn', $overridelsn) }
            if ( $PSBoundParameters.ContainsKey('mbf') ) { $payload.Add('mbf', $mbf) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocol') ) { $payload.Add('proxyprotocol', $proxyprotocol) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocoltxversion') ) { $payload.Add('proxyprotocoltxversion', $proxyprotocoltxversion) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocolaftertlshandshake') ) { $payload.Add('proxyprotocolaftertlshandshake', $proxyprotocolaftertlshandshake) }
            if ( $PSCmdlet.ShouldProcess("netprofile", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type netprofile -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetprofile -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetprofile: Finished"
    }
}

function Invoke-ADCDeleteNetprofile {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for Network profile resource.
    .PARAMETER Name
        Name for the net profile. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. Choose a name that helps identify the net profile.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetprofile -Name <string>
        An example how to delete netprofile configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetprofile
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetprofile: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netprofile -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetprofile: Finished"
    }
}

function Invoke-ADCUpdateNetprofile {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Network profile resource.
    .PARAMETER Name
        Name for the net profile. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. Choose a name that helps identify the net profile.
    .PARAMETER Srcip
        IP address or the name of an IP set.
    .PARAMETER Srcippersistency
        When the net profile is associated with a virtual server or its bound services, this option enables the Citrix ADC to use the same address, specified in the net profile, to communicate to servers for all sessions initiated from a particular client to the virtual server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Overridelsn
        USNIP/USIP settings override LSN settings for configured
        service/virtual server traffic.. .
        Possible values = ENABLED, DISABLED
    .PARAMETER Mbf
        Response will be sent using learnt info if enabled. When creating a netprofile, if you do not set this parameter, the netprofile inherits the global MBF setting (available in the enable ns mode and disable ns mode CLI commands, or in the System > Settings > Configure modes > Configure Modes dialog box). However, you can override this setting after you create the netprofile.
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocol
        Proxy Protocol Action (Enabled/Disabled).
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocoltxversion
        Proxy Protocol Version (V1/V2).
        Possible values = V1, V2
    .PARAMETER Proxyprotocolaftertlshandshake
        ADC doesnt look for proxy header before TLS handshake, if enabled. Proxy protocol parsed after TLS handshake.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created netprofile item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateNetprofile -name <string>
        An example how to update netprofile configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateNetprofile
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [string]$Srcip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Overridelsn,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Mbf,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Proxyprotocol,

        [ValidateSet('V1', 'V2')]
        [string]$Proxyprotocoltxversion,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Proxyprotocolaftertlshandshake,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateNetprofile: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('overridelsn') ) { $payload.Add('overridelsn', $overridelsn) }
            if ( $PSBoundParameters.ContainsKey('mbf') ) { $payload.Add('mbf', $mbf) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocol') ) { $payload.Add('proxyprotocol', $proxyprotocol) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocoltxversion') ) { $payload.Add('proxyprotocoltxversion', $proxyprotocoltxversion) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocolaftertlshandshake') ) { $payload.Add('proxyprotocolaftertlshandshake', $proxyprotocolaftertlshandshake) }
            if ( $PSCmdlet.ShouldProcess("netprofile", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netprofile -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetprofile -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateNetprofile: Finished"
    }
}

function Invoke-ADCUnsetNetprofile {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Network profile resource.
    .PARAMETER Name
        Name for the net profile. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. Choose a name that helps identify the net profile.
    .PARAMETER Srcip
        IP address or the name of an IP set.
    .PARAMETER Srcippersistency
        When the net profile is associated with a virtual server or its bound services, this option enables the Citrix ADC to use the same address, specified in the net profile, to communicate to servers for all sessions initiated from a particular client to the virtual server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Overridelsn
        USNIP/USIP settings override LSN settings for configured
        service/virtual server traffic.. .
        Possible values = ENABLED, DISABLED
    .PARAMETER Mbf
        Response will be sent using learnt info if enabled. When creating a netprofile, if you do not set this parameter, the netprofile inherits the global MBF setting (available in the enable ns mode and disable ns mode CLI commands, or in the System > Settings > Configure modes > Configure Modes dialog box). However, you can override this setting after you create the netprofile.
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocol
        Proxy Protocol Action (Enabled/Disabled).
        Possible values = ENABLED, DISABLED
    .PARAMETER Proxyprotocoltxversion
        Proxy Protocol Version (V1/V2).
        Possible values = V1, V2
    .PARAMETER Proxyprotocolaftertlshandshake
        ADC doesnt look for proxy header before TLS handshake, if enabled. Proxy protocol parsed after TLS handshake.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetNetprofile -name <string>
        An example how to unset netprofile configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetNetprofile
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Boolean]$srcip,

        [Boolean]$srcippersistency,

        [Boolean]$overridelsn,

        [Boolean]$mbf,

        [Boolean]$proxyprotocol,

        [Boolean]$proxyprotocoltxversion,

        [Boolean]$proxyprotocolaftertlshandshake 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetNetprofile: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('overridelsn') ) { $payload.Add('overridelsn', $overridelsn) }
            if ( $PSBoundParameters.ContainsKey('mbf') ) { $payload.Add('mbf', $mbf) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocol') ) { $payload.Add('proxyprotocol', $proxyprotocol) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocoltxversion') ) { $payload.Add('proxyprotocoltxversion', $proxyprotocoltxversion) }
            if ( $PSBoundParameters.ContainsKey('proxyprotocolaftertlshandshake') ) { $payload.Add('proxyprotocolaftertlshandshake', $proxyprotocolaftertlshandshake) }
            if ( $PSCmdlet.ShouldProcess("$name", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type netprofile -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetNetprofile: Finished"
    }
}

function Invoke-ADCGetNetprofile {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Network profile resource.
    .PARAMETER Name
        Name for the net profile. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the profile is created. Choose a name that helps identify the net profile.
    .PARAMETER GetAll
        Retrieve all netprofile object(s).
    .PARAMETER Count
        If specified, the count of the netprofile object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofile
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofile -GetAll
        Get all netprofile data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofile -Count
        Get the number of netprofile objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofile -name <string>
        Get netprofile object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofile -Filter @{ 'name'='<value>' }
        Get netprofile data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetprofile
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetNetprofile: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all netprofile objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netprofile objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netprofile objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netprofile configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netprofile configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetprofile: Ended"
    }
}

function Invoke-ADCGetNetprofilebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to netprofile.
    .PARAMETER Name
        Name of the net profile whose details you want to display.
    .PARAMETER GetAll
        Retrieve all netprofile_binding object(s).
    .PARAMETER Count
        If specified, the count of the netprofile_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilebinding -GetAll
        Get all netprofile_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilebinding -name <string>
        Get netprofile_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilebinding -Filter @{ 'name'='<value>' }
        Get netprofile_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetprofilebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetprofilebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netprofile_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netprofile_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netprofile_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netprofile_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netprofile_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetprofilebinding: Ended"
    }
}

function Invoke-ADCAddNetprofilenatrulebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the natrule that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER Natrule
        IPv4 network address on whose traffic you want the Citrix ADC to do rewrite ip prefix.
    .PARAMETER Netmask
        .
    .PARAMETER Rewriteip
        .
    .PARAMETER PassThru
        Return details about the created netprofile_natrule_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetprofilenatrulebinding -name <string>
        An example how to add netprofile_natrule_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetprofilenatrulebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_natrule_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [string]$Natrule,

        [string]$Netmask,

        [string]$Rewriteip,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetprofilenatrulebinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('natrule') ) { $payload.Add('natrule', $natrule) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('rewriteip') ) { $payload.Add('rewriteip', $rewriteip) }
            if ( $PSCmdlet.ShouldProcess("netprofile_natrule_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netprofile_natrule_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetprofilenatrulebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetprofilenatrulebinding: Finished"
    }
}

function Invoke-ADCDeleteNetprofilenatrulebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the natrule that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER Natrule
        IPv4 network address on whose traffic you want the Citrix ADC to do rewrite ip prefix.
    .PARAMETER Netmask
        .
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetprofilenatrulebinding -Name <string>
        An example how to delete netprofile_natrule_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetprofilenatrulebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_natrule_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Natrule,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetprofilenatrulebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Natrule') ) { $arguments.Add('natrule', $Natrule) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetprofilenatrulebinding: Finished"
    }
}

function Invoke-ADCGetNetprofilenatrulebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the natrule that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER GetAll
        Retrieve all netprofile_natrule_binding object(s).
    .PARAMETER Count
        If specified, the count of the netprofile_natrule_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilenatrulebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilenatrulebinding -GetAll
        Get all netprofile_natrule_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilenatrulebinding -Count
        Get the number of netprofile_natrule_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilenatrulebinding -name <string>
        Get netprofile_natrule_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilenatrulebinding -Filter @{ 'name'='<value>' }
        Get netprofile_natrule_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetprofilenatrulebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_natrule_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetprofilenatrulebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netprofile_natrule_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netprofile_natrule_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netprofile_natrule_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netprofile_natrule_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netprofile_natrule_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_natrule_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetprofilenatrulebinding: Ended"
    }
}

function Invoke-ADCAddNetprofilesrcportsetbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the srcportset that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER Srcportrange
        When the source port range is configured and associated with the netprofile bound to a service group, Citrix ADC will choose a port from the range configured for connection establishment at the backend servers.
    .PARAMETER PassThru
        Return details about the created netprofile_srcportset_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddNetprofilesrcportsetbinding -name <string>
        An example how to add netprofile_srcportset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddNetprofilesrcportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_srcportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateLength(1024, 65535)]
        [string]$Srcportrange,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddNetprofilesrcportsetbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('srcportrange') ) { $payload.Add('srcportrange', $srcportrange) }
            if ( $PSCmdlet.ShouldProcess("netprofile_srcportset_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type netprofile_srcportset_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetNetprofilesrcportsetbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddNetprofilesrcportsetbinding: Finished"
    }
}

function Invoke-ADCDeleteNetprofilesrcportsetbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the srcportset that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER Srcportrange
        When the source port range is configured and associated with the netprofile bound to a service group, Citrix ADC will choose a port from the range configured for connection establishment at the backend servers.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteNetprofilesrcportsetbinding -Name <string>
        An example how to delete netprofile_srcportset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteNetprofilesrcportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_srcportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Srcportrange 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteNetprofilesrcportsetbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Srcportrange') ) { $arguments.Add('srcportrange', $Srcportrange) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteNetprofilesrcportsetbinding: Finished"
    }
}

function Invoke-ADCGetNetprofilesrcportsetbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the srcportset that can be bound to netprofile.
    .PARAMETER Name
        Name of the netprofile to which to bind port ranges.
    .PARAMETER GetAll
        Retrieve all netprofile_srcportset_binding object(s).
    .PARAMETER Count
        If specified, the count of the netprofile_srcportset_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilesrcportsetbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilesrcportsetbinding -GetAll
        Get all netprofile_srcportset_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilesrcportsetbinding -Count
        Get the number of netprofile_srcportset_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilesrcportsetbinding -name <string>
        Get netprofile_srcportset_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetNetprofilesrcportsetbinding -Filter @{ 'name'='<value>' }
        Get netprofile_srcportset_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetNetprofilesrcportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/netprofile_srcportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetNetprofilesrcportsetbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all netprofile_srcportset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for netprofile_srcportset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving netprofile_srcportset_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving netprofile_srcportset_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving netprofile_srcportset_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type netprofile_srcportset_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetNetprofilesrcportsetbinding: Ended"
    }
}

function Invoke-ADCAddOnlinkipv6prefix {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for on-link IPv6 global prefixes for Router Advertisment resource.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .PARAMETER Onlinkprefix
        RA Prefix onlink flag.
        Possible values = YES, NO
    .PARAMETER Autonomusprefix
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Depricateprefix
        Depricate the prefix.
        Possible values = YES, NO
    .PARAMETER Decrementprefixlifetimes
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Prefixvalidelifetime
        Valide life time of the prefix, in seconds.
    .PARAMETER Prefixpreferredlifetime
        Preferred life time of the prefix, in seconds.
    .PARAMETER PassThru
        Return details about the created onlinkipv6prefix item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddOnlinkipv6prefix -ipv6prefix <string>
        An example how to add onlinkipv6prefix configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddOnlinkipv6prefix
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/onlinkipv6prefix/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Ipv6prefix,

        [ValidateSet('YES', 'NO')]
        [string]$Onlinkprefix = 'YES',

        [ValidateSet('YES', 'NO')]
        [string]$Autonomusprefix = 'YES',

        [ValidateSet('YES', 'NO')]
        [string]$Depricateprefix = 'NO',

        [ValidateSet('YES', 'NO')]
        [string]$Decrementprefixlifetimes = 'NO',

        [double]$Prefixvalidelifetime = '2592000',

        [double]$Prefixpreferredlifetime = '604800',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddOnlinkipv6prefix: Starting"
    }
    process {
        try {
            $payload = @{ ipv6prefix = $ipv6prefix }
            if ( $PSBoundParameters.ContainsKey('onlinkprefix') ) { $payload.Add('onlinkprefix', $onlinkprefix) }
            if ( $PSBoundParameters.ContainsKey('autonomusprefix') ) { $payload.Add('autonomusprefix', $autonomusprefix) }
            if ( $PSBoundParameters.ContainsKey('depricateprefix') ) { $payload.Add('depricateprefix', $depricateprefix) }
            if ( $PSBoundParameters.ContainsKey('decrementprefixlifetimes') ) { $payload.Add('decrementprefixlifetimes', $decrementprefixlifetimes) }
            if ( $PSBoundParameters.ContainsKey('prefixvalidelifetime') ) { $payload.Add('prefixvalidelifetime', $prefixvalidelifetime) }
            if ( $PSBoundParameters.ContainsKey('prefixpreferredlifetime') ) { $payload.Add('prefixpreferredlifetime', $prefixpreferredlifetime) }
            if ( $PSCmdlet.ShouldProcess("onlinkipv6prefix", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type onlinkipv6prefix -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetOnlinkipv6prefix -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddOnlinkipv6prefix: Finished"
    }
}

function Invoke-ADCDeleteOnlinkipv6prefix {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for on-link IPv6 global prefixes for Router Advertisment resource.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteOnlinkipv6prefix -Ipv6prefix <string>
        An example how to delete onlinkipv6prefix configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteOnlinkipv6prefix
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/onlinkipv6prefix/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Ipv6prefix 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteOnlinkipv6prefix: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$ipv6prefix", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type onlinkipv6prefix -NitroPath nitro/v1/config -Resource $ipv6prefix -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteOnlinkipv6prefix: Finished"
    }
}

function Invoke-ADCUpdateOnlinkipv6prefix {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for on-link IPv6 global prefixes for Router Advertisment resource.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .PARAMETER Onlinkprefix
        RA Prefix onlink flag.
        Possible values = YES, NO
    .PARAMETER Autonomusprefix
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Depricateprefix
        Depricate the prefix.
        Possible values = YES, NO
    .PARAMETER Decrementprefixlifetimes
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Prefixvalidelifetime
        Valide life time of the prefix, in seconds.
    .PARAMETER Prefixpreferredlifetime
        Preferred life time of the prefix, in seconds.
    .PARAMETER PassThru
        Return details about the created onlinkipv6prefix item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateOnlinkipv6prefix -ipv6prefix <string>
        An example how to update onlinkipv6prefix configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateOnlinkipv6prefix
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/onlinkipv6prefix/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Ipv6prefix,

        [ValidateSet('YES', 'NO')]
        [string]$Onlinkprefix,

        [ValidateSet('YES', 'NO')]
        [string]$Autonomusprefix,

        [ValidateSet('YES', 'NO')]
        [string]$Depricateprefix,

        [ValidateSet('YES', 'NO')]
        [string]$Decrementprefixlifetimes,

        [double]$Prefixvalidelifetime,

        [double]$Prefixpreferredlifetime,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateOnlinkipv6prefix: Starting"
    }
    process {
        try {
            $payload = @{ ipv6prefix = $ipv6prefix }
            if ( $PSBoundParameters.ContainsKey('onlinkprefix') ) { $payload.Add('onlinkprefix', $onlinkprefix) }
            if ( $PSBoundParameters.ContainsKey('autonomusprefix') ) { $payload.Add('autonomusprefix', $autonomusprefix) }
            if ( $PSBoundParameters.ContainsKey('depricateprefix') ) { $payload.Add('depricateprefix', $depricateprefix) }
            if ( $PSBoundParameters.ContainsKey('decrementprefixlifetimes') ) { $payload.Add('decrementprefixlifetimes', $decrementprefixlifetimes) }
            if ( $PSBoundParameters.ContainsKey('prefixvalidelifetime') ) { $payload.Add('prefixvalidelifetime', $prefixvalidelifetime) }
            if ( $PSBoundParameters.ContainsKey('prefixpreferredlifetime') ) { $payload.Add('prefixpreferredlifetime', $prefixpreferredlifetime) }
            if ( $PSCmdlet.ShouldProcess("onlinkipv6prefix", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type onlinkipv6prefix -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetOnlinkipv6prefix -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateOnlinkipv6prefix: Finished"
    }
}

function Invoke-ADCUnsetOnlinkipv6prefix {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for on-link IPv6 global prefixes for Router Advertisment resource.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .PARAMETER Onlinkprefix
        RA Prefix onlink flag.
        Possible values = YES, NO
    .PARAMETER Autonomusprefix
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Depricateprefix
        Depricate the prefix.
        Possible values = YES, NO
    .PARAMETER Decrementprefixlifetimes
        RA Prefix Autonomus flag.
        Possible values = YES, NO
    .PARAMETER Prefixvalidelifetime
        Valide life time of the prefix, in seconds.
    .PARAMETER Prefixpreferredlifetime
        Preferred life time of the prefix, in seconds.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetOnlinkipv6prefix -ipv6prefix <string>
        An example how to unset onlinkipv6prefix configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetOnlinkipv6prefix
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/onlinkipv6prefix
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Ipv6prefix,

        [Boolean]$onlinkprefix,

        [Boolean]$autonomusprefix,

        [Boolean]$depricateprefix,

        [Boolean]$decrementprefixlifetimes,

        [Boolean]$prefixvalidelifetime,

        [Boolean]$prefixpreferredlifetime 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetOnlinkipv6prefix: Starting"
    }
    process {
        try {
            $payload = @{ ipv6prefix = $ipv6prefix }
            if ( $PSBoundParameters.ContainsKey('onlinkprefix') ) { $payload.Add('onlinkprefix', $onlinkprefix) }
            if ( $PSBoundParameters.ContainsKey('autonomusprefix') ) { $payload.Add('autonomusprefix', $autonomusprefix) }
            if ( $PSBoundParameters.ContainsKey('depricateprefix') ) { $payload.Add('depricateprefix', $depricateprefix) }
            if ( $PSBoundParameters.ContainsKey('decrementprefixlifetimes') ) { $payload.Add('decrementprefixlifetimes', $decrementprefixlifetimes) }
            if ( $PSBoundParameters.ContainsKey('prefixvalidelifetime') ) { $payload.Add('prefixvalidelifetime', $prefixvalidelifetime) }
            if ( $PSBoundParameters.ContainsKey('prefixpreferredlifetime') ) { $payload.Add('prefixpreferredlifetime', $prefixpreferredlifetime) }
            if ( $PSCmdlet.ShouldProcess("$ipv6prefix", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type onlinkipv6prefix -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetOnlinkipv6prefix: Finished"
    }
}

function Invoke-ADCGetOnlinkipv6prefix {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for on-link IPv6 global prefixes for Router Advertisment resource.
    .PARAMETER Ipv6prefix
        Onlink prefixes for RA messages.
    .PARAMETER GetAll
        Retrieve all onlinkipv6prefix object(s).
    .PARAMETER Count
        If specified, the count of the onlinkipv6prefix object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetOnlinkipv6prefix
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetOnlinkipv6prefix -GetAll
        Get all onlinkipv6prefix data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetOnlinkipv6prefix -Count
        Get the number of onlinkipv6prefix objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetOnlinkipv6prefix -name <string>
        Get onlinkipv6prefix object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetOnlinkipv6prefix -Filter @{ 'name'='<value>' }
        Get onlinkipv6prefix data with a filter.
    .NOTES
        File Name : Invoke-ADCGetOnlinkipv6prefix
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/onlinkipv6prefix/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [string]$Ipv6prefix,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetOnlinkipv6prefix: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all onlinkipv6prefix objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type onlinkipv6prefix -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for onlinkipv6prefix objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type onlinkipv6prefix -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving onlinkipv6prefix objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type onlinkipv6prefix -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving onlinkipv6prefix configuration for property 'ipv6prefix'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type onlinkipv6prefix -NitroPath nitro/v1/config -Resource $ipv6prefix -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving onlinkipv6prefix configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type onlinkipv6prefix -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetOnlinkipv6prefix: Ended"
    }
}

function Invoke-ADCUpdatePtp {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Precision Time Protocol resource.
    .PARAMETER State
        Enables or disables Precision Time Protocol (PTP) on the appliance. If you disable PTP, make sure you enable Network Time Protocol (NTP) on the cluster.
        Possible values = DISABLE, ENABLE
    .EXAMPLE
        PS C:\>Invoke-ADCUpdatePtp -state <string>
        An example how to update ptp configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdatePtp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ptp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateSet('DISABLE', 'ENABLE')]
        [string]$State 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdatePtp: Starting"
    }
    process {
        try {
            $payload = @{ state = $state }

            if ( $PSCmdlet.ShouldProcess("ptp", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type ptp -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdatePtp: Finished"
    }
}

function Invoke-ADCGetPtp {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Precision Time Protocol resource.
    .PARAMETER GetAll
        Retrieve all ptp object(s).
    .PARAMETER Count
        If specified, the count of the ptp object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetPtp
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetPtp -GetAll
        Get all ptp data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetPtp -name <string>
        Get ptp object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetPtp -Filter @{ 'name'='<value>' }
        Get ptp data with a filter.
    .NOTES
        File Name : Invoke-ADCGetPtp
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/ptp/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetPtp: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all ptp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ptp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for ptp objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ptp -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving ptp objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ptp -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving ptp configuration for property ''"

            } else {
                Write-Verbose "Retrieving ptp configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type ptp -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetPtp: Ended"
    }
}

function Invoke-ADCClearRnat {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Network
        The network address defined for the RNAT entry.
    .PARAMETER Netmask
        The subnet mask for the network address.
    .PARAMETER Aclname
        An extended ACL defined for the RNAT entry.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .EXAMPLE
        PS C:\>Invoke-ADCClearRnat
        An example how to clear rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup 

    )
    begin {
        Write-Verbose "Invoke-ADCClearRnat: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnat -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearRnat: Finished"
    }
}

function Invoke-ADCUpdateRnat {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .PARAMETER Network
        The network address defined for the RNAT entry.
    .PARAMETER Netmask
        The subnet mask for the network address.
    .PARAMETER Aclname
        An extended ACL defined for the RNAT entry.
    .PARAMETER Redirectport
        Port number to which the IPv4 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Natip
        Any NetScaler-owned IPv4 address except the NSIP address. The NetScaler appliance replaces the source IP addresses of server-generated packets with the IP address specified. The IP address must be a public NetScaler-owned IP address. If you specify multiple addresses for this field, NATIP selection uses the round robin algorithm for each session. By specifying a range of IP addresses, you can specify all NetScaler-owned IP addresses, except the NSIP, that fall within the specified range.
    .PARAMETER Srcippersistency
        Enables the Citrix ADC to use the same NAT IP address for all RNAT sessions initiated from a particular server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Useproxyport
        Enable source port proxying, which enables the Citrix ADC to use the RNAT ips using proxied source port.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the RNAT session. In order for this to work, tcpproxy should be DISABLED. To disable tcpproxy use "set rnatparam tcpproxy DISABLED".
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created rnat item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRnat
        An example how to update rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname,

        [ValidateRange(1, 65535)]
        [int]$Redirectport,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Natip,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Useproxyport,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRnat: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('name') ) { $payload.Add('name', $name) }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('natip') ) { $payload.Add('natip', $natip) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSCmdlet.ShouldProcess("rnat", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnat -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRnat: Finished"
    }
}

function Invoke-ADCUnsetRnat {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .PARAMETER Network
        The network address defined for the RNAT entry.
    .PARAMETER Netmask
        The subnet mask for the network address.
    .PARAMETER Aclname
        An extended ACL defined for the RNAT entry.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Redirectport
        Port number to which the IPv4 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Natip
        Any NetScaler-owned IPv4 address except the NSIP address. The NetScaler appliance replaces the source IP addresses of server-generated packets with the IP address specified. The IP address must be a public NetScaler-owned IP address. If you specify multiple addresses for this field, NATIP selection uses the round robin algorithm for each session. By specifying a range of IP addresses, you can specify all NetScaler-owned IP addresses, except the NSIP, that fall within the specified range.
    .PARAMETER Srcippersistency
        Enables the Citrix ADC to use the same NAT IP address for all RNAT sessions initiated from a particular server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER Useproxyport
        Enable source port proxying, which enables the Citrix ADC to use the RNAT ips using proxied source port.
        Possible values = ENABLED, DISABLED
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the RNAT session. In order for this to work, tcpproxy should be DISABLED. To disable tcpproxy use "set rnatparam tcpproxy DISABLED".
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetRnat
        An example how to unset rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$name,

        [Boolean]$network,

        [Boolean]$netmask,

        [Boolean]$aclname,

        [Boolean]$td,

        [Boolean]$redirectport,

        [Boolean]$natip,

        [Boolean]$srcippersistency,

        [Boolean]$ownergroup,

        [Boolean]$useproxyport,

        [Boolean]$connfailover 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetRnat: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('name') ) { $payload.Add('name', $name) }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('natip') ) { $payload.Add('natip', $natip) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSCmdlet.ShouldProcess("rnat", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type rnat -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetRnat: Finished"
    }
}

function Invoke-ADCAddRnat {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .PARAMETER Network
        The network address defined for the RNAT entry.
    .PARAMETER Netmask
        The subnet mask for the network address.
    .PARAMETER Aclname
        An extended ACL defined for the RNAT entry.
    .PARAMETER Redirectport
        Port number to which the IPv4 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Srcippersistency
        Enables the Citrix ADC to use the same NAT IP address for all RNAT sessions initiated from a particular server.
        Possible values = ENABLED, DISABLED
    .PARAMETER Useproxyport
        Enable source port proxying, which enables the Citrix ADC to use the RNAT ips using proxied source port.
        Possible values = ENABLED, DISABLED
    .PARAMETER Connfailover
        Synchronize connection information with the secondary appliance in a high availability (HA) pair. That is, synchronize all connection-related information for the RNAT session. In order for this to work, tcpproxy should be DISABLED. To disable tcpproxy use "set rnatparam tcpproxy DISABLED".
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER PassThru
        Return details about the created rnat item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnat -name <string>
        An example how to add rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname,

        [ValidateRange(1, 65535)]
        [int]$Redirectport,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Useproxyport = 'ENABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Connfailover = 'DISABLED',

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnat: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('useproxyport') ) { $payload.Add('useproxyport', $useproxyport) }
            if ( $PSBoundParameters.ContainsKey('connfailover') ) { $payload.Add('connfailover', $connfailover) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("rnat", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnat -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnat: Finished"
    }
}

function Invoke-ADCRenameRnat {
    <#
    .SYNOPSIS
        Rename Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .PARAMETER Newname
        New name for the RNAT4 rule. Must begin with an ASCII alphabetic or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters.
    .PARAMETER PassThru
        Return details about the created rnat item.
    .EXAMPLE
        PS C:\>Invoke-ADCRenameRnat -name <string> -newname <string>
        An example how to rename rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCRenameRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [ValidatePattern('^(([a-zA-Z0-9]|[_])+([\x00-\x7F]|[_]|[#]|[.][ ]|[:]|[@]|[=]|[-])+)$')]
        [string]$Newname,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCRenameRnat: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                newname        = $newname
            }

            if ( $PSCmdlet.ShouldProcess("rnat", "Rename Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnat -Action rename -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCRenameRnat: Finished"
    }
}

function Invoke-ADCDeleteRnat {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRnat -Name <string>
        An example how to delete rnat configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRnat: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type rnat -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRnat: Finished"
    }
}

function Invoke-ADCGetRnat {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT4 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT4 rule.
    .PARAMETER GetAll
        Retrieve all rnat object(s).
    .PARAMETER Count
        If specified, the count of the rnat object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat -GetAll
        Get all rnat data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat -Count
        Get the number of rnat objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat -name <string>
        Get rnat object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat -Filter @{ 'name'='<value>' }
        Get rnat data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnat
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetRnat: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all rnat objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnat: Ended"
    }
}

function Invoke-ADCAddRnat6 {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for IPv6 RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT6 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT6 rule.
    .PARAMETER Network
        IPv6 address of the network on whose traffic you want the Citrix ADC to do RNAT processing.
    .PARAMETER Acl6name
        Name of any configured ACL6 whose action is ALLOW. The rule of the ACL6 is used as an RNAT6 rule.
    .PARAMETER Redirectport
        Port number to which the IPv6 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Srcippersistency
        Enable source ip persistency, which enables the Citrix ADC to use the RNAT ips using source ip.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER PassThru
        Return details about the created rnat6 item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnat6 -name <string>
        An example how to add rnat6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnat6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Acl6name,

        [ValidateRange(1, 65535)]
        [int]$Redirectport,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency = 'DISABLED',

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnat6: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('acl6name') ) { $payload.Add('acl6name', $acl6name) }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("rnat6", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnat6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat6 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnat6: Finished"
    }
}

function Invoke-ADCUpdateRnat6 {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for IPv6 RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT6 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT6 rule.
    .PARAMETER Redirectport
        Port number to which the IPv6 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Srcippersistency
        Enable source ip persistency, which enables the Citrix ADC to use the RNAT ips using source ip.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER PassThru
        Return details about the created rnat6 item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRnat6 -name <string>
        An example how to update rnat6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRnat6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateRange(1, 65535)]
        [int]$Redirectport,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRnat6: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("rnat6", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnat6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat6 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRnat6: Finished"
    }
}

function Invoke-ADCUnsetRnat6 {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for IPv6 RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT6 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT6 rule.
    .PARAMETER Redirectport
        Port number to which the IPv6 packets are redirected. Applicable to TCP and UDP protocols.
    .PARAMETER Srcippersistency
        Enable source ip persistency, which enables the Citrix ADC to use the RNAT ips using source ip.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetRnat6 -name <string>
        An example how to unset rnat6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetRnat6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Boolean]$redirectport,

        [Boolean]$srcippersistency,

        [Boolean]$ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetRnat6: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('redirectport') ) { $payload.Add('redirectport', $redirectport) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$name", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type rnat6 -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetRnat6: Finished"
    }
}

function Invoke-ADCClearRnat6 {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for IPv6 RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT6 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT6 rule.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .EXAMPLE
        PS C:\>Invoke-ADCClearRnat6 -name <string>
        An example how to clear rnat6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearRnat6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup 

    )
    begin {
        Write-Verbose "Invoke-ADCClearRnat6: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnat6 -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearRnat6: Finished"
    }
}

function Invoke-ADCGetRnat6 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for IPv6 RNAT configured route resource.
    .PARAMETER Name
        Name for the RNAT6 rule. Must begin with a letter, number, or the underscore character (_), and can consist of letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore characters. Cannot be changed after the rule is created. Choose a name that helps identify the RNAT6 rule.
    .PARAMETER GetAll
        Retrieve all rnat6 object(s).
    .PARAMETER Count
        If specified, the count of the rnat6 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6 -GetAll
        Get all rnat6 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6 -Count
        Get the number of rnat6 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6 -name <string>
        Get rnat6 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6 -Filter @{ 'name'='<value>' }
        Get rnat6 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnat6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetRnat6: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all rnat6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat6 objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat6 configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6 -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat6 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnat6: Ended"
    }
}

function Invoke-ADCGetRnat6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to rnat6.
    .PARAMETER Name
        Name of the RNAT6 rule whose details you want to display.
    .PARAMETER GetAll
        Retrieve all rnat6_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnat6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6binding -GetAll
        Get all rnat6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6binding -name <string>
        Get rnat6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6binding -Filter @{ 'name'='<value>' }
        Get rnat6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnat6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnat6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnat6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat6_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnat6binding: Ended"
    }
}

function Invoke-ADCAddRnat6nsip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to rnat6.
    .PARAMETER Name
        Name of the RNAT6 rule to which to bind NAT IPs.
    .PARAMETER Natip6
        Nat IP Address.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .PARAMETER PassThru
        Return details about the created rnat6_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnat6nsip6binding -name <string> -natip6 <string>
        An example how to add rnat6_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnat6nsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Natip6,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnat6nsip6binding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name
                natip6         = $natip6
            }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("rnat6_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnat6_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnat6nsip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnat6nsip6binding: Finished"
    }
}

function Invoke-ADCDeleteRnat6nsip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to rnat6.
    .PARAMETER Name
        Name of the RNAT6 rule to which to bind NAT IPs.
    .PARAMETER Natip6
        Nat IP Address.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this rnat rule.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRnat6nsip6binding -Name <string>
        An example how to delete rnat6_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRnat6nsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Natip6,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRnat6nsip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Natip6') ) { $arguments.Add('natip6', $Natip6) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRnat6nsip6binding: Finished"
    }
}

function Invoke-ADCGetRnat6nsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to rnat6.
    .PARAMETER Name
        Name of the RNAT6 rule to which to bind NAT IPs.
    .PARAMETER GetAll
        Retrieve all rnat6_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnat6_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6nsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6nsip6binding -GetAll
        Get all rnat6_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6nsip6binding -Count
        Get the number of rnat6_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6nsip6binding -name <string>
        Get rnat6_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnat6nsip6binding -Filter @{ 'name'='<value>' }
        Get rnat6_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnat6nsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat6_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnat6nsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnat6_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat6_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat6_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat6_nsip6_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat6_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat6_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnat6nsip6binding: Ended"
    }
}

function Invoke-ADCAddRnatglobalauditsyslogpolicybinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the auditsyslogpolicy that can be bound to rnatglobal.
    .PARAMETER Policy
        The policy Name.
    .PARAMETER Priority
        The priority of the policy.
    .PARAMETER PassThru
        Return details about the created rnatglobal_auditsyslogpolicy_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnatglobalauditsyslogpolicybinding
        An example how to add rnatglobal_auditsyslogpolicy_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnatglobalauditsyslogpolicybinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatglobal_auditsyslogpolicy_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Policy,

        [double]$Priority,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnatglobalauditsyslogpolicybinding: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('policy') ) { $payload.Add('policy', $policy) }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSCmdlet.ShouldProcess("rnatglobal_auditsyslogpolicy_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnatglobal_auditsyslogpolicy_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnatglobalauditsyslogpolicybinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnatglobalauditsyslogpolicybinding: Finished"
    }
}

function Invoke-ADCDeleteRnatglobalauditsyslogpolicybinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the auditsyslogpolicy that can be bound to rnatglobal.
    .PARAMETER Policy
        The policy Name.
    .PARAMETER All
        Remove all RNAT global config.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRnatglobalauditsyslogpolicybinding
        An example how to delete rnatglobal_auditsyslogpolicy_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRnatglobalauditsyslogpolicybinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatglobal_auditsyslogpolicy_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Policy,

        [boolean]$All 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRnatglobalauditsyslogpolicybinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Policy') ) { $arguments.Add('policy', $Policy) }
            if ( $PSBoundParameters.ContainsKey('All') ) { $arguments.Add('all', $All) }
            if ( $PSCmdlet.ShouldProcess("rnatglobal_auditsyslogpolicy_binding", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type rnatglobal_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Resource $ -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRnatglobalauditsyslogpolicybinding: Finished"
    }
}

function Invoke-ADCGetRnatglobalauditsyslogpolicybinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the auditsyslogpolicy that can be bound to rnatglobal.
    .PARAMETER GetAll
        Retrieve all rnatglobal_auditsyslogpolicy_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnatglobal_auditsyslogpolicy_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalauditsyslogpolicybinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalauditsyslogpolicybinding -GetAll
        Get all rnatglobal_auditsyslogpolicy_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalauditsyslogpolicybinding -Count
        Get the number of rnatglobal_auditsyslogpolicy_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalauditsyslogpolicybinding -name <string>
        Get rnatglobal_auditsyslogpolicy_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalauditsyslogpolicybinding -Filter @{ 'name'='<value>' }
        Get rnatglobal_auditsyslogpolicy_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatglobalauditsyslogpolicybinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatglobal_auditsyslogpolicy_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatglobalauditsyslogpolicybinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnatglobal_auditsyslogpolicy_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnatglobal_auditsyslogpolicy_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnatglobal_auditsyslogpolicy_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnatglobal_auditsyslogpolicy_binding configuration for property ''"

            } else {
                Write-Verbose "Retrieving rnatglobal_auditsyslogpolicy_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_auditsyslogpolicy_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatglobalauditsyslogpolicybinding: Ended"
    }
}

function Invoke-ADCGetRnatglobalbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to rnatglobal.
    .PARAMETER GetAll
        Retrieve all rnatglobal_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnatglobal_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalbinding -GetAll
        Get all rnatglobal_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalbinding -name <string>
        Get rnatglobal_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatglobalbinding -Filter @{ 'name'='<value>' }
        Get rnatglobal_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatglobalbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatglobal_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatglobalbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnatglobal_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnatglobal_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnatglobal_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnatglobal_binding configuration for property ''"

            } else {
                Write-Verbose "Retrieving rnatglobal_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatglobal_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatglobalbinding: Ended"
    }
}

function Invoke-ADCUpdateRnatparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT parameter resource.
    .PARAMETER Tcpproxy
        Enable TCP proxy, which enables the Citrix ADC to optimize the RNAT TCP traffic by using Layer 4 features.
        Possible values = ENABLED, DISABLED
    .PARAMETER Srcippersistency
        Enable source ip persistency, which enables the Citrix ADC to use the RNAT ips using source ip.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRnatparam
        An example how to update rnatparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRnatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Tcpproxy,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Srcippersistency 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRnatparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('tcpproxy') ) { $payload.Add('tcpproxy', $tcpproxy) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSCmdlet.ShouldProcess("rnatparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnatparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRnatparam: Finished"
    }
}

function Invoke-ADCUnsetRnatparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT parameter resource.
    .PARAMETER Tcpproxy
        Enable TCP proxy, which enables the Citrix ADC to optimize the RNAT TCP traffic by using Layer 4 features.
        Possible values = ENABLED, DISABLED
    .PARAMETER Srcippersistency
        Enable source ip persistency, which enables the Citrix ADC to use the RNAT ips using source ip.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetRnatparam
        An example how to unset rnatparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetRnatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$tcpproxy,

        [Boolean]$srcippersistency 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetRnatparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('tcpproxy') ) { $payload.Add('tcpproxy', $tcpproxy) }
            if ( $PSBoundParameters.ContainsKey('srcippersistency') ) { $payload.Add('srcippersistency', $srcippersistency) }
            if ( $PSCmdlet.ShouldProcess("rnatparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type rnatparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetRnatparam: Finished"
    }
}

function Invoke-ADCGetRnatparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for RNAT parameter resource.
    .PARAMETER GetAll
        Retrieve all rnatparam object(s).
    .PARAMETER Count
        If specified, the count of the rnatparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatparam -GetAll
        Get all rnatparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatparam -name <string>
        Get rnatparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatparam -Filter @{ 'name'='<value>' }
        Get rnatparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all rnatparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnatparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnatparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnatparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving rnatparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnatparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatparam: Ended"
    }
}

function Invoke-ADCFlushRnatsession {
    <#
    .SYNOPSIS
        Flush Network configuration Object.
    .DESCRIPTION
        Configuration for RNAT session resource.
    .PARAMETER Network
        IPv4 network address on whose traffic you want the Citrix ADC to do RNAT processing.
    .PARAMETER Netmask
        Subnet mask associated with the network address.
    .PARAMETER Natip
        The NAT IP address defined for the RNAT entry.
    .PARAMETER Aclname
        Name of any configured extended ACL whose action is ALLOW.
    .EXAMPLE
        PS C:\>Invoke-ADCFlushRnatsession
        An example how to flush rnatsession configuration Object(s).
    .NOTES
        File Name : Invoke-ADCFlushRnatsession
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnatsession/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Network,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Natip,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Aclname 

    )
    begin {
        Write-Verbose "Invoke-ADCFlushRnatsession: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('network') ) { $payload.Add('network', $network) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('natip') ) { $payload.Add('natip', $natip) }
            if ( $PSBoundParameters.ContainsKey('aclname') ) { $payload.Add('aclname', $aclname) }
            if ( $PSCmdlet.ShouldProcess($Name, "Flush Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type rnatsession -Action flush -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCFlushRnatsession: Finished"
    }
}

function Invoke-ADCGetRnatbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule whose details you want to display.
    .PARAMETER GetAll
        Retrieve all rnat_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnat_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatbinding -GetAll
        Get all rnat_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatbinding -name <string>
        Get rnat_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatbinding -Filter @{ 'name'='<value>' }
        Get rnat_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnat_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatbinding: Ended"
    }
}

function Invoke-ADCAddRnatnsipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER Natip
        Any NetScaler-owned IPv4 address except the NSIP address. The NetScaler appliance replaces the source IP addresses of server-generated packets with the IP address specified. The IP address must be a public NetScaler-owned IP address. If you specify multiple addresses for this field, NATIP selection uses the round robin algorithm for each session. By specifying a range of IP addresses, you can specify all NetScaler-owned IP addresses, except the NSIP, that fall within the specified range.
    .PARAMETER PassThru
        Return details about the created rnat_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnatnsipbinding -name <string>
        An example how to add rnat_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnatnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Natip,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnatnsipbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('natip') ) { $payload.Add('natip', $natip) }
            if ( $PSCmdlet.ShouldProcess("rnat_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnat_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnatnsipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnatnsipbinding: Finished"
    }
}

function Invoke-ADCDeleteRnatnsipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER Natip
        Any NetScaler-owned IPv4 address except the NSIP address. The NetScaler appliance replaces the source IP addresses of server-generated packets with the IP address specified. The IP address must be a public NetScaler-owned IP address. If you specify multiple addresses for this field, NATIP selection uses the round robin algorithm for each session. By specifying a range of IP addresses, you can specify all NetScaler-owned IP addresses, except the NSIP, that fall within the specified range.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRnatnsipbinding -Name <string>
        An example how to delete rnat_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRnatnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Natip 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRnatnsipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Natip') ) { $arguments.Add('natip', $Natip) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type rnat_nsip_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRnatnsipbinding: Finished"
    }
}

function Invoke-ADCGetRnatnsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER GetAll
        Retrieve all rnat_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnat_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatnsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatnsipbinding -GetAll
        Get all rnat_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatnsipbinding -Count
        Get the number of rnat_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatnsipbinding -name <string>
        Get rnat_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatnsipbinding -Filter @{ 'name'='<value>' }
        Get rnat_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatnsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnat_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat_nsip_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_nsip_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatnsipbinding: Ended"
    }
}

function Invoke-ADCAddRnatretainsourceportsetbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the retainsourceportset that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER Retainsourceportrange
        When the source port range is configured and associated with the RNAT rule, Citrix ADC will choose a port from the specified source port range configured for connection establishment at the backend servers.
    .PARAMETER PassThru
        Return details about the created rnat_retainsourceportset_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRnatretainsourceportsetbinding -name <string>
        An example how to add rnat_retainsourceportset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRnatretainsourceportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_retainsourceportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateLength(1024, 65535)]
        [string]$Retainsourceportrange,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRnatretainsourceportsetbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('retainsourceportrange') ) { $payload.Add('retainsourceportrange', $retainsourceportrange) }
            if ( $PSCmdlet.ShouldProcess("rnat_retainsourceportset_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rnat_retainsourceportset_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetRnatretainsourceportsetbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRnatretainsourceportsetbinding: Finished"
    }
}

function Invoke-ADCDeleteRnatretainsourceportsetbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the retainsourceportset that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER Retainsourceportrange
        When the source port range is configured and associated with the RNAT rule, Citrix ADC will choose a port from the specified source port range configured for connection establishment at the backend servers.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRnatretainsourceportsetbinding -Name <string>
        An example how to delete rnat_retainsourceportset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRnatretainsourceportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_retainsourceportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [string]$Retainsourceportrange 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRnatretainsourceportsetbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Retainsourceportrange') ) { $arguments.Add('retainsourceportrange', $Retainsourceportrange) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRnatretainsourceportsetbinding: Finished"
    }
}

function Invoke-ADCGetRnatretainsourceportsetbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the retainsourceportset that can be bound to rnat.
    .PARAMETER Name
        Name of the RNAT rule to which to bind NAT IPs.
    .PARAMETER GetAll
        Retrieve all rnat_retainsourceportset_binding object(s).
    .PARAMETER Count
        If specified, the count of the rnat_retainsourceportset_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatretainsourceportsetbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatretainsourceportsetbinding -GetAll
        Get all rnat_retainsourceportset_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatretainsourceportsetbinding -Count
        Get the number of rnat_retainsourceportset_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatretainsourceportsetbinding -name <string>
        Get rnat_retainsourceportset_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRnatretainsourceportsetbinding -Filter @{ 'name'='<value>' }
        Get rnat_retainsourceportset_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRnatretainsourceportsetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rnat_retainsourceportset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRnatretainsourceportsetbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all rnat_retainsourceportset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rnat_retainsourceportset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rnat_retainsourceportset_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rnat_retainsourceportset_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving rnat_retainsourceportset_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rnat_retainsourceportset_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRnatretainsourceportsetbinding: Ended"
    }
}

function Invoke-ADCAddRoute {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Network
        IPv4 network address for which to add a route entry in the routing table of the Citrix ADC.
    .PARAMETER Netmask
        The subnet mask associated with the network address.
    .PARAMETER Gateway
        IP address of the gateway for this route. Can be either the IP address of the gateway, or can be null to specify a null interface route.
    .PARAMETER Vlan
        VLAN as the gateway for this route.
    .PARAMETER Cost
        Positive integer used by the routing algorithms to determine preference for using this route. The lower the cost, the higher the preference.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Distance
        Administrative distance of this route, which determines the preference of this route over other routes, with same destination, from different routing protocols. A lower value is preferred.
    .PARAMETER Cost1
        The cost of a route is used to compare routes of the same type. The route having the lowest cost is the most preferred route. Possible values: 0 through 65535. Default: 0.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Protocol
        Routing protocol used for advertising this route.
        Possible values = OSPF, ISIS, RIP, BGP
    .PARAMETER Msr
        Monitor this route using a monitor of type ARP or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ARP or PING, configured on the Citrix ADC to monitor this route.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this route. If owner node group is not specified then the route is treated as Striped route.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRoute -network <string> -netmask <string>
        An example how to add route configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [Parameter(Mandatory)]
        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Gateway,

        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [ValidateRange(0, 65535)]
        [double]$Cost,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateRange(0, 255)]
        [double]$Distance = '1',

        [ValidateRange(0, 65535)]
        [double]$Cost1,

        [ValidateRange(1, 65535)]
        [double]$Weight = '1',

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Advertise,

        [ValidateSet('OSPF', 'ISIS', 'RIP', 'BGP')]
        [string[]]$Protocol = 'ADV_ROUTE_FLAGS',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Msr = 'DISABLED',

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Monitor,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG' 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRoute: Starting"
    }
    process {
        try {
            $payload = @{ network = $network
                netmask           = $netmask
            }
            if ( $PSBoundParameters.ContainsKey('gateway') ) { $payload.Add('gateway', $gateway) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('cost') ) { $payload.Add('cost', $cost) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost1') ) { $payload.Add('cost1', $cost1) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('protocol') ) { $payload.Add('protocol', $protocol) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("route", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type route -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRoute: Finished"
    }
}

function Invoke-ADCClearRoute {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Routetype
        Protocol used by routes that you want to remove from the routing table of the Citrix ADC.
        Possible values = CONNECTED, STATIC, DYNAMIC, OSPF, ISIS, RIP, BGP
    .EXAMPLE
        PS C:\>Invoke-ADCClearRoute -routetype <string>
        An example how to clear route configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateSet('CONNECTED', 'STATIC', 'DYNAMIC', 'OSPF', 'ISIS', 'RIP', 'BGP')]
        [string]$Routetype 

    )
    begin {
        Write-Verbose "Invoke-ADCClearRoute: Starting"
    }
    process {
        try {
            $payload = @{ routetype = $routetype }

            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type route -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearRoute: Finished"
    }
}

function Invoke-ADCDeleteRoute {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Network
        IPv4 network address for which to add a route entry in the routing table of the Citrix ADC.
    .PARAMETER Netmask
        The subnet mask associated with the network address.
    .PARAMETER Gateway
        IP address of the gateway for this route. Can be either the IP address of the gateway, or can be null to specify a null interface route.
    .PARAMETER Vlan
        VLAN as the gateway for this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this route. If owner node group is not specified then the route is treated as Striped route.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRoute -Network <string>
        An example how to delete route configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [string]$Netmask,

        [string]$Gateway,

        [double]$Vlan,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRoute: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSBoundParameters.ContainsKey('Gateway') ) { $arguments.Add('gateway', $Gateway) }
            if ( $PSBoundParameters.ContainsKey('Vlan') ) { $arguments.Add('vlan', $Vlan) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$network", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type route -NitroPath nitro/v1/config -Resource $network -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRoute: Finished"
    }
}

function Invoke-ADCUpdateRoute {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Network
        IPv4 network address for which to add a route entry in the routing table of the Citrix ADC.
    .PARAMETER Netmask
        The subnet mask associated with the network address.
    .PARAMETER Gateway
        IP address of the gateway for this route. Can be either the IP address of the gateway, or can be null to specify a null interface route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Distance
        Administrative distance of this route, which determines the preference of this route over other routes, with same destination, from different routing protocols. A lower value is preferred.
    .PARAMETER Cost1
        The cost of a route is used to compare routes of the same type. The route having the lowest cost is the most preferred route. Possible values: 0 through 65535. Default: 0.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Protocol
        Routing protocol used for advertising this route.
        Possible values = OSPF, ISIS, RIP, BGP
    .PARAMETER Msr
        Monitor this route using a monitor of type ARP or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ARP or PING, configured on the Citrix ADC to monitor this route.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRoute -network <string> -netmask <string> -gateway <string>
        An example how to update route configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [Parameter(Mandatory)]
        [string]$Netmask,

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Gateway,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateRange(0, 255)]
        [double]$Distance,

        [ValidateRange(0, 65535)]
        [double]$Cost1,

        [ValidateRange(1, 65535)]
        [double]$Weight,

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Advertise,

        [ValidateSet('OSPF', 'ISIS', 'RIP', 'BGP')]
        [string[]]$Protocol,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Msr,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Monitor 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRoute: Starting"
    }
    process {
        try {
            $payload = @{ network = $network
                netmask           = $netmask
                gateway           = $gateway
            }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost1') ) { $payload.Add('cost1', $cost1) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('protocol') ) { $payload.Add('protocol', $protocol) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSCmdlet.ShouldProcess("route", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type route -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRoute: Finished"
    }
}

function Invoke-ADCUnsetRoute {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Network
        IPv4 network address for which to add a route entry in the routing table of the Citrix ADC.
    .PARAMETER Netmask
        The subnet mask associated with the network address.
    .PARAMETER Gateway
        IP address of the gateway for this route. Can be either the IP address of the gateway, or can be null to specify a null interface route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Distance
        Administrative distance of this route, which determines the preference of this route over other routes, with same destination, from different routing protocols. A lower value is preferred.
    .PARAMETER Cost1
        The cost of a route is used to compare routes of the same type. The route having the lowest cost is the most preferred route. Possible values: 0 through 65535. Default: 0.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Protocol
        Routing protocol used for advertising this route.
        Possible values = OSPF, ISIS, RIP, BGP
    .PARAMETER Msr
        Monitor this route using a monitor of type ARP or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ARP or PING, configured on the Citrix ADC to monitor this route.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetRoute -network <string> -netmask <string> -gateway <string>
        An example how to unset route configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Network,

        [string]$Netmask,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Gateway,

        [Boolean]$td,

        [Boolean]$advertise,

        [Boolean]$distance,

        [Boolean]$cost1,

        [Boolean]$weight,

        [Boolean]$protocol,

        [Boolean]$msr,

        [Boolean]$monitor 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetRoute: Starting"
    }
    process {
        try {
            $payload = @{ network = $network
                netmask           = $netmask
                gateway           = $gateway
            }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost1') ) { $payload.Add('cost1', $cost1) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('protocol') ) { $payload.Add('protocol', $protocol) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSCmdlet.ShouldProcess("$network netmask gateway", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type route -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetRoute: Finished"
    }
}

function Invoke-ADCGetRoute {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for route resource.
    .PARAMETER Network
        IPv4 network address for which to add a route entry in the routing table of the Citrix ADC.
    .PARAMETER Netmask
        The subnet mask associated with the network address.
    .PARAMETER Gateway
        IP address of the gateway for this route. Can be either the IP address of the gateway, or can be null to specify a null interface route.
    .PARAMETER Vlan
        VLAN as the gateway for this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Routetype
        Protocol used by routes that you want to remove from the routing table of the Citrix ADC.
        Possible values = CONNECTED, STATIC, DYNAMIC, OSPF, ISIS, RIP, BGP
    .PARAMETER Detail
        Display a detailed view.
    .PARAMETER GetAll
        Retrieve all route object(s).
    .PARAMETER Count
        If specified, the count of the route object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute -GetAll
        Get all route data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute -Count
        Get the number of route objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute -name <string>
        Get route object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute -Filter @{ 'name'='<value>' }
        Get route data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRoute
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByArgument')]
        [string]$Network,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [string]$Netmask,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Gateway,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(1, 4094)]
        [double]$Vlan,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateSet('CONNECTED', 'STATIC', 'DYNAMIC', 'OSPF', 'ISIS', 'RIP', 'BGP')]
        [string]$Routetype,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [boolean]$Detail,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetRoute: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all route objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for route objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving route objects by arguments"
                $arguments = @{ } 
                if ( $PSBoundParameters.ContainsKey('network') ) { $arguments.Add('network', $network) } 
                if ( $PSBoundParameters.ContainsKey('netmask') ) { $arguments.Add('netmask', $netmask) } 
                if ( $PSBoundParameters.ContainsKey('gateway') ) { $arguments.Add('gateway', $gateway) } 
                if ( $PSBoundParameters.ContainsKey('vlan') ) { $arguments.Add('vlan', $vlan) } 
                if ( $PSBoundParameters.ContainsKey('td') ) { $arguments.Add('td', $td) } 
                if ( $PSBoundParameters.ContainsKey('routetype') ) { $arguments.Add('routetype', $routetype) } 
                if ( $PSBoundParameters.ContainsKey('detail') ) { $arguments.Add('detail', $detail) }
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving route configuration for property ''"

            } else {
                Write-Verbose "Retrieving route configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRoute: Ended"
    }
}

function Invoke-ADCAddRoute6 {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Network
        IPv6 network address for which to add a route entry to the routing table of the Citrix ADC.
    .PARAMETER Gateway
        The gateway for this route. The value for this parameter is either an IPv6 address or null.
    .PARAMETER Vlan
        Integer value that uniquely identifies a VLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Vxlan
        Integer value that uniquely identifies a VXLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Distance
        Administrative distance of this route from the appliance.
    .PARAMETER Cost
        Positive integer used by the routing algorithms to determine preference for this route. The lower the cost, the higher the preference.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Msr
        Monitor this route with a monitor of type ND6 or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ND6 or PING, configured on the Citrix ADC to monitor this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this route6. If owner node group is not specified then the route is treated as Striped route.
    .EXAMPLE
        PS C:\>Invoke-ADCAddRoute6 -network <string>
        An example how to add route6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [string]$Gateway = '0',

        [ValidateRange(0, 4094)]
        [double]$Vlan = '0',

        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [ValidateRange(1, 65535)]
        [double]$Weight = '1',

        [ValidateRange(1, 254)]
        [double]$Distance = '1',

        [ValidateRange(0, 65535)]
        [double]$Cost = '1',

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Advertise,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Msr = 'DISABLED',

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Monitor,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG' 
    )
    begin {
        Write-Verbose "Invoke-ADCAddRoute6: Starting"
    }
    process {
        try {
            $payload = @{ network = $network }
            if ( $PSBoundParameters.ContainsKey('gateway') ) { $payload.Add('gateway', $gateway) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost') ) { $payload.Add('cost', $cost) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("route6", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type route6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddRoute6: Finished"
    }
}

function Invoke-ADCClearRoute6 {
    <#
    .SYNOPSIS
        Clear Network configuration Object.
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Routetype
        Type of IPv6 routes to remove from the routing table of the Citrix ADC.
        Possible values = CONNECTED, STATIC, DYNAMIC, OSPF, ISIS, BGP, RIP, ND-RA-ROUTE, FIB6
    .EXAMPLE
        PS C:\>Invoke-ADCClearRoute6 -routetype <string>
        An example how to clear route6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCClearRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateSet('CONNECTED', 'STATIC', 'DYNAMIC', 'OSPF', 'ISIS', 'BGP', 'RIP', 'ND-RA-ROUTE', 'FIB6')]
        [string]$Routetype 

    )
    begin {
        Write-Verbose "Invoke-ADCClearRoute6: Starting"
    }
    process {
        try {
            $payload = @{ routetype = $routetype }

            if ( $PSCmdlet.ShouldProcess($Name, "Clear Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type route6 -Action clear -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCClearRoute6: Finished"
    }
}

function Invoke-ADCDeleteRoute6 {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Network
        IPv6 network address for which to add a route entry to the routing table of the Citrix ADC.
    .PARAMETER Gateway
        The gateway for this route. The value for this parameter is either an IPv6 address or null.
    .PARAMETER Vlan
        Integer value that uniquely identifies a VLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Vxlan
        Integer value that uniquely identifies a VXLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this route6. If owner node group is not specified then the route is treated as Striped route.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteRoute6 -Network <string>
        An example how to delete route6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [string]$Gateway,

        [double]$Vlan,

        [double]$Vxlan,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteRoute6: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Gateway') ) { $arguments.Add('gateway', $Gateway) }
            if ( $PSBoundParameters.ContainsKey('Vlan') ) { $arguments.Add('vlan', $Vlan) }
            if ( $PSBoundParameters.ContainsKey('Vxlan') ) { $arguments.Add('vxlan', $Vxlan) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$network", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type route6 -NitroPath nitro/v1/config -Resource $network -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteRoute6: Finished"
    }
}

function Invoke-ADCUpdateRoute6 {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Network
        IPv6 network address for which to add a route entry to the routing table of the Citrix ADC.
    .PARAMETER Gateway
        The gateway for this route. The value for this parameter is either an IPv6 address or null.
    .PARAMETER Vlan
        Integer value that uniquely identifies a VLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Vxlan
        Integer value that uniquely identifies a VXLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Distance
        Administrative distance of this route from the appliance.
    .PARAMETER Cost
        Positive integer used by the routing algorithms to determine preference for this route. The lower the cost, the higher the preference.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Msr
        Monitor this route with a monitor of type ND6 or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ND6 or PING, configured on the Citrix ADC to monitor this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRoute6 -network <string>
        An example how to update route6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Network,

        [string]$Gateway,

        [ValidateRange(0, 4094)]
        [double]$Vlan,

        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [ValidateRange(1, 65535)]
        [double]$Weight,

        [ValidateRange(1, 254)]
        [double]$Distance,

        [ValidateRange(0, 65535)]
        [double]$Cost,

        [ValidateSet('DISABLED', 'ENABLED')]
        [string]$Advertise,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Msr,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Monitor,

        [ValidateRange(0, 4094)]
        [double]$Td 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRoute6: Starting"
    }
    process {
        try {
            $payload = @{ network = $network }
            if ( $PSBoundParameters.ContainsKey('gateway') ) { $payload.Add('gateway', $gateway) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost') ) { $payload.Add('cost', $cost) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSCmdlet.ShouldProcess("route6", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type route6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRoute6: Finished"
    }
}

function Invoke-ADCUnsetRoute6 {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Network
        IPv6 network address for which to add a route entry to the routing table of the Citrix ADC.
    .PARAMETER Gateway
        The gateway for this route. The value for this parameter is either an IPv6 address or null.
    .PARAMETER Vlan
        Integer value that uniquely identifies a VLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Vxlan
        Integer value that uniquely identifies a VXLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Weight
        Positive integer used by the routing algorithms to determine preference for this route over others of equal cost. The lower the weight, the higher the preference.
    .PARAMETER Distance
        Administrative distance of this route from the appliance.
    .PARAMETER Cost
        Positive integer used by the routing algorithms to determine preference for this route. The lower the cost, the higher the preference.
    .PARAMETER Advertise
        Advertise this route.
        Possible values = DISABLED, ENABLED
    .PARAMETER Msr
        Monitor this route with a monitor of type ND6 or PING.
        Possible values = ENABLED, DISABLED
    .PARAMETER Monitor
        Name of the monitor, of type ND6 or PING, configured on the Citrix ADC to monitor this route.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetRoute6 -network <string>
        An example how to unset route6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [string]$Network,

        [Boolean]$gateway,

        [Boolean]$vlan,

        [Boolean]$vxlan,

        [Boolean]$td,

        [Boolean]$weight,

        [Boolean]$distance,

        [Boolean]$cost,

        [Boolean]$advertise,

        [Boolean]$msr,

        [Boolean]$monitor 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetRoute6: Starting"
    }
    process {
        try {
            $payload = @{ network = $network }
            if ( $PSBoundParameters.ContainsKey('gateway') ) { $payload.Add('gateway', $gateway) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('weight') ) { $payload.Add('weight', $weight) }
            if ( $PSBoundParameters.ContainsKey('distance') ) { $payload.Add('distance', $distance) }
            if ( $PSBoundParameters.ContainsKey('cost') ) { $payload.Add('cost', $cost) }
            if ( $PSBoundParameters.ContainsKey('advertise') ) { $payload.Add('advertise', $advertise) }
            if ( $PSBoundParameters.ContainsKey('msr') ) { $payload.Add('msr', $msr) }
            if ( $PSBoundParameters.ContainsKey('monitor') ) { $payload.Add('monitor', $monitor) }
            if ( $PSCmdlet.ShouldProcess("$network", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type route6 -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetRoute6: Finished"
    }
}

function Invoke-ADCGetRoute6 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for route 6 resource.
    .PARAMETER Network
        IPv6 network address for which to add a route entry to the routing table of the Citrix ADC.
    .PARAMETER Gateway
        The gateway for this route. The value for this parameter is either an IPv6 address or null.
    .PARAMETER Vlan
        Integer value that uniquely identifies a VLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Vxlan
        Integer value that uniquely identifies a VXLAN through which the Citrix ADC forwards the packets for this route.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Routetype
        Type of IPv6 routes to remove from the routing table of the Citrix ADC.
        Possible values = CONNECTED, STATIC, DYNAMIC, OSPF, ISIS, BGP, RIP, ND-RA-ROUTE, FIB6
    .PARAMETER Detail
        To get a detailed view.
    .PARAMETER GetAll
        Retrieve all route6 object(s).
    .PARAMETER Count
        If specified, the count of the route6 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute6
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute6 -GetAll
        Get all route6 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute6 -Count
        Get the number of route6 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute6 -name <string>
        Get route6 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRoute6 -Filter @{ 'name'='<value>' }
        Get route6 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRoute6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/route6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByArgument')]
        [string]$Network,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [string]$Gateway,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 4094)]
        [double]$Vlan,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateRange(0, 4094)]
        [double]$Td,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [ValidateSet('CONNECTED', 'STATIC', 'DYNAMIC', 'OSPF', 'ISIS', 'BGP', 'RIP', 'ND-RA-ROUTE', 'FIB6')]
        [string]$Routetype,

        [Parameter(ParameterSetName = 'GetByArgument')]
        [boolean]$Detail,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetRoute6: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all route6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for route6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving route6 objects by arguments"
                $arguments = @{ } 
                if ( $PSBoundParameters.ContainsKey('network') ) { $arguments.Add('network', $network) } 
                if ( $PSBoundParameters.ContainsKey('gateway') ) { $arguments.Add('gateway', $gateway) } 
                if ( $PSBoundParameters.ContainsKey('vlan') ) { $arguments.Add('vlan', $vlan) } 
                if ( $PSBoundParameters.ContainsKey('vxlan') ) { $arguments.Add('vxlan', $vxlan) } 
                if ( $PSBoundParameters.ContainsKey('td') ) { $arguments.Add('td', $td) } 
                if ( $PSBoundParameters.ContainsKey('routetype') ) { $arguments.Add('routetype', $routetype) } 
                if ( $PSBoundParameters.ContainsKey('detail') ) { $arguments.Add('detail', $detail) }
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route6 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving route6 configuration for property ''"

            } else {
                Write-Verbose "Retrieving route6 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type route6 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRoute6: Ended"
    }
}

function Invoke-ADCUpdateRsskeytype {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for RSS key type resource.
    .PARAMETER Rsstype
        Type of RSS key, possible values are SYMMETRIC and ASYMMETRIC.
        Possible values = ASYMMETRIC, SYMMETRIC
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateRsskeytype -rsstype <string>
        An example how to update rsskeytype configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateRsskeytype
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rsskeytype/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateSet('ASYMMETRIC', 'SYMMETRIC')]
        [string]$Rsstype 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateRsskeytype: Starting"
    }
    process {
        try {
            $payload = @{ rsstype = $rsstype }

            if ( $PSCmdlet.ShouldProcess("rsskeytype", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type rsskeytype -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateRsskeytype: Finished"
    }
}

function Invoke-ADCGetRsskeytype {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for RSS key type resource.
    .PARAMETER GetAll
        Retrieve all rsskeytype object(s).
    .PARAMETER Count
        If specified, the count of the rsskeytype object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRsskeytype
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRsskeytype -GetAll
        Get all rsskeytype data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRsskeytype -name <string>
        Get rsskeytype object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetRsskeytype -Filter @{ 'name'='<value>' }
        Get rsskeytype data with a filter.
    .NOTES
        File Name : Invoke-ADCGetRsskeytype
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/rsskeytype/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetRsskeytype: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all rsskeytype objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rsskeytype -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for rsskeytype objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rsskeytype -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving rsskeytype objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rsskeytype -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving rsskeytype configuration for property ''"

            } else {
                Write-Verbose "Retrieving rsskeytype configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type rsskeytype -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetRsskeytype: Ended"
    }
}

function Invoke-ADCAddVlan {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for "VLAN" resource.
    .PARAMETER Id
        A positive integer that uniquely identifies a VLAN.
    .PARAMETER Aliasname
        A name for the VLAN. Must begin with a letter, a number, or the underscore symbol, and can consist of from 1 to 31 letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore (_) characters. You should choose a name that helps identify the VLAN. However, you cannot perform any VLAN operation by specifying this name instead of the VLAN ID.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mtu
        Specifies the maximum transmission unit (MTU), in bytes. The MTU is the largest packet size, excluding 14 bytes of ethernet header and 4 bytes of crc, that can be transmitted and received over this VLAN.
    .PARAMETER Sharing
        If sharing is enabled, then this vlan can be shared across multiple partitions by binding it to all those partitions. If sharing is disabled, then this vlan can be bound to only one of the partitions.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created vlan item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlan -id <double>
        An example how to add vlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [string]$Aliasname,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting = 'DISABLED',

        [ValidateRange(500, 9216)]
        [double]$Mtu = '0',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('aliasname') ) { $payload.Add('aliasname', $aliasname) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSCmdlet.ShouldProcess("vlan", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type vlan -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlan -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlan: Finished"
    }
}

function Invoke-ADCDeleteVlan {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for "VLAN" resource.
    .PARAMETER Id
        A positive integer that uniquely identifies a VLAN.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlan -Id <double>
        An example how to delete vlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlan: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlan: Finished"
    }
}

function Invoke-ADCUpdateVlan {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for "VLAN" resource.
    .PARAMETER Id
        A positive integer that uniquely identifies a VLAN.
    .PARAMETER Aliasname
        A name for the VLAN. Must begin with a letter, a number, or the underscore symbol, and can consist of from 1 to 31 letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore (_) characters. You should choose a name that helps identify the VLAN. However, you cannot perform any VLAN operation by specifying this name instead of the VLAN ID.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mtu
        Specifies the maximum transmission unit (MTU), in bytes. The MTU is the largest packet size, excluding 14 bytes of ethernet header and 4 bytes of crc, that can be transmitted and received over this VLAN.
    .PARAMETER Sharing
        If sharing is enabled, then this vlan can be shared across multiple partitions by binding it to all those partitions. If sharing is disabled, then this vlan can be bound to only one of the partitions.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created vlan item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateVlan -id <double>
        An example how to update vlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateVlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [string]$Aliasname,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting,

        [ValidateRange(500, 9216)]
        [double]$Mtu,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateVlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('aliasname') ) { $payload.Add('aliasname', $aliasname) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSCmdlet.ShouldProcess("vlan", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlan -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateVlan: Finished"
    }
}

function Invoke-ADCUnsetVlan {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for "VLAN" resource.
    .PARAMETER Id
        A positive integer that uniquely identifies a VLAN.
    .PARAMETER Aliasname
        A name for the VLAN. Must begin with a letter, a number, or the underscore symbol, and can consist of from 1 to 31 letters, numbers, and the hyphen (-), period (.) pound (#), space ( ), at sign (@), equals (=), colon (:), and underscore (_) characters. You should choose a name that helps identify the VLAN. However, you cannot perform any VLAN operation by specifying this name instead of the VLAN ID.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Mtu
        Specifies the maximum transmission unit (MTU), in bytes. The MTU is the largest packet size, excluding 14 bytes of ethernet header and 4 bytes of crc, that can be transmitted and received over this VLAN.
    .PARAMETER Sharing
        If sharing is enabled, then this vlan can be shared across multiple partitions by binding it to all those partitions. If sharing is disabled, then this vlan can be bound to only one of the partitions.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetVlan -id <double>
        An example how to unset vlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetVlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 4094)]
        [double]$Id,

        [Boolean]$aliasname,

        [Boolean]$dynamicrouting,

        [Boolean]$ipv6dynamicrouting,

        [Boolean]$mtu,

        [Boolean]$sharing 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetVlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('aliasname') ) { $payload.Add('aliasname', $aliasname) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('mtu') ) { $payload.Add('mtu', $mtu) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type vlan -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetVlan: Finished"
    }
}

function Invoke-ADCGetVlan {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for "VLAN" resource.
    .PARAMETER Id
        A positive integer that uniquely identifies a VLAN.
    .PARAMETER GetAll
        Retrieve all vlan object(s).
    .PARAMETER Count
        If specified, the count of the vlan object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlan
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlan -GetAll
        Get all vlan data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlan -Count
        Get the number of vlan objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlan -name <string>
        Get vlan object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlan -Filter @{ 'name'='<value>' }
        Get vlan data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetVlan: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vlan objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlan: Ended"
    }
}

function Invoke-ADCGetVlanbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to vlan.
    .PARAMETER Id
        Integer that uniquely identifies the VLAN for which the details are to be displayed.
    .PARAMETER GetAll
        Retrieve all vlan_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanbinding -GetAll
        Get all vlan_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanbinding -name <string>
        Get vlan_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanbinding -Filter @{ 'name'='<value>' }
        Get vlan_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlanbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlanbinding: Ended"
    }
}

function Invoke-ADCAddVlanchannelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created vlan_channel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlanchannelbinding -id <double>
        An example how to add vlan_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlanchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ifnum,

        [boolean]$Tagged,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlanchannelbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('tagged') ) { $payload.Add('tagged', $tagged) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("vlan_channel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan_channel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlanchannelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlanchannelbinding: Finished"
    }
}

function Invoke-ADCDeleteVlanchannelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlanchannelbinding -Id <double>
        An example how to delete vlan_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlanchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum,

        [boolean]$Tagged,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlanchannelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSBoundParameters.ContainsKey('Tagged') ) { $arguments.Add('tagged', $Tagged) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan_channel_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlanchannelbinding: Finished"
    }
}

function Invoke-ADCGetVlanchannelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the channel that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER GetAll
        Retrieve all vlan_channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanchannelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanchannelbinding -GetAll
        Get all vlan_channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanchannelbinding -Count
        Get the number of vlan_channel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanchannelbinding -name <string>
        Get vlan_channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanchannelbinding -Filter @{ 'name'='<value>' }
        Get vlan_channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlanchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlanchannelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_channel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_channel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlanchannelbinding: Ended"
    }
}

function Invoke-ADCAddVlaninterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created vlan_interface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlaninterfacebinding -id <double>
        An example how to add vlan_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlaninterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ifnum,

        [boolean]$Tagged,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlaninterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('tagged') ) { $payload.Add('tagged', $tagged) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("vlan_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlaninterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlaninterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteVlaninterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlaninterfacebinding -Id <double>
        An example how to delete vlan_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlaninterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum,

        [boolean]$Tagged,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlaninterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSBoundParameters.ContainsKey('Tagged') ) { $arguments.Add('tagged', $Tagged) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan_interface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlaninterfacebinding: Finished"
    }
}

function Invoke-ADCGetVlaninterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the interface that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER GetAll
        Retrieve all vlan_interface_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_interface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlaninterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlaninterfacebinding -GetAll
        Get all vlan_interface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlaninterfacebinding -Count
        Get the number of vlan_interface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlaninterfacebinding -name <string>
        Get vlan_interface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlaninterfacebinding -Filter @{ 'name'='<value>' }
        Get vlan_interface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlaninterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlaninterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_interface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_interface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_interface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_interface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_interface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_interface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlaninterfacebinding: Ended"
    }
}

function Invoke-ADCAddVlanlinksetbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the linkset that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created vlan_linkset_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlanlinksetbinding -id <double>
        An example how to add vlan_linkset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlanlinksetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_linkset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ifnum,

        [boolean]$Tagged,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlanlinksetbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSBoundParameters.ContainsKey('tagged') ) { $payload.Add('tagged', $tagged) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("vlan_linkset_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan_linkset_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlanlinksetbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlanlinksetbinding: Finished"
    }
}

function Invoke-ADCDeleteVlanlinksetbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the linkset that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ifnum
        The interface to be bound to the VLAN, specified in slot/port notation (for example, 1/3).
    .PARAMETER Tagged
        Make the interface an 802.1q tagged interface. Packets sent on this interface on this VLAN have an additional 4-byte 802.1q tag, which identifies the VLAN. To use 802.1q tagging, you must also configure the switch connected to the appliance's interfaces.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlanlinksetbinding -Id <double>
        An example how to delete vlan_linkset_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlanlinksetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_linkset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum,

        [boolean]$Tagged,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlanlinksetbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSBoundParameters.ContainsKey('Tagged') ) { $arguments.Add('tagged', $Tagged) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan_linkset_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlanlinksetbinding: Finished"
    }
}

function Invoke-ADCGetVlanlinksetbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the linkset that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER GetAll
        Retrieve all vlan_linkset_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_linkset_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanlinksetbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanlinksetbinding -GetAll
        Get all vlan_linkset_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanlinksetbinding -Count
        Get the number of vlan_linkset_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanlinksetbinding -name <string>
        Get vlan_linkset_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlanlinksetbinding -Filter @{ 'name'='<value>' }
        Get vlan_linkset_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlanlinksetbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_linkset_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlanlinksetbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_linkset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_linkset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_linkset_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_linkset_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_linkset_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_linkset_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_linkset_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_linkset_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_linkset_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_linkset_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlanlinksetbinding: Ended"
    }
}

function Invoke-ADCAddVlannsip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ipaddress
        The IP address assigned to the VLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VLAN.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created vlan_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlannsip6binding -id <double>
        An example how to add vlan_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [string]$Ipaddress,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlannsip6binding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("vlan_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlannsip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlannsip6binding: Finished"
    }
}

function Invoke-ADCDeleteVlannsip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ipaddress
        The IP address assigned to the VLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VLAN.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlannsip6binding -Id <double>
        An example how to delete vlan_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlannsip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlannsip6binding: Finished"
    }
}

function Invoke-ADCGetVlannsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER GetAll
        Retrieve all vlan_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsip6binding -GetAll
        Get all vlan_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsip6binding -Count
        Get the number of vlan_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsip6binding -name <string>
        Get vlan_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsip6binding -Filter @{ 'name'='<value>' }
        Get vlan_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlannsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_nsip6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlannsip6binding: Ended"
    }
}

function Invoke-ADCAddVlannsipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ipaddress
        The IP address assigned to the VLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VLAN.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .PARAMETER PassThru
        Return details about the created vlan_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVlannsipbinding -id <double>
        An example how to add vlan_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [ValidateRange(0, 4094)]
        [double]$Td,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Ownergroup = 'DEFAULT_NG',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVlannsipbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSBoundParameters.ContainsKey('td') ) { $payload.Add('td', $td) }
            if ( $PSBoundParameters.ContainsKey('ownergroup') ) { $payload.Add('ownergroup', $ownergroup) }
            if ( $PSCmdlet.ShouldProcess("vlan_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vlan_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVlannsipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVlannsipbinding: Finished"
    }
}

function Invoke-ADCDeleteVlannsipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER Ipaddress
        The IP address assigned to the VLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VLAN.
    .PARAMETER Td
        Integer value that uniquely identifies the traffic domain in which you want to configure the entity. If you do not specify an ID, the entity becomes part of the default traffic domain, which has an ID of 0.
    .PARAMETER Ownergroup
        The owner node group in a Cluster for this vlan.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVlannsipbinding -Id <double>
        An example how to delete vlan_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [double]$Td,

        [string]$Ownergroup 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVlannsipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSBoundParameters.ContainsKey('Td') ) { $arguments.Add('td', $Td) }
            if ( $PSBoundParameters.ContainsKey('Ownergroup') ) { $arguments.Add('ownergroup', $Ownergroup) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vlan_nsip_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVlannsipbinding: Finished"
    }
}

function Invoke-ADCGetVlannsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vlan.
    .PARAMETER Id
        Specifies the virtual LAN ID.
    .PARAMETER GetAll
        Retrieve all vlan_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the vlan_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsipbinding -GetAll
        Get all vlan_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsipbinding -Count
        Get the number of vlan_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsipbinding -name <string>
        Get vlan_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVlannsipbinding -Filter @{ 'name'='<value>' }
        Get vlan_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 4094)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVlannsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vlan_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vlan_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vlan_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vlan_nsip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vlan_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vlan_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVlannsipbinding: Ended"
    }
}

function Invoke-ADCAddVrid {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID resource.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, owner node is displayed as ALL and one node is dynamically elected as the owner.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Preemptiondelaytimer
        Preemption delay time, in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .PARAMETER PassThru
        Return details about the created vrid item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVrid -id <double>
        An example how to add vrid configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVrid
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [ValidateRange(0, 255)]
        [double]$Priority = '255',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Preemption = 'ENABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing = 'DISABLED',

        [ValidateSet('NONE', 'ONE', 'ALL', 'PROGRESSIVE')]
        [string]$Tracking = 'NONE',

        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [ValidateRange(1, 255)]
        [double]$Trackifnumpriority = '0',

        [ValidateRange(1, 36000)]
        [double]$Preemptiondelaytimer = '0',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVrid: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSCmdlet.ShouldProcess("vrid", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type vrid -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVrid: Finished"
    }
}

function Invoke-ADCDeleteVrid {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID resource.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER All
        Remove all the configured VMAC addresses from the Citrix ADC.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVrid -Id <double>
        An example how to delete vrid configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVrid
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [boolean]$All 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVrid: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('All') ) { $arguments.Add('all', $All) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVrid: Finished"
    }
}

function Invoke-ADCUpdateVrid {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID resource.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, owner node is displayed as ALL and one node is dynamically elected as the owner.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Preemptiondelaytimer
        Preemption delay time, in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .PARAMETER PassThru
        Return details about the created vrid item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateVrid -id <double>
        An example how to update vrid configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateVrid
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [ValidateRange(0, 255)]
        [double]$Priority,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Preemption,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing,

        [ValidateSet('NONE', 'ONE', 'ALL', 'PROGRESSIVE')]
        [string]$Tracking,

        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [ValidateRange(1, 255)]
        [double]$Trackifnumpriority,

        [ValidateRange(1, 36000)]
        [double]$Preemptiondelaytimer,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateVrid: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSCmdlet.ShouldProcess("vrid", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateVrid: Finished"
    }
}

function Invoke-ADCUnsetVrid {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID resource.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, owner node is displayed as ALL and one node is dynamically elected as the owner.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Preemptiondelaytimer
        Preemption delay time, in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetVrid -id <double>
        An example how to unset vrid configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetVrid
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 255)]
        [double]$Id,

        [Boolean]$priority,

        [Boolean]$preemption,

        [Boolean]$sharing,

        [Boolean]$tracking,

        [Boolean]$ownernode,

        [Boolean]$trackifnumpriority,

        [Boolean]$preemptiondelaytimer 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetVrid: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type vrid -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetVrid: Finished"
    }
}

function Invoke-ADCGetVrid {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Virtual Router ID resource.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid object(s).
    .PARAMETER Count
        If specified, the count of the vrid object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid -GetAll
        Get all vrid data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid -Count
        Get the number of vrid objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid -name <string>
        Get vrid object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid -Filter @{ 'name'='<value>' }
        Get vrid data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vrid objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid: Ended"
    }
}

function Invoke-ADCAddVrid6 {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID for IPv6 resource.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Preemptiondelaytimer
        Preemption delay time in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, ow ner node is displayed as ALL and one node is dynamically elected as the owner.
    .PARAMETER PassThru
        Return details about the created vrid6 item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVrid6 -id <double>
        An example how to add vrid6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVrid6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [ValidateRange(0, 255)]
        [double]$Priority = '255',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Preemption = 'ENABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing = 'DISABLED',

        [ValidateSet('NONE', 'ONE', 'ALL', 'PROGRESSIVE')]
        [string]$Tracking = 'NONE',

        [ValidateRange(1, 36000)]
        [double]$Preemptiondelaytimer = '0',

        [ValidateRange(1, 255)]
        [double]$Trackifnumpriority = '0',

        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVrid6: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("vrid6", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type vrid6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid6 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVrid6: Finished"
    }
}

function Invoke-ADCDeleteVrid6 {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID for IPv6 resource.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER All
        Remove all configured VMAC6 addresses from the Citrix ADC.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVrid6 -Id <double>
        An example how to delete vrid6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVrid6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [boolean]$All 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVrid6: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('All') ) { $arguments.Add('all', $All) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid6 -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVrid6: Finished"
    }
}

function Invoke-ADCUpdateVrid6 {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID for IPv6 resource.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Preemptiondelaytimer
        Preemption delay time in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, ow ner node is displayed as ALL and one node is dynamically elected as the owner.
    .PARAMETER PassThru
        Return details about the created vrid6 item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateVrid6 -id <double>
        An example how to update vrid6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateVrid6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [ValidateRange(0, 255)]
        [double]$Priority,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Preemption,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sharing,

        [ValidateSet('NONE', 'ONE', 'ALL', 'PROGRESSIVE')]
        [string]$Tracking,

        [ValidateRange(1, 36000)]
        [double]$Preemptiondelaytimer,

        [ValidateRange(1, 255)]
        [double]$Trackifnumpriority,

        [ValidateRange(0, 31)]
        [double]$Ownernode,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateVrid6: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("vrid6", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid6 -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid6 -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateVrid6: Finished"
    }
}

function Invoke-ADCUnsetVrid6 {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for Virtual Router ID for IPv6 resource.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Priority
        Base priority (BP), in an active-active mode configuration, which ordinarily determines the master VIP address.
    .PARAMETER Preemption
        In an active-active mode configuration, make a backup VIP address the master if its priority becomes higher than that of a master VIP address bound to this VMAC address.
        If you disable pre-emption while a backup VIP address is the master, the backup VIP address remains master until the original master VIP's priority becomes higher than that of the current master.
        Possible values = ENABLED, DISABLED
    .PARAMETER Sharing
        In an active-active mode configuration, enable the backup VIP address to process any traffic instead of dropping it.
        Possible values = ENABLED, DISABLED
    .PARAMETER Tracking
        The effective priority (EP) value, relative to the base priority (BP) value in an active-active mode configuration. When EP is set to a value other than None, it is EP, not BP, which determines the master VIP address.
        Available settings function as follows:
        * NONE - No tracking. EP = BP
        * ALL - If the status of all virtual servers is UP, EP = BP. Otherwise, EP = 0.
        * ONE - If the status of at least one virtual server is UP, EP = BP. Otherwise, EP = 0.
        * PROGRESSIVE - If the status of all virtual servers is UP, EP = BP. If the status of all virtual servers is DOWN, EP = 0. Otherwise EP = BP (1 - K/N), where N is the total number of virtual servers associated with the VIP address and K is the number of virtual servers for which the status is DOWN.
        Default: NONE.
        Possible values = NONE, ONE, ALL, PROGRESSIVE
    .PARAMETER Preemptiondelaytimer
        Preemption delay time in seconds, in an active-active configuration. If any high priority node will come in network, it will wait for these many seconds before becoming master.
    .PARAMETER Trackifnumpriority
        Priority by which the Effective priority will be reduced if any of the tracked interfaces goes down in an active-active configuration.
    .PARAMETER Ownernode
        In a cluster setup, assign a cluster node as the owner of this VMAC address for IP based VRRP configuration. If no owner is configured, ow ner node is displayed as ALL and one node is dynamically elected as the owner.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetVrid6 -id <double>
        An example how to unset vrid6 configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetVrid6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 255)]
        [double]$Id,

        [Boolean]$priority,

        [Boolean]$preemption,

        [Boolean]$sharing,

        [Boolean]$tracking,

        [Boolean]$preemptiondelaytimer,

        [Boolean]$trackifnumpriority,

        [Boolean]$ownernode 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetVrid6: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('priority') ) { $payload.Add('priority', $priority) }
            if ( $PSBoundParameters.ContainsKey('preemption') ) { $payload.Add('preemption', $preemption) }
            if ( $PSBoundParameters.ContainsKey('sharing') ) { $payload.Add('sharing', $sharing) }
            if ( $PSBoundParameters.ContainsKey('tracking') ) { $payload.Add('tracking', $tracking) }
            if ( $PSBoundParameters.ContainsKey('preemptiondelaytimer') ) { $payload.Add('preemptiondelaytimer', $preemptiondelaytimer) }
            if ( $PSBoundParameters.ContainsKey('trackifnumpriority') ) { $payload.Add('trackifnumpriority', $trackifnumpriority) }
            if ( $PSBoundParameters.ContainsKey('ownernode') ) { $payload.Add('ownernode', $ownernode) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type vrid6 -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetVrid6: Finished"
    }
}

function Invoke-ADCGetVrid6 {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for Virtual Router ID for IPv6 resource.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6 object(s).
    .PARAMETER Count
        If specified, the count of the vrid6 object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6 -GetAll
        Get all vrid6 data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6 -Count
        Get the number of vrid6 objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6 -name <string>
        Get vrid6 object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6 -Filter @{ 'name'='<value>' }
        Get vrid6 data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vrid6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6 objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6 -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6 objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6 -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6 configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6 -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6 configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6 -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6: Ended"
    }
}

function Invoke-ADCGetVrid6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6binding -GetAll
        Get all vrid6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6binding -name <string>
        Get vrid6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6binding -Filter @{ 'name'='<value>' }
        Get vrid6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6binding: Ended"
    }
}

function Invoke-ADCAddVrid6channelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC6, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .PARAMETER PassThru
        Return details about the created vrid6_channel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVrid6channelbinding -id <double>
        An example how to add vrid6_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVrid6channelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVrid6channelbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid6_channel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid6_channel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid6channelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVrid6channelbinding: Finished"
    }
}

function Invoke-ADCDeleteVrid6channelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC6, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVrid6channelbinding -Id <double>
        An example how to delete vrid6_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVrid6channelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVrid6channelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid6_channel_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVrid6channelbinding: Finished"
    }
}

function Invoke-ADCGetVrid6channelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6channelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6channelbinding -GetAll
        Get all vrid6_channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6channelbinding -Count
        Get the number of vrid6_channel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6channelbinding -name <string>
        Get vrid6_channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6channelbinding -Filter @{ 'name'='<value>' }
        Get vrid6_channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6channelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6channelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_channel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_channel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6channelbinding: Ended"
    }
}

function Invoke-ADCAddVrid6interfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC6, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .PARAMETER PassThru
        Return details about the created vrid6_interface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVrid6interfacebinding -id <double>
        An example how to add vrid6_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVrid6interfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVrid6interfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid6_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid6_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid6interfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVrid6interfacebinding: Finished"
    }
}

function Invoke-ADCDeleteVrid6interfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC6, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVrid6interfacebinding -Id <double>
        An example how to delete vrid6_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVrid6interfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVrid6interfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid6_interface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVrid6interfacebinding: Finished"
    }
}

function Invoke-ADCGetVrid6interfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_interface_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_interface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6interfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6interfacebinding -GetAll
        Get all vrid6_interface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6interfacebinding -Count
        Get the number of vrid6_interface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6interfacebinding -name <string>
        Get vrid6_interface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6interfacebinding -Filter @{ 'name'='<value>' }
        Get vrid6_interface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6interfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6interfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_interface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_interface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_interface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_interface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_interface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_interface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6interfacebinding: Ended"
    }
}

function Invoke-ADCGetVrid6nsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsip6binding -GetAll
        Get all vrid6_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsip6binding -Count
        Get the number of vrid6_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsip6binding -name <string>
        Get vrid6_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsip6binding -Filter @{ 'name'='<value>' }
        Get vrid6_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6nsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6nsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_nsip6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6nsip6binding: Ended"
    }
}

function Invoke-ADCGetVrid6nsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsipbinding -GetAll
        Get all vrid6_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsipbinding -Count
        Get the number of vrid6_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsipbinding -name <string>
        Get vrid6_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6nsipbinding -Filter @{ 'name'='<value>' }
        Get vrid6_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6nsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6nsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_nsip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6nsipbinding: Ended"
    }
}

function Invoke-ADCAddVrid6trackinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Trackifnum
        Interfaces which need to be tracked for this vrID.
    .PARAMETER PassThru
        Return details about the created vrid6_trackinterface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVrid6trackinterfacebinding -id <double>
        An example how to add vrid6_trackinterface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVrid6trackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Trackifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVrid6trackinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('trackifnum') ) { $payload.Add('trackifnum', $trackifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid6_trackinterface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid6_trackinterface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVrid6trackinterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVrid6trackinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteVrid6trackinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER Trackifnum
        Interfaces which need to be tracked for this vrID.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVrid6trackinterfacebinding -Id <double>
        An example how to delete vrid6_trackinterface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVrid6trackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Trackifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVrid6trackinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Trackifnum') ) { $arguments.Add('trackifnum', $Trackifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVrid6trackinterfacebinding: Finished"
    }
}

function Invoke-ADCGetVrid6trackinterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid6.
    .PARAMETER Id
        Integer value that uniquely identifies a VMAC6 address.
    .PARAMETER GetAll
        Retrieve all vrid6_trackinterface_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid6_trackinterface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6trackinterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6trackinterfacebinding -GetAll
        Get all vrid6_trackinterface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6trackinterfacebinding -Count
        Get the number of vrid6_trackinterface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6trackinterfacebinding -name <string>
        Get vrid6_trackinterface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVrid6trackinterfacebinding -Filter @{ 'name'='<value>' }
        Get vrid6_trackinterface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVrid6trackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid6_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVrid6trackinterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid6_trackinterface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid6_trackinterface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid6_trackinterface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid6_trackinterface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid6_trackinterface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid6_trackinterface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVrid6trackinterfacebinding: Ended"
    }
}

function Invoke-ADCUpdateVridparam {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for VR ID parameter resource.
    .PARAMETER Sendtomaster
        Forward packets to the master node, in an active-active mode configuration, if the virtual server is in the backup state and sharing is disabled.
        Possible values = ENABLED, DISABLED
    .PARAMETER Hellointerval
        Interval, in milliseconds, between vrrp advertisement messages sent to the peer node in active-active mode.
    .PARAMETER Deadinterval
        Number of seconds after which a peer node in active-active mode is marked down if vrrp advertisements are not received from the peer node.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateVridparam
        An example how to update vridparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateVridparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vridparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Sendtomaster,

        [ValidateRange(200, 1000)]
        [double]$Hellointerval,

        [ValidateRange(1, 60)]
        [double]$Deadinterval 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateVridparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('sendtomaster') ) { $payload.Add('sendtomaster', $sendtomaster) }
            if ( $PSBoundParameters.ContainsKey('hellointerval') ) { $payload.Add('hellointerval', $hellointerval) }
            if ( $PSBoundParameters.ContainsKey('deadinterval') ) { $payload.Add('deadinterval', $deadinterval) }
            if ( $PSCmdlet.ShouldProcess("vridparam", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vridparam -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $result
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateVridparam: Finished"
    }
}

function Invoke-ADCUnsetVridparam {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for VR ID parameter resource.
    .PARAMETER Sendtomaster
        Forward packets to the master node, in an active-active mode configuration, if the virtual server is in the backup state and sharing is disabled.
        Possible values = ENABLED, DISABLED
    .PARAMETER Hellointerval
        Interval, in milliseconds, between vrrp advertisement messages sent to the peer node in active-active mode.
    .PARAMETER Deadinterval
        Number of seconds after which a peer node in active-active mode is marked down if vrrp advertisements are not received from the peer node.
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetVridparam
        An example how to unset vridparam configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetVridparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vridparam
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Boolean]$sendtomaster,

        [Boolean]$hellointerval,

        [Boolean]$deadinterval 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetVridparam: Starting"
    }
    process {
        try {
            $payload = @{ }
            if ( $PSBoundParameters.ContainsKey('sendtomaster') ) { $payload.Add('sendtomaster', $sendtomaster) }
            if ( $PSBoundParameters.ContainsKey('hellointerval') ) { $payload.Add('hellointerval', $hellointerval) }
            if ( $PSBoundParameters.ContainsKey('deadinterval') ) { $payload.Add('deadinterval', $deadinterval) }
            if ( $PSCmdlet.ShouldProcess("vridparam", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type vridparam -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetVridparam: Finished"
    }
}

function Invoke-ADCGetVridparam {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for VR ID parameter resource.
    .PARAMETER GetAll
        Retrieve all vridparam object(s).
    .PARAMETER Count
        If specified, the count of the vridparam object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridparam
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridparam -GetAll
        Get all vridparam data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridparam -name <string>
        Get vridparam object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridparam -Filter @{ 'name'='<value>' }
        Get vridparam data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridparam
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vridparam/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridparam: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vridparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vridparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vridparam objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vridparam -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vridparam objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vridparam -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vridparam configuration for property ''"

            } else {
                Write-Verbose "Retrieving vridparam configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vridparam -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridparam: Ended"
    }
}

function Invoke-ADCGetVridbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to vrid.
    .PARAMETER Id
        Integer value that uniquely identifies the VMAC address.
    .PARAMETER GetAll
        Retrieve all vrid_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridbinding -GetAll
        Get all vrid_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridbinding -name <string>
        Get vrid_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridbinding -Filter @{ 'name'='<value>' }
        Get vrid_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridbinding: Ended"
    }
}

function Invoke-ADCAddVridchannelbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .PARAMETER PassThru
        Return details about the created vrid_channel_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVridchannelbinding -id <double>
        An example how to add vrid_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVridchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVridchannelbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid_channel_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid_channel_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVridchannelbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVridchannelbinding: Finished"
    }
}

function Invoke-ADCDeleteVridchannelbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVridchannelbinding -Id <double>
        An example how to delete vrid_channel_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVridchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVridchannelbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid_channel_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVridchannelbinding: Finished"
    }
}

function Invoke-ADCGetVridchannelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the channel that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid_channel_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_channel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridchannelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridchannelbinding -GetAll
        Get all vrid_channel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridchannelbinding -Count
        Get the number of vrid_channel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridchannelbinding -name <string>
        Get vrid_channel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridchannelbinding -Filter @{ 'name'='<value>' }
        Get vrid_channel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridchannelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_channel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridchannelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_channel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_channel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_channel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_channel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_channel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_channel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_channel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_channel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridchannelbinding: Ended"
    }
}

function Invoke-ADCAddVridinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .PARAMETER PassThru
        Return details about the created vrid_interface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVridinterfacebinding -id <double>
        An example how to add vrid_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVridinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Ifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVridinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ifnum') ) { $payload.Add('ifnum', $ifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid_interface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid_interface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVridinterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVridinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteVridinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Ifnum
        Interfaces to bind to the VMAC, specified in (slot/port) notation (for example, 1/2).Use spaces to separate multiple entries.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVridinterfacebinding -Id <double>
        An example how to delete vrid_interface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVridinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVridinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ifnum') ) { $arguments.Add('ifnum', $Ifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid_interface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVridinterfacebinding: Finished"
    }
}

function Invoke-ADCGetVridinterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the interface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid_interface_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_interface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridinterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridinterfacebinding -GetAll
        Get all vrid_interface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridinterfacebinding -Count
        Get the number of vrid_interface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridinterfacebinding -name <string>
        Get vrid_interface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridinterfacebinding -Filter @{ 'name'='<value>' }
        Get vrid_interface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_interface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridinterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_interface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_interface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_interface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_interface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_interface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_interface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_interface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_interface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridinterfacebinding: Ended"
    }
}

function Invoke-ADCGetVridnsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsip6binding -GetAll
        Get all vrid_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsip6binding -Count
        Get the number of vrid_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsip6binding -name <string>
        Get vrid_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsip6binding -Filter @{ 'name'='<value>' }
        Get vrid_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridnsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridnsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_nsip6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridnsip6binding: Ended"
    }
}

function Invoke-ADCGetVridnsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsipbinding -GetAll
        Get all vrid_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsipbinding -Count
        Get the number of vrid_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsipbinding -name <string>
        Get vrid_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridnsipbinding -Filter @{ 'name'='<value>' }
        Get vrid_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridnsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridnsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_nsip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridnsipbinding: Ended"
    }
}

function Invoke-ADCAddVridtrackinterfacebinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Trackifnum
        Interfaces which need to be tracked for this vrID.
    .PARAMETER PassThru
        Return details about the created vrid_trackinterface_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVridtrackinterfacebinding -id <double>
        An example how to add vrid_trackinterface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVridtrackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 255)]
        [double]$Id,

        [string]$Trackifnum,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVridtrackinterfacebinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('trackifnum') ) { $payload.Add('trackifnum', $trackifnum) }
            if ( $PSCmdlet.ShouldProcess("vrid_trackinterface_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vrid_trackinterface_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVridtrackinterfacebinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVridtrackinterfacebinding: Finished"
    }
}

function Invoke-ADCDeleteVridtrackinterfacebinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER Trackifnum
        Interfaces which need to be tracked for this vrID.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVridtrackinterfacebinding -Id <double>
        An example how to delete vrid_trackinterface_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVridtrackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Trackifnum 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVridtrackinterfacebinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Trackifnum') ) { $arguments.Add('trackifnum', $Trackifnum) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVridtrackinterfacebinding: Finished"
    }
}

function Invoke-ADCGetVridtrackinterfacebinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the trackinterface that can be bound to vrid.
    .PARAMETER Id
        Integer that uniquely identifies the VMAC address. The generic VMAC address is in the form of 00:00:5e:00:01:<VRID>. For example, if you add a VRID with a value of 60 and bind it to an interface, the resulting VMAC address is 00:00:5e:00:01:3c, where 3c is the hexadecimal representation of 60.
    .PARAMETER GetAll
        Retrieve all vrid_trackinterface_binding object(s).
    .PARAMETER Count
        If specified, the count of the vrid_trackinterface_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridtrackinterfacebinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridtrackinterfacebinding -GetAll
        Get all vrid_trackinterface_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridtrackinterfacebinding -Count
        Get the number of vrid_trackinterface_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridtrackinterfacebinding -name <string>
        Get vrid_trackinterface_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVridtrackinterfacebinding -Filter @{ 'name'='<value>' }
        Get vrid_trackinterface_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVridtrackinterfacebinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vrid_trackinterface_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 255)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVridtrackinterfacebinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vrid_trackinterface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vrid_trackinterface_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vrid_trackinterface_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vrid_trackinterface_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vrid_trackinterface_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vrid_trackinterface_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVridtrackinterfacebinding: Ended"
    }
}

function Invoke-ADCAddVxlan {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for "VXLAN" resource.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Vlan
        ID of VLANs whose traffic is allowed over this VXLAN. If you do not specify any VLAN IDs, the Citrix ADC allows traffic of all VLANs that are not part of any other VXLANs.
    .PARAMETER Port
        Specifies UDP destination port for VXLAN packets.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VXLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VXLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Type
        VXLAN encapsulation type. VXLAN, VXLANGPE.
        Possible values = VXLAN, VXLANGPE
    .PARAMETER Protocol
        VXLAN-GPE next protocol. RESERVED, IPv4, IPv6, ETHERNET, NSH.
        Possible values = IPv4, IPv6, ETHERNET, NSH
    .PARAMETER Innervlantagging
        Specifies whether Citrix ADC should generate VXLAN packets with inner VLAN tag.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created vxlan item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlan -id <double>
        An example how to add vxlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [ValidateRange(2, 4094)]
        [double]$Vlan,

        [ValidateRange(1, 65534)]
        [int]$Port = '4789',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting = 'DISABLED',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting = 'DISABLED',

        [ValidateSet('VXLAN', 'VXLANGPE')]
        [string]$Type = 'VXLAN',

        [ValidateSet('IPv4', 'IPv6', 'ETHERNET', 'NSH')]
        [string]$Protocol = 'ETHERNET',

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Innervlantagging = 'DISABLED',

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('port') ) { $payload.Add('port', $port) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('type') ) { $payload.Add('type', $type) }
            if ( $PSBoundParameters.ContainsKey('protocol') ) { $payload.Add('protocol', $protocol) }
            if ( $PSBoundParameters.ContainsKey('innervlantagging') ) { $payload.Add('innervlantagging', $innervlantagging) }
            if ( $PSCmdlet.ShouldProcess("vxlan", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type vxlan -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlan -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlan: Finished"
    }
}

function Invoke-ADCDeleteVxlan {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for "VXLAN" resource.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlan -Id <double>
        An example how to delete vxlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlan: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlan -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlan: Finished"
    }
}

function Invoke-ADCUpdateVxlan {
    <#
    .SYNOPSIS
        Update Network configuration Object.
    .DESCRIPTION
        Configuration for "VXLAN" resource.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Vlan
        ID of VLANs whose traffic is allowed over this VXLAN. If you do not specify any VLAN IDs, the Citrix ADC allows traffic of all VLANs that are not part of any other VXLANs.
    .PARAMETER Port
        Specifies UDP destination port for VXLAN packets.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VXLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VXLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Innervlantagging
        Specifies whether Citrix ADC should generate VXLAN packets with inner VLAN tag.
        Possible values = ENABLED, DISABLED
    .PARAMETER PassThru
        Return details about the created vxlan item.
    .EXAMPLE
        PS C:\>Invoke-ADCUpdateVxlan -id <double>
        An example how to update vxlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUpdateVxlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [ValidateRange(2, 4094)]
        [double]$Vlan,

        [ValidateRange(1, 65534)]
        [int]$Port,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Ipv6dynamicrouting,

        [ValidateSet('ENABLED', 'DISABLED')]
        [string]$Innervlantagging,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCUpdateVxlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('port') ) { $payload.Add('port', $port) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('innervlantagging') ) { $payload.Add('innervlantagging', $innervlantagging) }
            if ( $PSCmdlet.ShouldProcess("vxlan", "Update Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vxlan -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlan -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUpdateVxlan: Finished"
    }
}

function Invoke-ADCUnsetVxlan {
    <#
    .SYNOPSIS
        Unset Network configuration Object.
    .DESCRIPTION
        Configuration for "VXLAN" resource.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Vlan
        ID of VLANs whose traffic is allowed over this VXLAN. If you do not specify any VLAN IDs, the Citrix ADC allows traffic of all VLANs that are not part of any other VXLANs.
    .PARAMETER Port
        Specifies UDP destination port for VXLAN packets.
    .PARAMETER Dynamicrouting
        Enable dynamic routing on this VXLAN.
        Possible values = ENABLED, DISABLED
    .PARAMETER Ipv6dynamicrouting
        Enable all IPv6 dynamic routing protocols on this VXLAN. Note: For the ENABLED setting to work, you must configure IPv6 dynamic routing protocols from the VTYSH command line.
        Possible values = ENABLED, DISABLED
    .PARAMETER Innervlantagging
        Specifies whether Citrix ADC should generate VXLAN packets with inner VLAN tag.
        Possible values = ENABLED, DISABLED
    .EXAMPLE
        PS C:\>Invoke-ADCUnsetVxlan -id <double>
        An example how to unset vxlan configuration Object(s).
    .NOTES
        File Name : Invoke-ADCUnsetVxlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Boolean]$vlan,

        [Boolean]$port,

        [Boolean]$dynamicrouting,

        [Boolean]$ipv6dynamicrouting,

        [Boolean]$innervlantagging 
    )
    begin {
        Write-Verbose "Invoke-ADCUnsetVxlan: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSBoundParameters.ContainsKey('port') ) { $payload.Add('port', $port) }
            if ( $PSBoundParameters.ContainsKey('dynamicrouting') ) { $payload.Add('dynamicrouting', $dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('ipv6dynamicrouting') ) { $payload.Add('ipv6dynamicrouting', $ipv6dynamicrouting) }
            if ( $PSBoundParameters.ContainsKey('innervlantagging') ) { $payload.Add('innervlantagging', $innervlantagging) }
            if ( $PSCmdlet.ShouldProcess("$id", "Unset Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -Type vxlan -NitroPath nitro/v1/config -Action unset -Payload $payload -GetWarning
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCUnsetVxlan: Finished"
    }
}

function Invoke-ADCGetVxlan {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for "VXLAN" resource.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan object(s).
    .PARAMETER Count
        If specified, the count of the vxlan object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlan
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlan -GetAll
        Get all vxlan data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlan -Count
        Get the number of vxlan objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlan -name <string>
        Get vxlan object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlan -Filter @{ 'name'='<value>' }
        Get vxlan data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlan
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlan: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vxlan objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlan: Ended"
    }
}

function Invoke-ADCAddVxlanvlanmap {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Configuration for vxlan vlan mapping resource.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER PassThru
        Return details about the created vxlanvlanmap item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlanvlanmap -name <string>
        An example how to add vxlanvlanmap configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlanvlanmap
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlanvlanmap: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }

            if ( $PSCmdlet.ShouldProcess("vxlanvlanmap", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method POST -NitroPath nitro/v1/config -Type vxlanvlanmap -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlanvlanmap -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlanvlanmap: Finished"
    }
}

function Invoke-ADCDeleteVxlanvlanmap {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Configuration for vxlan vlan mapping resource.
    .PARAMETER Name
        Name of the mapping table.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlanvlanmap -Name <string>
        An example how to delete vxlanvlanmap configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlanvlanmap
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlanvlanmap: Starting"
    }
    process {
        try {
            $arguments = @{ }

            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlanvlanmap -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlanvlanmap: Finished"
    }
}

function Invoke-ADCGetVxlanvlanmap {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Configuration for vxlan vlan mapping resource.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER GetAll
        Retrieve all vxlanvlanmap object(s).
    .PARAMETER Count
        If specified, the count of the vxlanvlanmap object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmap
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmap -GetAll
        Get all vxlanvlanmap data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmap -Count
        Get the number of vxlanvlanmap objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmap -name <string>
        Get vxlanvlanmap object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmap -Filter @{ 'name'='<value>' }
        Get vxlanvlanmap data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlanvlanmap
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll,

        [Parameter(ParameterSetName = 'GetAll')]
        [Parameter(ParameterSetName = 'Get')]
        [Switch]$ViewSummary

    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlanvlanmap: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{ }
                Write-Verbose "Retrieving all vxlanvlanmap objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlanvlanmap objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlanvlanmap objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlanvlanmap configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlanvlanmap configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlanvlanmap: Ended"
    }
}

function Invoke-ADCGetVxlanvlanmapbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to vxlanvlanmap.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER GetAll
        Retrieve all vxlanvlanmap_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlanvlanmap_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapbinding -GetAll
        Get all vxlanvlanmap_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapbinding -name <string>
        Get vxlanvlanmap_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapbinding -Filter @{ 'name'='<value>' }
        Get vxlanvlanmap_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlanvlanmapbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlanvlanmapbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlanvlanmap_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlanvlanmap_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlanvlanmap_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlanvlanmap_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlanvlanmap_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlanvlanmapbinding: Ended"
    }
}

function Invoke-ADCAddVxlanvlanmapvxlanbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the vxlan that can be bound to vxlanvlanmap.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER Vxlan
        The VXLAN assigned to the vlan inside the cloud.
    .PARAMETER Vlan
        The vlan id or the range of vlan ids in the on-premise network.
    .PARAMETER PassThru
        Return details about the created vxlanvlanmap_vxlan_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlanvlanmapvxlanbinding -name <string>
        An example how to add vxlanvlanmap_vxlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlanvlanmapvxlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap_vxlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [ValidateRange(1, 16777215)]
        [double]$Vxlan,

        [ValidateLength(1, 4094)]
        [string[]]$Vlan,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlanvlanmapvxlanbinding: Starting"
    }
    process {
        try {
            $payload = @{ name = $name }
            if ( $PSBoundParameters.ContainsKey('vxlan') ) { $payload.Add('vxlan', $vxlan) }
            if ( $PSBoundParameters.ContainsKey('vlan') ) { $payload.Add('vlan', $vlan) }
            if ( $PSCmdlet.ShouldProcess("vxlanvlanmap_vxlan_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vxlanvlanmap_vxlan_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlanvlanmapvxlanbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlanvlanmapvxlanbinding: Finished"
    }
}

function Invoke-ADCDeleteVxlanvlanmapvxlanbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the vxlan that can be bound to vxlanvlanmap.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER Vxlan
        The VXLAN assigned to the vlan inside the cloud.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlanvlanmapvxlanbinding -Name <string>
        An example how to delete vxlanvlanmap_vxlan_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlanvlanmapvxlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap_vxlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [string]$Name,

        [double]$Vxlan 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlanvlanmapvxlanbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Vxlan') ) { $arguments.Add('vxlan', $Vxlan) }
            if ( $PSCmdlet.ShouldProcess("$name", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Resource $name -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlanvlanmapvxlanbinding: Finished"
    }
}

function Invoke-ADCGetVxlanvlanmapvxlanbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the vxlan that can be bound to vxlanvlanmap.
    .PARAMETER Name
        Name of the mapping table.
    .PARAMETER GetAll
        Retrieve all vxlanvlanmap_vxlan_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlanvlanmap_vxlan_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapvxlanbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapvxlanbinding -GetAll
        Get all vxlanvlanmap_vxlan_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapvxlanbinding -Count
        Get the number of vxlanvlanmap_vxlan_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapvxlanbinding -name <string>
        Get vxlanvlanmap_vxlan_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanvlanmapvxlanbinding -Filter @{ 'name'='<value>' }
        Get vxlanvlanmap_vxlan_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlanvlanmapvxlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlanvlanmap_vxlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Name,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlanvlanmapvxlanbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlanvlanmap_vxlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlanvlanmap_vxlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlanvlanmap_vxlan_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlanvlanmap_vxlan_binding configuration for property 'name'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Resource $name -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlanvlanmap_vxlan_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlanvlanmap_vxlan_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlanvlanmapvxlanbinding: Ended"
    }
}

function Invoke-ADCGetVxlanbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object which returns the resources bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlan_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanbinding -GetAll
        Get all vxlan_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanbinding -name <string>
        Get vxlan_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlanbinding -Filter @{ 'name'='<value>' }
        Get vxlan_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlanbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlanbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlanbinding: Ended"
    }
}

function Invoke-ADCGetVxlaniptunnelbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the iptunnel that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan_iptunnel_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlan_iptunnel_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlaniptunnelbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlaniptunnelbinding -GetAll
        Get all vxlan_iptunnel_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlaniptunnelbinding -Count
        Get the number of vxlan_iptunnel_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlaniptunnelbinding -name <string>
        Get vxlan_iptunnel_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlaniptunnelbinding -Filter @{ 'name'='<value>' }
        Get vxlan_iptunnel_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlaniptunnelbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_iptunnel_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlaniptunnelbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlan_iptunnel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_iptunnel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan_iptunnel_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_iptunnel_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan_iptunnel_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_iptunnel_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan_iptunnel_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_iptunnel_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan_iptunnel_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_iptunnel_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlaniptunnelbinding: Ended"
    }
}

function Invoke-ADCAddVxlannsip6binding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Ipaddress
        The IP address assigned to the VXLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VXLAN.
    .PARAMETER PassThru
        Return details about the created vxlan_nsip6_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlannsip6binding -id <double>
        An example how to add vxlan_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [string]$Ipaddress,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Netmask,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlannsip6binding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSCmdlet.ShouldProcess("vxlan_nsip6_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vxlan_nsip6_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlannsip6binding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlannsip6binding: Finished"
    }
}

function Invoke-ADCDeleteVxlannsip6binding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Ipaddress
        The IP address assigned to the VXLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VXLAN.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlannsip6binding -Id <double>
        An example how to delete vxlan_nsip6_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlannsip6binding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlannsip6binding: Finished"
    }
}

function Invoke-ADCGetVxlannsip6binding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip6 that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan_nsip6_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlan_nsip6_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsip6binding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsip6binding -GetAll
        Get all vxlan_nsip6_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsip6binding -Count
        Get the number of vxlan_nsip6_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsip6binding -name <string>
        Get vxlan_nsip6_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsip6binding -Filter @{ 'name'='<value>' }
        Get vxlan_nsip6_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlannsip6binding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip6_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlannsip6binding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlan_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan_nsip6_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan_nsip6_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan_nsip6_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan_nsip6_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip6_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlannsip6binding: Ended"
    }
}

function Invoke-ADCAddVxlannsipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Ipaddress
        The IP address assigned to the VXLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VXLAN.
    .PARAMETER PassThru
        Return details about the created vxlan_nsip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlannsipbinding -id <double>
        An example how to add vxlan_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlannsipbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('ipaddress') ) { $payload.Add('ipaddress', $ipaddress) }
            if ( $PSBoundParameters.ContainsKey('netmask') ) { $payload.Add('netmask', $netmask) }
            if ( $PSCmdlet.ShouldProcess("vxlan_nsip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vxlan_nsip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlannsipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlannsipbinding: Finished"
    }
}

function Invoke-ADCDeleteVxlannsipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Ipaddress
        The IP address assigned to the VXLAN.
    .PARAMETER Netmask
        Subnet mask for the network address defined for this VXLAN.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlannsipbinding -Id <double>
        An example how to delete vxlan_nsip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Ipaddress,

        [string]$Netmask 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlannsipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Ipaddress') ) { $arguments.Add('ipaddress', $Ipaddress) }
            if ( $PSBoundParameters.ContainsKey('Netmask') ) { $arguments.Add('netmask', $Netmask) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlannsipbinding: Finished"
    }
}

function Invoke-ADCGetVxlannsipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the nsip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan_nsip_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlan_nsip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsipbinding -GetAll
        Get all vxlan_nsip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsipbinding -Count
        Get the number of vxlan_nsip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsipbinding -name <string>
        Get vxlan_nsip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlannsipbinding -Filter @{ 'name'='<value>' }
        Get vxlan_nsip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlannsipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_nsip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlannsipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlan_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan_nsip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan_nsip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan_nsip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan_nsip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_nsip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlannsipbinding: Ended"
    }
}

function Invoke-ADCAddVxlansrcipbinding {
    <#
    .SYNOPSIS
        Add Network configuration Object.
    .DESCRIPTION
        Binding object showing the srcip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Srcip
        The source IP address to use in outgoing vxlan packets.
    .PARAMETER PassThru
        Return details about the created vxlan_srcip_binding item.
    .EXAMPLE
        PS C:\>Invoke-ADCAddVxlansrcipbinding -id <double>
        An example how to add vxlan_srcip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCAddVxlansrcipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_srcip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [ValidateScript({ $_.Length -gt 1 })]
        [string]$Srcip,

        [Switch]$PassThru 
    )
    begin {
        Write-Verbose "Invoke-ADCAddVxlansrcipbinding: Starting"
    }
    process {
        try {
            $payload = @{ id = $id }
            if ( $PSBoundParameters.ContainsKey('srcip') ) { $payload.Add('srcip', $srcip) }
            if ( $PSCmdlet.ShouldProcess("vxlan_srcip_binding", "Add Network configuration Object") ) {
                $result = Invoke-ADCNitroApi -ADCSession $ADCSession -Method PUT -NitroPath nitro/v1/config -Type vxlan_srcip_binding -Payload $payload -GetWarning
                #HTTP Status Code on Success: 201 Created
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                if ( $PSBoundParameters.ContainsKey('PassThru') ) {
                    Write-Output (Invoke-ADCGetVxlansrcipbinding -Filter $payload)
                } else {
                    Write-Output $result
                }
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCAddVxlansrcipbinding: Finished"
    }
}

function Invoke-ADCDeleteVxlansrcipbinding {
    <#
    .SYNOPSIS
        Delete Network configuration Object.
    .DESCRIPTION
        Binding object showing the srcip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER Srcip
        The source IP address to use in outgoing vxlan packets.
    .EXAMPLE
        PS C:\>Invoke-ADCDeleteVxlansrcipbinding -Id <double>
        An example how to delete vxlan_srcip_binding configuration Object(s).
    .NOTES
        File Name : Invoke-ADCDeleteVxlansrcipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_srcip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "Low")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(Mandatory)]
        [double]$Id,

        [string]$Srcip 
    )
    begin {
        Write-Verbose "Invoke-ADCDeleteVxlansrcipbinding: Starting"
    }
    process {
        try {
            $arguments = @{ }
            if ( $PSBoundParameters.ContainsKey('Srcip') ) { $arguments.Add('srcip', $Srcip) }
            if ( $PSCmdlet.ShouldProcess("$id", "Delete Network configuration Object") ) {
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method DELETE -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Resource $id -Arguments $arguments
                #HTTP Status Code on Success: 200 OK
                #HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error
                Write-Output $response
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            throw $_
        }
    }
    end {
        Write-Verbose "Invoke-ADCDeleteVxlansrcipbinding: Finished"
    }
}

function Invoke-ADCGetVxlansrcipbinding {
    <#
    .SYNOPSIS
        Get Network configuration object(s).
    .DESCRIPTION
        Binding object showing the srcip that can be bound to vxlan.
    .PARAMETER Id
        A positive integer, which is also called VXLAN Network Identifier (VNI), that uniquely identifies a VXLAN.
    .PARAMETER GetAll
        Retrieve all vxlan_srcip_binding object(s).
    .PARAMETER Count
        If specified, the count of the vxlan_srcip_binding object(s) will be returned.
    .PARAMETER Filter
        Specify a filter.
        -Filter @{ 'name'='<value>' }
    .PARAMETER ViewSummary
        When specified, only a summary of information is returned.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlansrcipbinding
        Get data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlansrcipbinding -GetAll
        Get all vxlan_srcip_binding data.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlansrcipbinding -Count
        Get the number of vxlan_srcip_binding objects.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlansrcipbinding -name <string>
        Get vxlan_srcip_binding object by specifying for example the name.
    .EXAMPLE
        PS C:\>Invoke-ADCGetVxlansrcipbinding -Filter @{ 'name'='<value>' }
        Get vxlan_srcip_binding data with a filter.
    .NOTES
        File Name : Invoke-ADCGetVxlansrcipbinding
        Version : v2210.2317
        Author : John Billekens
        Reference : https://developer-docs.citrix.com/projects/citrix-adc-nitro-api-reference/en/latest/configuration/network/vxlan_srcip_binding/
        Requires : PowerShell v5.1 and up
                    ADC 13.x and up.
                    ADC 12 and lower may work, not guaranteed.
    .LINK
        https://blog.j81.nl
    #>

    [CmdletBinding(DefaultParameterSetName = "GetAll")]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingPlainTextForPassword', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSAvoidUsingUserNameAndPasswordParams', '')]
    [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute('PSUseBOMForUnicodeEncodedFile', '')]
    param(
        [Parameter(DontShow)]
        [Object]$ADCSession = (Get-ADCSession),

        [Parameter(ParameterSetName = 'GetByResource')]
        [ValidateRange(1, 16777215)]
        [double]$Id,

        [Parameter(ParameterSetName = 'Count', Mandatory)]
        [Switch]$Count,
            
        [hashtable]$Filter = @{ },

        [Parameter(ParameterSetName = 'GetAll')]
        [Switch]$GetAll
    )
    begin {
        Write-Verbose "Invoke-ADCGetVxlansrcipbinding: Beginning"
    }
    process {
        try {
            if ( $PsCmdlet.ParameterSetName -eq 'GetAll' ) {
                $query = @{  bulkbindings = 'yes' }
                Write-Verbose "Retrieving all vxlan_srcip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'Count' ) {
                if ( $PSBoundParameters.ContainsKey('Count') ) { $query = @{ 'count' = 'yes' } }
                Write-Verbose "Retrieving total count for vxlan_srcip_binding objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Query $query -Summary:$ViewSummary -Filter $Filter -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByArgument' ) {
                Write-Verbose "Retrieving vxlan_srcip_binding objects by arguments"
                $arguments = @{ } 
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Arguments $arguments -GetWarning
            } elseif ( $PsCmdlet.ParameterSetName -eq 'GetByResource' ) {
                Write-Verbose "Retrieving vxlan_srcip_binding configuration for property 'id'"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Resource $id -Summary:$ViewSummary -Filter $Filter -GetWarning
            } else {
                Write-Verbose "Retrieving vxlan_srcip_binding configuration objects"
                $response = Invoke-ADCNitroApi -ADCSession $ADCSession -Method GET -Type vxlan_srcip_binding -NitroPath nitro/v1/config -Summary:$ViewSummary -Query $query -Filter $Filter -GetWarning
            }
        } catch {
            Write-Verbose "ERROR: $($_.Exception.Message)"
            $response = $null
        }
        Write-Output $response
    }
    end {
        Write-Verbose "Invoke-ADCGetVxlansrcipbinding: Ended"
    }
}

# SIG # Begin signature block
# MIITYgYJKoZIhvcNAQcCoIITUzCCE08CAQExDzANBglghkgBZQMEAgEFADB5Bgor
# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCCGvtORdJiy4nhB
# C55lV/yAYjS24AUEmZ1XXqbca52nQqCCEHUwggTzMIID26ADAgECAhAsJ03zZBC0
# i/247uUvWN5TMA0GCSqGSIb3DQEBCwUAMHwxCzAJBgNVBAYTAkdCMRswGQYDVQQI
# ExJHcmVhdGVyIE1hbmNoZXN0ZXIxEDAOBgNVBAcTB1NhbGZvcmQxGDAWBgNVBAoT
# D1NlY3RpZ28gTGltaXRlZDEkMCIGA1UEAxMbU2VjdGlnbyBSU0EgQ29kZSBTaWdu
# aW5nIENBMB4XDTIxMDUwNTAwMDAwMFoXDTI0MDUwNDIzNTk1OVowWzELMAkGA1UE
# BhMCTkwxEjAQBgNVBAcMCVZlbGRob3ZlbjEbMBkGA1UECgwSSm9oYW5uZXMgQmls
# bGVrZW5zMRswGQYDVQQDDBJKb2hhbm5lcyBCaWxsZWtlbnMwggEiMA0GCSqGSIb3
# DQEBAQUAA4IBDwAwggEKAoIBAQCsfgRG81keOHalHfCUgxOa1Qy4VNOnGxB8SL8e
# rjP9SfcF13McP7F1HGka5Be495pTZ+duGbaQMNozwg/5Dg9IRJEeBabeSSJJCbZo
# SNpmUu7NNRRfidQxlPC81LxTVHxJ7In0MEfCVm7rWcri28MRCAuafqOfSE+hyb1Z
# /tKyCyQ5RUq3kjs/CF+VfMHsJn6ZT63YqewRkwHuc7UogTTZKjhPJ9prGLTer8UX
# UgvsGRbvhYZXIEuy+bmx/iJ1yRl1kX4nj6gUYzlhemOnlSDD66YOrkLDhXPMXLym
# AN7h0/W5Bo//R5itgvdGBkXkWCKRASnq/9PTcoxW6mwtgU8xAgMBAAGjggGQMIIB
# jDAfBgNVHSMEGDAWgBQO4TqoUzox1Yq+wbutZxoDha00DjAdBgNVHQ4EFgQUZWMy
# gC0i1u2NZ1msk2Mm5nJm5AswDgYDVR0PAQH/BAQDAgeAMAwGA1UdEwEB/wQCMAAw
# EwYDVR0lBAwwCgYIKwYBBQUHAwMwEQYJYIZIAYb4QgEBBAQDAgQQMEoGA1UdIARD
# MEEwNQYMKwYBBAGyMQECAQMCMCUwIwYIKwYBBQUHAgEWF2h0dHBzOi8vc2VjdGln
# by5jb20vQ1BTMAgGBmeBDAEEATBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3Js
# LnNlY3RpZ28uY29tL1NlY3RpZ29SU0FDb2RlU2lnbmluZ0NBLmNybDBzBggrBgEF
# BQcBAQRnMGUwPgYIKwYBBQUHMAKGMmh0dHA6Ly9jcnQuc2VjdGlnby5jb20vU2Vj
# dGlnb1JTQUNvZGVTaWduaW5nQ0EuY3J0MCMGCCsGAQUFBzABhhdodHRwOi8vb2Nz
# cC5zZWN0aWdvLmNvbTANBgkqhkiG9w0BAQsFAAOCAQEARjv9ieRocb1DXRWm3XtY
# jjuSRjlvkoPd9wS6DNfsGlSU42BFd9LCKSyRREZVu8FDq7dN0PhD4bBTT+k6AgrY
# KG6f/8yUponOdxskv850SjN2S2FeVuR20pqActMrpd1+GCylG8mj8RGjdrLQ3QuX
# qYKS68WJ39WWYdVB/8Ftajir5p6sAfwHErLhbJS6WwmYjGI/9SekossvU8mZjZwo
# Gbu+fjZhPc4PhjbEh0ABSsPMfGjQQsg5zLFjg/P+cS6hgYI7qctToo0TexGe32DY
# fFWHrHuBErW2qXEJvzSqM5OtLRD06a4lH5ZkhojhMOX9S8xDs/ArDKgX1j1Xm4Tu
# DjCCBYEwggRpoAMCAQICEDlyRDr5IrdR19NsEN0xNZUwDQYJKoZIhvcNAQEMBQAw
# ezELMAkGA1UEBhMCR0IxGzAZBgNVBAgMEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G
# A1UEBwwHU2FsZm9yZDEaMBgGA1UECgwRQ29tb2RvIENBIExpbWl0ZWQxITAfBgNV
# BAMMGEFBQSBDZXJ0aWZpY2F0ZSBTZXJ2aWNlczAeFw0xOTAzMTIwMDAwMDBaFw0y
# ODEyMzEyMzU5NTlaMIGIMQswCQYDVQQGEwJVUzETMBEGA1UECBMKTmV3IEplcnNl
# eTEUMBIGA1UEBxMLSmVyc2V5IENpdHkxHjAcBgNVBAoTFVRoZSBVU0VSVFJVU1Qg
# TmV0d29yazEuMCwGA1UEAxMlVVNFUlRydXN0IFJTQSBDZXJ0aWZpY2F0aW9uIEF1
# dGhvcml0eTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAIASZRc2DsPb
# CLPQrFcNdu3NJ9NMrVCDYeKqIE0JLWQJ3M6Jn8w9qez2z8Hc8dOx1ns3KBErR9o5
# xrw6GbRfpr19naNjQrZ28qk7K5H44m/Q7BYgkAk+4uh0yRi0kdRiZNt/owbxiBhq
# kCI8vP4T8IcUe/bkH47U5FHGEWdGCFHLhhRUP7wz/n5snP8WnRi9UY41pqdmyHJn
# 2yFmsdSbeAPAUDrozPDcvJ5M/q8FljUfV1q3/875PbcstvZU3cjnEjpNrkyKt1ya
# tLcgPcp/IjSufjtoZgFE5wFORlObM2D3lL5TN5BzQ/Myw1Pv26r+dE5px2uMYJPe
# xMcM3+EyrsyTO1F4lWeL7j1W/gzQaQ8bD/MlJmszbfduR/pzQ+V+DqVmsSl8MoRj
# VYnEDcGTVDAZE6zTfTen6106bDVc20HXEtqpSQvf2ICKCZNijrVmzyWIzYS4sT+k
# OQ/ZAp7rEkyVfPNrBaleFoPMuGfi6BOdzFuC00yz7Vv/3uVzrCM7LQC/NVV0CUnY
# SVgaf5I25lGSDvMmfRxNF7zJ7EMm0L9BX0CpRET0medXh55QH1dUqD79dGMvsVBl
# CeZYQi5DGky08CVHWfoEHpPUJkZKUIGy3r54t/xnFeHJV4QeD2PW6WK61l9VLupc
# xigIBCU5uA4rqfJMlxwHPw1S9e3vL4IPAgMBAAGjgfIwge8wHwYDVR0jBBgwFoAU
# oBEKIz6W8Qfs4q8p74Klf9AwpLQwHQYDVR0OBBYEFFN5v1qqK0rPVIDh2JvAnfKy
# A2bLMA4GA1UdDwEB/wQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MBEGA1UdIAQKMAgw
# BgYEVR0gADBDBgNVHR8EPDA6MDigNqA0hjJodHRwOi8vY3JsLmNvbW9kb2NhLmNv
# bS9BQUFDZXJ0aWZpY2F0ZVNlcnZpY2VzLmNybDA0BggrBgEFBQcBAQQoMCYwJAYI
# KwYBBQUHMAGGGGh0dHA6Ly9vY3NwLmNvbW9kb2NhLmNvbTANBgkqhkiG9w0BAQwF
# AAOCAQEAGIdR3HQhPZyK4Ce3M9AuzOzw5steEd4ib5t1jp5y/uTW/qofnJYt7wNK
# fq70jW9yPEM7wD/ruN9cqqnGrvL82O6je0P2hjZ8FODN9Pc//t64tIrwkZb+/UNk
# fv3M0gGhfX34GRnJQisTv1iLuqSiZgR2iJFODIkUzqJNyTKzuugUGrxx8VvwQQuY
# AAoiAxDlDLH5zZI3Ge078eQ6tvlFEyZ1r7uq7z97dzvSxAKRPRkA0xdcOds/exgN
# Rc2ThZYvXd9ZFk8/Ub3VRRg/7UqO6AZhdCMWtQ1QcydER38QXYkqa4UxFMToqWpM
# gLxqeM+4f452cpkMnf7XkQgWoaNflTCCBfUwggPdoAMCAQICEB2iSDBvmyYY0ILg
# ln0z02owDQYJKoZIhvcNAQEMBQAwgYgxCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpO
# ZXcgSmVyc2V5MRQwEgYDVQQHEwtKZXJzZXkgQ2l0eTEeMBwGA1UEChMVVGhlIFVT
# RVJUUlVTVCBOZXR3b3JrMS4wLAYDVQQDEyVVU0VSVHJ1c3QgUlNBIENlcnRpZmlj
# YXRpb24gQXV0aG9yaXR5MB4XDTE4MTEwMjAwMDAwMFoXDTMwMTIzMTIzNTk1OVow
# fDELMAkGA1UEBhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4G
# A1UEBxMHU2FsZm9yZDEYMBYGA1UEChMPU2VjdGlnbyBMaW1pdGVkMSQwIgYDVQQD
# ExtTZWN0aWdvIFJTQSBDb2RlIFNpZ25pbmcgQ0EwggEiMA0GCSqGSIb3DQEBAQUA
# A4IBDwAwggEKAoIBAQCGIo0yhXoYn0nwli9jCB4t3HyfFM/jJrYlZilAhlRGdDFi
# xRDtsocnppnLlTDAVvWkdcapDlBipVGREGrgS2Ku/fD4GKyn/+4uMyD6DBmJqGx7
# rQDDYaHcaWVtH24nlteXUYam9CflfGqLlR5bYNV+1xaSnAAvaPeX7Wpyvjg7Y96P
# v25MQV0SIAhZ6DnNj9LWzwa0VwW2TqE+V2sfmLzEYtYbC43HZhtKn52BxHJAteJf
# 7wtF/6POF6YtVbC3sLxUap28jVZTxvC6eVBJLPcDuf4vZTXyIuosB69G2flGHNyM
# fHEo8/6nxhTdVZFuihEN3wYklX0Pp6F8OtqGNWHTAgMBAAGjggFkMIIBYDAfBgNV
# HSMEGDAWgBRTeb9aqitKz1SA4dibwJ3ysgNmyzAdBgNVHQ4EFgQUDuE6qFM6MdWK
# vsG7rWcaA4WtNA4wDgYDVR0PAQH/BAQDAgGGMBIGA1UdEwEB/wQIMAYBAf8CAQAw
# HQYDVR0lBBYwFAYIKwYBBQUHAwMGCCsGAQUFBwMIMBEGA1UdIAQKMAgwBgYEVR0g
# ADBQBgNVHR8ESTBHMEWgQ6BBhj9odHRwOi8vY3JsLnVzZXJ0cnVzdC5jb20vVVNF
# UlRydXN0UlNBQ2VydGlmaWNhdGlvbkF1dGhvcml0eS5jcmwwdgYIKwYBBQUHAQEE
# ajBoMD8GCCsGAQUFBzAChjNodHRwOi8vY3J0LnVzZXJ0cnVzdC5jb20vVVNFUlRy
# dXN0UlNBQWRkVHJ1c3RDQS5jcnQwJQYIKwYBBQUHMAGGGWh0dHA6Ly9vY3NwLnVz
# ZXJ0cnVzdC5jb20wDQYJKoZIhvcNAQEMBQADggIBAE1jUO1HNEphpNveaiqMm/EA
# AB4dYns61zLC9rPgY7P7YQCImhttEAcET7646ol4IusPRuzzRl5ARokS9At3Wpwq
# QTr81vTr5/cVlTPDoYMot94v5JT3hTODLUpASL+awk9KsY8k9LOBN9O3ZLCmI2pZ
# aFJCX/8E6+F0ZXkI9amT3mtxQJmWunjxucjiwwgWsatjWsgVgG10Xkp1fqW4w2y1
# z99KeYdcx0BNYzX2MNPPtQoOCwR/oEuuu6Ol0IQAkz5TXTSlADVpbL6fICUQDRn7
# UJBhvjmPeo5N9p8OHv4HURJmgyYZSJXOSsnBf/M6BZv5b9+If8AjntIeQ3pFMcGc
# TanwWbJZGehqjSkEAnd8S0vNcL46slVaeD68u28DECV3FTSK+TbMQ5Lkuk/xYpMo
# JVcp+1EZx6ElQGqEV8aynbG8HArafGd+fS7pKEwYfsR7MUFxmksp7As9V1DSyt39
# ngVR5UR43QHesXWYDVQk/fBO4+L4g71yuss9Ou7wXheSaG3IYfmm8SoKC6W59J7u
# mDIFhZ7r+YMp08Ysfb06dy6LN0KgaoLtO0qqlBCk4Q34F8W2WnkzGJLjtXX4oemO
# CiUe5B7xn1qHI/+fpFGe+zmAEc3btcSnqIBv5VPU4OOiwtJbGvoyJi1qV3AcPKRY
# LqPzW0sH3DJZ84enGm1YMYICQzCCAj8CAQEwgZAwfDELMAkGA1UEBhMCR0IxGzAZ
# BgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEYMBYG
# A1UEChMPU2VjdGlnbyBMaW1pdGVkMSQwIgYDVQQDExtTZWN0aWdvIFJTQSBDb2Rl
# IFNpZ25pbmcgQ0ECECwnTfNkELSL/bju5S9Y3lMwDQYJYIZIAWUDBAIBBQCggYQw
# GAYKKwYBBAGCNwIBDDEKMAigAoAAoQKAADAZBgkqhkiG9w0BCQMxDAYKKwYBBAGC
# NwIBBDAcBgorBgEEAYI3AgELMQ4wDAYKKwYBBAGCNwIBFTAvBgkqhkiG9w0BCQQx
# IgQg/zpgSSXmxFkV8xceTlyy4itwOYp5FlXOyMGkWC2cFM8wDQYJKoZIhvcNAQEB
# BQAEggEAkY5kmCZMz+zlUZBCDI1ySi5zgBB3kUZTTyQxQD5KF5k8giDSj9LZvLCW
# ATj0xldvv8sr50WhVeLxeqJVNVc3TJ3UclndJAAkgT8bf3NNyf4aowqMcmOR2RC2
# G+RCDy6LyQijr6g2IV0S1/0MgFp8gs/OdJi9Ulm0h0JUeQBV/SQqSjRidtlFtdgm
# ty9Fhl0cHqyN2lmK8h1rdLZwyy8ckfR0nOjyEKmhkUt/B/N1Ccg/zhy6dEN7X7lg
# og/7cXF3IgHW4Jqihl1w+sLaKHBbSioTnStGPlFoRBXrvKfSm/W7+FDh/bLH39Ra
# 3qfVsRnhIlI5qRAtQGUbONRrma+2vQ==
# SIG # End signature block