Skip to content

Latest commit

 

History

History
48 lines (32 loc) · 1.92 KB

event-grid-cli-subscribe-custom-topic.md

File metadata and controls

48 lines (32 loc) · 1.92 KB
title description services documentationcenter author ms.service ms.devlang ms.topic ms.tgt_pltfrm ms.workload ms.date ms.author
Azure CLI script sample - Subscribe to custom topic | Microsoft Docs
Azure CLI Script Sample - Subscribe to custom topic
event-grid
na
tfitzmac
event-grid
azurecli
sample
na
na
11/02/2018
tomfitz

Subscribe to events for a custom topic with Azure CLI

This script creates an Event Grid subscription to the events for a custom topic.

[!INCLUDE sample-cli-install]

[!INCLUDE quickstarts-free-trial-note]

The preview sample script requires the Event Grid extension. To install, run az extension add --name eventgrid.

Sample script - stable

[!code-azureclimain]

Sample script - preview extension

[!code-azureclimain]

Script explanation

This script uses the following command to create the event subscription. Each command in the table links to command-specific documentation.

Command Notes
az eventgrid event-subscription create Create an Event Grid subscription.
az eventgrid event-subscription create - extension version Create an Event Grid subscription.

Next steps