The New-AzAutomationWebhook cmdlet creates a webhook for an Azure Automation runbook.
Be sure to save the webhook URL that this cmdlet returns, because it cannot be retrieved again.
This command creates a webhook named Webhook06 for the runbook named ContosoRunbook in the Automation account named AutomationAccount01.
The command stores the webhook in the $Webhook variable.
The webhook is enabled.
The webhook expires at the specified time.
This command does not provide any values for webhook parameters.
This command specifies the Force parameter.
Therefore, it does not prompt you for confirmation.
The first command creates a dictionary of parameters, and stores them in the $Params variable.
The second command creates a webhook named Webhook11 for the runbook named ContosoRunbook in the Automation account named AutomationAccount01.
The command assigns the parameters in $Params to the webhook.
Parameters
-AutomationAccountName
Specifies the name of an Automation account in which this cmdlet creates a webhook.
Specifies the expiry time for the webhook as a DateTimeOffset object.
You can specify a string or a DateTime that can be converted to a valid DateTimeOffset.
Specifies a dictionary of key/value pairs.
The keys are the runbook parameter names.
The values are the runbook parameter values.
When the runbook starts in response to a webhook, these parameters are passed to the runbook.
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters.