Azure Event Grid Component
Azure Event Grid is an event routing service that can be used to build event driven applications by distributing events from various sources to subscribers.
Component key: azure-event-grid · Changelog ↓Description
Azure Event Grid is used to build data pipelines, integrate applications, and create event-driven serverless solutions with a fully managed publish-subscribe messaging service.
API Documentation
The component was built using the Azure Event Grid REST API
Connections
OAuth 2.0
key: azure-event-grid-oauth2This authentication method may be used when an App requires granting admin consent to API permissions, in addition to authorizing the integration with the App's configured client credentials.
The Microsoft Event Grid component authenticates requests through the Microsoft Graph API.
Creating an App Registration
To configure OAuth 2.0, first create an App through Active Directory in the Microsoft Azure Portal.
- Navigate to App Registrations
- When creating the application, the system prompts to select Supported account types.
- Select Accounts in any organizational directory (Any Azure AD directory - Multitenant).
- Navigate to Redirect URI and add the Web platform. Now enter the redirect URI as
https://oauth2.prismatic.io/callback. - Select Register to complete.
- In the App, navigate to Certificates & Secrets and select New client secret. Copy/save the Value for use in the connection configuration of the integration (the value will not be shown again).
- Next, navigate to the Overview section and copy the Application (client) ID
- Navigate to the API Permissions section to assign the proper permissions for the integration. Select Add Permission, select all permissions that are required for the desired integration
and save these values for later. A full list of scopes can be found on
the Microsoft Graph API documentation 1. Recommended scopes for Active Directory can be found in Microsoft Graph > Delegated permissions: 1.
Group.ReadWrite.All GroupMember.ReadWrite.All Application.ReadWrite.All User.Read.All offline_access
Configuring the Integration
Supply the following values to the OAuth 2.0 Authorization Code connection in the integration:
- Client ID enter the Application (client) ID
- Client Secret enter the Value provided (Do not use Secret ID)
- If Multitenant was not selected when creating the App, it is necessary to replace the Authorize URL and Token URL with ones specific to the tenant.
| Input | Notes | Example |
|---|---|---|
| Authorize URL | The OAuth 2.0 Authorization URL for your Microsoft Event Grid. | https://login.microsoftonline.com/common/oauth2/v2.0/authorize |
| Client ID | Get this value from your App Registration in the Azure Portal | |
| Client Secret | Get this value from your App Registration in the Azure Portal | |
| Scopes | Microsoft Event Grid Scopes. | https://management.azure.com/.default offline_access |
| Token URL | The OAuth 2.0 Token URL for your Microsoft Event Grid | https://login.microsoftonline.com/common/oauth2/v2.0/token |
Triggers
Event Grid Trigger
Handle validation and delivery of Event Grid events | key: myTrigger
| Input | Notes | Example |
|---|---|---|
| Event Topics to Listen For | The topics to listen for events on |
An Azure Event Grid webhook subscription can be configured to deliver events to a flow's webhook URL. This trigger handles the subscription validation handshake automatically and routes incoming events through configurable branches.
The trigger supports both the Event Grid Schema and the CloudEvents v1.0 Schema.
How It Works
Azure Event Grid uses a validation handshake to confirm ownership of the webhook endpoint. When a new event subscription is created, Event Grid sends a Microsoft.EventGrid.SubscriptionValidationEvent containing a validation code. This trigger automatically responds with the required validation code, completing the handshake without any additional configuration.
The trigger uses three branches to route requests:
- Validation Event: Handles subscription validation handshake requests from Azure Event Grid. This branch is invoked automatically during initial webhook registration and responds with the validation code that Event Grid requires.
- Process Event: Handles actual event notifications that match the configured event topics. The event payload is forwarded for processing.
- Skip Event: Handles event notifications that do not match any of the configured event topics. A
200response is returned, but no processing occurs.
For the CloudEvents v1.0 Schema, Event Grid sends an OPTIONS request instead of a validation event. The trigger automatically responds with the appropriate WebHook-Allowed-Origin headers.
Configuration
Configure the following inputs:
- Event Topics to Listen For: A list of event types the trigger should process (e.g.,
Microsoft.Storage.BlobCreated,Microsoft.Resources.ResourceWriteSuccess). Events not matching these topics are routed to the Skip Event branch.
Refer to the Azure Event Grid event types documentation for a complete list of available system event types.
Returned Data
Example Event Grid Schema Payload
[
{
"id": "b3ccc7e3-c1cb-49bf-b7c8-0d4e60980616",
"topic": "/subscriptions/{subscription-id}/resourceGroups/{resource-group}/providers/Microsoft.Storage/storageAccounts/{storage-account}",
"subject": "/blobServices/default/containers/my-container/blobs/my-blob.txt",
"data": {
"api": "PutBlob",
"clientRequestId": "6d79dbfb-0e37-4fc4-981f-442c9ca65760",
"requestId": "831e1650-001e-001b-66ab-eeb76e000000",
"eTag": "0x8D4BCC2E4835CD0",
"contentType": "text/plain",
"contentLength": 524288,
"blobType": "BlockBlob",
"url": "https://example.blob.core.windows.net/my-container/my-blob.txt"
},
"eventType": "Microsoft.Storage.BlobCreated",
"eventTime": "2024-01-15T10:30:00.000Z",
"metadataVersion": "1",
"dataVersion": "1"
}
]
Example CloudEvents v1.0 Payload
[
{
"id": "b3ccc7e3-c1cb-49bf-b7c8-0d4e60980616",
"source": "/subscriptions/{subscription-id}/resourceGroups/{resource-group}/providers/Microsoft.Storage/storageAccounts/{storage-account}",
"specversion": "1.0",
"type": "Microsoft.Storage.BlobCreated",
"time": "2024-01-15T10:30:00.000Z",
"data": {
"api": "PutBlob",
"clientRequestId": "6d79dbfb-0e37-4fc4-981f-442c9ca65760",
"requestId": "831e1650-001e-001b-66ab-eeb76e000000",
"contentType": "text/plain",
"contentLength": 524288,
"blobType": "BlockBlob",
"url": "https://example.blob.core.windows.net/my-container/my-blob.txt"
}
}
]
Notes
- Azure Event Grid does not use HMAC signature validation for webhook endpoints. The subscription validation handshake is the documented security mechanism.
- Events that do not match the configured event topics are silently acknowledged with a
200response and routed to the Skip Event branch. - The maximum delivery attempt count and event time-to-live are configured on the Azure Event Grid subscription itself, not on this trigger.
Data Sources
Select Event Subscription
Select an event subscription from the specified topic. | key: selectEventSubscription | type: picklist
| Input | Notes | Example |
|---|---|---|
| Connection | The Azure Event Grid connection to use. | |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
Actions
Create or Update Event Subscription
Asynchronously creates a new event subscription or updates an existing event subscription based on the specified scope. | key: createOrUpdateEventSubscription
| Input | Notes | Example |
|---|---|---|
| Body Fields | Extra fields to include in the body of the request. | |
| Connection | The Azure Event Grid connection to use. | |
| Event Delivery Schema | The event delivery schema for the event subscription. | |
| Event Subscription Name | The name of the event subscription to use. | myeventsubscriptionxxx |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
| Webhook URL | The URL to send the event to. If not provided, the event will be sent to the current flow endpoint. | https://example.com/webhook |
{
"data": {
"properties": {
"destination": {
"properties": {
"endpointBaseUrl": "https://requestb.in/15ksip71"
},
"endpointType": "WebHook"
},
"filter": {
"isSubjectCaseSensitive": false,
"subjectBeginsWith": "ExamplePrefix",
"subjectEndsWith": "ExampleSuffix"
},
"labels": [
"label1",
"label2"
],
"provisioningState": "Succeeded",
"topic": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/microsoft.eventgrid/topics/exampletopic2"
},
"id": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/Microsoft.EventGrid/topics/exampletopic2/providers/Microsoft.EventGrid/eventSubscriptions/examplesubscription1",
"name": "examplesubscription1",
"type": "Microsoft.EventGrid/eventSubscriptions"
}
}
Delete Event Subscription
Delete an existing event subscription. | key: deleteEventSubscription
| Input | Notes | Example |
|---|---|---|
| Connection | The Azure Event Grid connection to use. | |
| Event Subscription Name | The name of the event subscription to use. | myeventsubscriptionxxx |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
{
"data": "DELETED SUCCESSFULLY"
}
Get Event Subscription
Get properties of an event subscription. | key: getEventSubscription
| Input | Notes | Example |
|---|---|---|
| Connection | The Azure Event Grid connection to use. | |
| Event Subscription Name | The name of the event subscription to use. | myeventsubscriptionxxx |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
{
"data": {
"properties": {
"destination": {
"properties": {
"endpointBaseUrl": "https://requestb.in/15ksip71"
},
"endpointType": "WebHook"
},
"filter": {
"isSubjectCaseSensitive": false,
"subjectBeginsWith": "ExamplePrefix",
"subjectEndsWith": "ExampleSuffix"
},
"labels": [
"label1",
"label2"
],
"provisioningState": "Succeeded",
"topic": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/microsoft.eventgrid/topics/exampletopic2"
},
"id": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/Microsoft.EventGrid/topics/exampletopic2/providers/Microsoft.EventGrid/eventSubscriptions/examplesubscription1",
"name": "examplesubscription1",
"type": "Microsoft.EventGrid/eventSubscriptions"
}
}
List Event Subscriptions
List all event subscriptions that have been created for a specific topic. | key: listEventSubscriptions
| Input | Notes | Example |
|---|---|---|
| Filter | The query used to filter the search results using OData syntax. Filtering is permitted on the 'name' property only and with limited number of OData operations. The following is a valid filter example: $filter=contains(namE, 'PATTERN') and name ne 'PATTERN-1'. | contains(namE, 'PATTERN') and name ne 'PATTERN-1' |
| Top | The number of results to return per page for the list operation. Valid range for top parameter is 1 to 100. If not specified, the default number of results to be returned is 20 items per page. | 20 |
| Connection | The Azure Event Grid connection to use. | |
| Fetch All | When true, fetches all pages of results. | false |
| Next Link | The next link to fetch the next page of results. | https://management.azure.com/subscriptions/503a76a6-249f-422e-a06a-12345/resourceGroups/AzureEventGrid/providers/Microsoft.EventGrid/topics/AzureTestGrid/providers/Microsoft.EventGrid/eventSubscriptions?api-version=2022-06-15&$skiptoken=%5b%7b%22token%22%3anull%2c%22range%22%3a%7b%22min%22%3a%2205C1DF6B5557E0%22%2c%22max%22%3a%22FF%22%7d%7d%5d&$top=20 |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
{
"data": {
"value": [
{
"properties": {
"destination": {
"properties": {
"endpointBaseUrl": "https://requestb.in/15ksip71"
},
"endpointType": "WebHook"
},
"filter": {
"isSubjectCaseSensitive": false,
"subjectBeginsWith": "ExamplePrefix",
"subjectEndsWith": "ExampleSuffix"
},
"labels": [
"label1",
"label2"
],
"provisioningState": "Succeeded",
"topic": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/microsoft.eventgrid/topics/exampletopic2"
},
"id": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/Microsoft.EventGrid/topics/exampletopic2/providers/Microsoft.EventGrid/eventSubscriptions/examplesubscription1",
"name": "examplesubscription1",
"type": "Microsoft.EventGrid/eventSubscriptions"
}
],
"nextLink": null
}
}
Publish Events
Publishes a batch of events to an Azure Event Grid topic. | key: publishEvents
| Input | Notes | Example |
|---|---|---|
| Connection | The Azure Event Grid connection to use. | |
| Events | The events to publish. The events must match the schema of the topic. | |
| Topic Access Key | The access key of the topic. | AzVWk42YmQlshLB7o5pxJqBTBYmkS1SAEGldtYeLcWAu5gzk5YKpJQQJ99AKACYesed1SSsd1s |
| Topic Host Name | The host name of the topic. | topic1.westus2-1.eventgrid.azure.net |
{
"data": {
"properties": {
"destination": {
"properties": {
"endpointBaseUrl": "https://requestb.in/15ksip71"
},
"endpointType": "WebHook"
},
"filter": {
"isSubjectCaseSensitive": false,
"subjectBeginsWith": "ExamplePrefix",
"subjectEndsWith": "ExampleSuffix"
},
"labels": [
"label1",
"label2"
],
"provisioningState": "Succeeded",
"topic": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/microsoft.eventgrid/topics/exampletopic2"
},
"id": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/Microsoft.EventGrid/topics/exampletopic2/providers/Microsoft.EventGrid/eventSubscriptions/examplesubscription1",
"name": "examplesubscription1",
"type": "Microsoft.EventGrid/eventSubscriptions"
}
}
Update Event Subscription
Asynchronously updates an existing event subscription. | key: updateEventSubscription
| Input | Notes | Example |
|---|---|---|
| Body Fields | Extra fields to include in the body of the request. | |
| Connection | The Azure Event Grid connection to use. | |
| Event Delivery Schema | The event delivery schema for the event subscription. | |
| Event Subscription Name | The name of the event subscription to use. | myeventsubscriptionxxx |
| Resource Group Name | The name of the resource group to use. | my-resource-group |
| Subscription ID | The ID of the subscription to use. | 00000000-0000-0000-0000-000000000000 |
| Topic | The name of the topic to subscribe to. | my-topic |
| Webhook URL | The URL to send the event to. If not provided, the event will be sent to the current flow endpoint. | https://example.com/webhook |
{
"data": {
"properties": {
"destination": {
"properties": {
"endpointBaseUrl": "https://requestb.in/15ksip71"
},
"endpointType": "WebHook"
},
"filter": {
"isSubjectCaseSensitive": false,
"subjectBeginsWith": "ExamplePrefix",
"subjectEndsWith": "ExampleSuffix"
},
"labels": [
"label1",
"label2"
],
"provisioningState": "Succeeded",
"topic": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/microsoft.eventgrid/topics/exampletopic2"
},
"id": "/subscriptions/5b4b650e-28b9-4790-b3ab-ddbd88d727c4/resourceGroups/examplerg/providers/Microsoft.EventGrid/topics/exampletopic2/providers/Microsoft.EventGrid/eventSubscriptions/examplesubscription1",
"name": "examplesubscription1",
"type": "Microsoft.EventGrid/eventSubscriptions"
}
}
Changelog
2026-04-07
Various modernizations and documentation updates
2026-02-03
Added Select Event Subscription data source for selecting event subscriptions from a topic