Key authentication with code

Azure Event Grid key authentication is the simplest way to publish an event to a custom Event Grid topic. In Event Grid key authentication, the client application has to pass aeg-sas-key as the header to event's POST operation. When using aeg-sas-key, it is always advisable to secure the keys within Azure Key Vault, or any secure storage of your choice, and retrieve the value at runtime.

The following function uses the Event Grid SDK, aeg-sas-key, and the topic endpoint for creating an Azure Event Grid topic connection before routing custom events. Once we have created a custom topic through the Azure portal or the Azure CLI, we can get the details of aeg-sas-key and the topic endpoint by navigating through the ...

Get Serverless Integration Design Patterns with Azure now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.