Franz.Common.Messaging.AzureEventGrid 3.0.0

dotnet add package Franz.Common.Messaging.AzureEventGrid --version 3.0.0
                    
NuGet\Install-Package Franz.Common.Messaging.AzureEventGrid -Version 3.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Franz.Common.Messaging.AzureEventGrid" Version="3.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Franz.Common.Messaging.AzureEventGrid" Version="3.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Franz.Common.Messaging.AzureEventGrid" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Franz.Common.Messaging.AzureEventGrid --version 3.0.0
                    
#r "nuget: Franz.Common.Messaging.AzureEventGrid, 3.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Franz.Common.Messaging.AzureEventGrid@3.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Franz.Common.Messaging.AzureEventGrid&version=3.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Franz.Common.Messaging.AzureEventGrid&version=3.0.0
                    
Install as a Cake Tool

Franz.Common.Messaging.AzureEventGrid

Host-agnostic Azure Event Grid ingress, event filtering, mapping, and Mediator dispatch.

Overview

This package registers the Event Grid ingress service and mapper. It parses Azure Event Grid events, handles subscription-validation event recognition, applies an optional event-type allow-list, maps accepted events into Franz messages, and publishes them through the Mediator dispatcher.

Installation

dotnet add package Franz.Common.Messaging.AzureEventGrid

Registration

using Franz.Common.Messaging.AzureEventGrid;

builder.Services.AddFranzAzureEventGrid();

The current registration method has no configuration callback. It registers a default AzureEventGridFilterOptions instance with an empty allow-list, which permits all event types. To replace it with an allow-list:

using Franz.Common.Messaging.AzureEventGrid.Configuration;
using Microsoft.Extensions.DependencyInjection.Extensions;

builder.Services.AddFranzAzureEventGrid();

var filters = new AzureEventGridFilterOptions();
filters.AllowedEventTypes.Add("Contoso.OrderCreated");
builder.Services.Replace(ServiceDescriptor.Singleton(filters));

Ingress contract

IAzureEventGridIngress.IngestAsync(EventGridEvent, cancellationToken) returns SubscriptionValidationResult?. For a subscription-validation event, the result contains the validation code. Filtered events return null; accepted business events are mapped and dispatched as notifications.

The batch overload processes each event in order. The package itself does not expose an HTTP endpoint; use the Azure hosting package to map the endpoint.

DI lifetime limitation

AddFranzAzureEventGrid registers IAzureEventGridIngress as a singleton, while its implementation captures IDispatcher, which Franz Mediator registers as scoped. With DI scope validation enabled, resolving the ingress fails; with validation disabled, it retains a root-scoped dispatcher. The ingress should be scoped or resolve a dispatcher from a per-request scope before being treated as production-safe.

Subscription-validation limitation

The current built-in HTTP endpoint in Franz.Common.Messaging.Hosting.Azure calls the ingress for each event but discards the returned SubscriptionValidationResult and responds with an empty 200 OK. Azure Event Grid requires a response body containing validationResponse for subscription validation. Therefore, the built-in endpoint does not complete the subscription-validation handshake. Use a custom endpoint that serializes the returned validation code until the host endpoint is corrected.

License

MIT. See the repository LICENSE.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Franz.Common.Messaging.AzureEventGrid:

Package Downloads
Franz.Common.Messaging.Hosting.Azure

Shared utility library for the Franz Framework.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.0.0 67 11/10/2026
2.3.4 349 11/1/2026
2.3.3 108 10/28/2026
2.3.2 114 10/27/2026
2.3.1 112 10/26/2026
2.3.0 180 7/21/2026
2.2.19 149 7/19/2026
2.2.18 135 7/19/2026
2.2.17 149 7/12/2026
2.2.16 145 7/2/2026
2.2.15 162 6/29/2026
2.2.14 136 6/29/2026
2.2.13 152 6/29/2026
2.2.12 142 6/28/2026
2.2.11 143 6/28/2026
2.2.10 144 6/28/2026
2.2.9 158 6/28/2026
2.2.8 140 6/28/2026
2.2.7 143 6/7/2026
2.2.6 147 6/6/2026
Loading failed