Pax8API/Public/Webhooks/Update-Pax8WebhookTopics.ps1
|
<#
.SYNOPSIS Replace all webhook topics .DESCRIPTION Replace all webhook topics OpenAPI: PUT /webhooks/{id}/topics Scope: Webhooks. Audience: https://api.pax8.com. .PARAMETER Id path parameter 'id'. .PARAMETER WebhookTopics List of webhook topics to replace existing ones .PARAMETER Body Raw request body. This can be a hashtable, PSCustomObject, or pre-built JSON string. .EXAMPLE Update-Pax8WebhookTopics -Id '00000000-0000-0000-0000-000000000000' .LINK https://devx.pax8.com/openapi/webhooks-api.json #> function Update-Pax8WebhookTopics { [CmdletBinding()] param ( [Parameter(Mandatory = $true)] [guid]$Id, [Parameter(Mandatory = $true)] [object[]]$WebhookTopics, [Parameter(ValueFromPipeline = $true)] [object]$Body, [switch]$Raw ) process { $boundParameters = @{} foreach ($entry in $PSBoundParameters.GetEnumerator()) { $boundParameters[$entry.Key] = $entry.Value } Invoke-Pax8ApiOperation -CommandName $MyInvocation.MyCommand.Name -Parameters $boundParameters } } |