FlowMediator 1.0.0
dotnet add package FlowMediator --version 1.0.0
NuGet\Install-Package FlowMediator -Version 1.0.0
<PackageReference Include="FlowMediator" Version="1.0.0" />
<PackageVersion Include="FlowMediator" Version="1.0.0" />
<PackageReference Include="FlowMediator" />
paket add FlowMediator --version 1.0.0
#r "nuget: FlowMediator, 1.0.0"
#:package FlowMediator@1.0.0
#addin nuget:?package=FlowMediator&version=1.0.0
#tool nuget:?package=FlowMediator&version=1.0.0
FlowMediator
A lightweight mediator library with pipeline behaviors for .NET 8/9.
Ideal for hobby projects, personal apps, or learning CQRS patterns without the complexity of bigger frameworks.
Provides request/response messaging and pipeline behaviors like logging and validation with minimal setup.
Features
✅ Request/Response messaging (IRequest<TResponse>, IRequestHandler<TRequest,TResponse>)
✅ Pipeline behaviors (IPipelineBehavior<TRequest,TResponse>) for cross-cutting concerns (logging, validation, etc.)
✅ Dependency Injection (DI) ready via IServiceCollection extensions
✅ Manual or automatic pipeline registration
✅ .NET 8 and .NET 9 support
Installation
dotnet add package FlowMediator --version 1.0.0
Example Usage
using FlowMediator.Contracts;
using FlowMediator.Extensions;
// Manual pipeline (you choose order of behaviors)
services.AddFlowMediator(typeof(GetUserByIdQuery).Assembly);
services.AddTransient(typeof(IPipelineBehavior<,>), typeof(LoggingBehavior<,>));
services.AddTransient(typeof(IPipelineBehavior<,>), typeof(ValidationBehavior<,>));
// Or automatic pipeline (handlers + behaviors auto registered)
services.AddFlowMediatorWithBehaviors(typeof(GetUserByIdQuery).Assembly);
Use Mediator
var mediator = provider.GetRequiredService<IMediator>();
var user = await mediator.Send(new GetUserByIdQuery(1));
Console.WriteLine(user.Name); // "User 1"
🤝 Contributing
Contributions are welcome! Please fork the repo and create a PR.
📜 License
Licensed under the MIT License. See LICENSE for details.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
-
net8.0
- Microsoft.Extensions.DependencyInjection (>= 9.0.8)
-
net9.0
- Microsoft.Extensions.DependencyInjection (>= 9.0.8)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last Updated |
---|---|---|
1.0.0 | 173 | 8/26/2025 |
Initial 1.0.0 release: core mediator, pipeline behaviors, DI integration.