Skip to content

Commit 5f42734

Browse files
Added a note
1 parent ee90c6b commit 5f42734

File tree

2 files changed

+22
-6
lines changed

2 files changed

+22
-6
lines changed

articles/automation/automation-runbook-types.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Azure Automation Runbook Types
33
description: This article describes the types of runbooks that you can use in Azure Automation and considerations for determining which type to use.
44
services: automation
55
ms.subservice: process-automation
6-
ms.date: 06/27/2025
6+
ms.date: 07/15/2025
77
ms.topic: overview
88
ms.custom: references_regions, devx-track-python, devx-track-azurepowershell
99
ms.service: azure-automation
@@ -371,6 +371,9 @@ The limitations of Python runbooks are:
371371

372372
---
373373

374+
> [!NOTE]
375+
> Using a webhook to start a Python runbook is not supported.
376+
374377
### Multiple Python versions
375378

376379
It's applicable for Windows Hybrid workers. For a Windows Runbook Worker, when running a Python 2 runbook it looks for the environment variable `PYTHON_2_PATH` first and validates whether it points to a valid executable file. For example, if the installation folder is `C:\Python2`, it would check if `C:\Python2\python.exe` is a valid path. If not found, then it looks for the `PATH` environment variable to do a similar check.

articles/automation/automation-webhooks.md

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
2-
title: Start an Azure Automation runbook from a webhook
2+
title: Start an Azure Automation Runbook from a Webhook
33
description: This article tells how to use a webhook to start a runbook in Azure Automation from an HTTP call.
44
services: automation
55
ms.subservice: process-automation
6-
ms.date: 09/09/2024
6+
ms.date: 07/15/2025
77
ms.topic: how-to
88
ms.custom: devx-track-azurepowershell, devx-track-arm-template
99
ms.service: azure-automation
@@ -90,7 +90,10 @@ Consider the following strategies:
9090
## Create a webhook
9191

9292
> [!NOTE]
93-
> When you use the webhook with PowerShell 7 runbook, it auto-converts the webhook input parameter to an invalid JSON. For more information, see [Known issues - PowerShell 7.1 (preview)](./automation-runbook-types.md#limitations-and-known-issues). We recommend that you use the webhook with PowerShell 5 runbook.
93+
> * When you use the webhook with PowerShell 7 runbook, it auto-converts the webhook input parameter to an invalid JSON. For more information, see [Known issues - PowerShell 7.1 (preview)](./automation-runbook-types.md#limitations-and-known-issues). We recommend that you use the webhook with PowerShell 5 runbook.
94+
> * Using a webhook to start a Python runbook is not supported.
95+
96+
To create a webhook, follow these steps:
9497

9598
1. Create PowerShell runbook with the following code:
9699

@@ -127,6 +130,8 @@ Consider the following strategies:
127130
128131
# [Azure portal](#tab/portal)
129132
133+
To create a webhook using the Azure portal, do the following:
134+
130135
1. Sign in to the [Azure portal](https://portal.azure.com/).
131136
132137
1. In the Azure portal, navigate to your Automation account.
@@ -145,7 +150,7 @@ Consider the following strategies:
145150
146151
1. Enter in the **Name** for the webhook. The expiration date for the field **Expires** defaults to one year from the current date.
147152
148-
1. Click the copy icon or press <kbd>Ctrl + C</kbd> copy the URL of the webhook. Then save the URL to a secure location.
153+
1. Select the copy icon or press <kbd>Ctrl + C</kbd> copy the URL of the webhook. Then, save the URL to a secure location.
149154
150155
:::image type="content" source="media/automation-webhooks/create-new-webhook.png" alt-text="Create webhook page with URL highlighted.":::
151156
@@ -164,6 +169,8 @@ Consider the following strategies:
164169
165170
# [PowerShell](#tab/powershell)
166171
172+
To create a webhook using PowerShell, do the following:
173+
167174
1. Verify you have the latest version of the PowerShell [Az Module](/powershell/azure/new-azureps-module-az) installed.
168175
169176
1. Sign in to Azure interactively using the [Connect-AzAccount](/powershell/module/Az.Accounts/Connect-AzAccount) cmdlet and follow the instructions.
@@ -214,6 +221,8 @@ Consider the following strategies:
214221
215222
# [REST API](#tab/rest)
216223
224+
To create a webhook using REST API, do the following:
225+
217226
The PUT command is documented at [Webhook - Create Or Update](/rest/api/automation/webhook/create-or-update). This example uses the PowerShell cmdlet [Invoke-RestMethod](/powershell/module/microsoft.powershell.utility/invoke-restmethod) to send the PUT request.
218227
219228
1. Create a file called `webhook.json` and then paste the following code:
@@ -302,6 +311,8 @@ Consider the following strategies:
302311
303312
This example uses the PowerShell cmdlet [Invoke-WebRequest](/powershell/module/microsoft.powershell.utility/invoke-webrequest) to send the POST request to your new webhook.
304313
314+
To use a webhook, follow these steps:
315+
305316
1. Prepare values to pass to the runbook as the body for the webhook call. For relatively simple values, you could script the values as follows:
306317
307318
```powershell
@@ -380,7 +391,7 @@ This example uses the PowerShell cmdlet [Invoke-WebRequest](/powershell/module/m
380391
381392
## Update a webhook
382393
383-
When a webhook is created, it has a validity time period of 10 years, after which it automatically expires. Once a webhook has expired, you can't reactivate it. You can only remove and then recreate it. You can extend a webhook that hasn't reached its expiration time. To extend a webhook, perform the following steps.
394+
When a webhook is created, it has a validity time period of 10 years, after which it automatically expires. Once a webhook has expired, you can't reactivate it. You can only remove and then recreate it. You can extend a webhook that hasn't reached its expiration time. To extend a webhook, perform the following steps:
384395
385396
1. Navigate to the runbook that contains the webhook.
386397
1. Under **Resources**, select **Webhooks**, and then the webhook that you want to extend.
@@ -413,6 +424,8 @@ Here are examples of removing a webhook from an Automation runbook.
413424
414425
Automation webhooks can also be created using [Azure Resource Manager](../azure-resource-manager/templates/overview.md) templates. This sample template creates an Automation account, four runbooks, and a webhook for the named runbook.
415426
427+
To create a webhook using an ARM template, follow these steps:
428+
416429
1. Create a file named `webhook_deploy.json` and then paste the following code:
417430
418431
```json

0 commit comments

Comments
 (0)