You are configuring an Azure Event Grid subscription to route customer events to a third-party HTTP webhook endpoint that you do not control. Because the third-party endpoint cannot be modified to programmatically return the validation code synchronously, you must manually validate the subscription. You create the subscription, and its provisioning state is set to Pending. What must you do to complete the endpoint validation and activate the subscription?
- Locate the validation event sent to the webhook destination, copy the validationUrl, and send an HTTP GET request to that URL.Cevap
- BConfigure the event subscription to use a system-assigned managed identity, and grant it the EventGrid Contributor role on the destination endpoint.
- CGenerate a Shared Access Signature (SAS) token at the topic level and append it as a query parameter named validationToken to the endpoint URL.
- DRetrieve the validationCode from the event payload and send an HTTP POST request containing this code to the Event Grid custom topic endpoint.
Cevap
To manually validate the subscription, you must locate the validation event sent to the webhook, extract the validationUrl, and send an HTTP GET request to that URL.
When configuring an Event Grid subscription for a webhook that cannot programmatically respond to validation handshakes (such as a third-party service), developers must perform a manual handshake. This is done by intercepting the validation event payload sent to the webhook, copying the validationUrl from the event's data object, and making an HTTP GET request to that URL to activate the subscription.
Adım Adım Çözüm
Anahtar Kavram
Azure Event Grid webhook endpoint manual validation handshake