Pax8API/Public/Webhooks/Invoke-Pax8WebhookTopic.ps1
|
<#
.SYNOPSIS Test webhook topic .DESCRIPTION Test a webhook by sending a test event for a specific topic. This will send a example payload of what this topic provides. OpenAPI: POST /webhooks/{id}/topics/{topic}/test Scope: Webhooks. Audience: https://api.pax8.com. .PARAMETER Id path parameter 'id'. .PARAMETER Topic path parameter 'topic'. .EXAMPLE Invoke-Pax8WebhookTopic -Id '00000000-0000-0000-0000-000000000000' -Topic 'value' .LINK https://devx.pax8.com/openapi/webhooks-api.json #> function Invoke-Pax8WebhookTopic { [CmdletBinding()] param ( [Parameter(Mandatory = $true)] [guid]$Id, [Parameter(Mandatory = $true)] [string]$Topic, [switch]$Raw ) process { $boundParameters = @{} foreach ($entry in $PSBoundParameters.GetEnumerator()) { $boundParameters[$entry.Key] = $entry.Value } Invoke-Pax8ApiOperation -CommandName $MyInvocation.MyCommand.Name -Parameters $boundParameters } } |