Create an Azure event grid subscription
Learn how to create an event grid subscription in your Azure account.
- Navigate to and select the Azure storage container for which you want to create an event grid subscription:
- In the Microsoft Azure portal, select Storage accounts.
- Select the storage account and storage container you previously created (for details see Create an Azure storage account container).
- On the Containers page, from the left navigation panel, select Events.
- In the Events page, select the Event Subscription tab and then the + Event Subscription button.
- In the Create Event Subscription page, complete the Basics tab:
-
Event Subscription Details:
-
Name: Enter a name for this event grid subscription.
Tip: Take note of this value. -
Event Schema: Select Event Grid Schema.
-
-
Topic Details:
-
Topic Type: View the type populated from the storage account you previously created in topic Create an Azure storage account.
-
Source Resource: View the resource populated from the Azure storage account you previously created.
-
System Topic Name: Enter a name for this topic to which events will be pushed.
-
-
Event types:
-
Filter to Event Types: Select Blob Created and clear any other options.
-
-
Endpoint Details:
-
Endpoint Type: Select Storage Queues.
-
Endpoint: Select this displayed link.
-
Queues In the displayed side panel, enter:
-
Subscription: Select the same subscription you selected in topic Create an Azure resource group.
-
Storage account: Select the storage account you selected in topic Create an Azure storage account.
-
Queue: Select Select existing queue, then from the list below select the storage queue you created in topic Create an Azure storage account queue.
-
-
-
- Select Select to conclude the Basics tab.
- Select the Filters tab and complete the following details.
-
Subject filters:
-
Enable subject filtering: Select this check box.
-
Subject begins with: In this displayed field, enter this string:
/blobServices/default/containers/<storage_container_name>/blobs/
where <storage_container_name> is the name of the storage container you previously created in topic Create an Azure storage account container.
-
Subject ends with: Enter .gz.
-
-
Advanced filters:
-
Select Add new filter: Fill in these fields:
- Key: Enter data.api.
- Operator: Select String is in.
- Value: Enter CopyBlob, PutBlob, PutBlocklist, FlushWithClose.
-
Enable advanced filtering on arrays: Leave this checkbox selected.
-
-
- Select Create. After a deployment success message clears, view your new subscription in the list.