TimeWarp.Mediator
15.0.0-beta.2
Prefix Reserved
See the version list below for details.
dotnet add package TimeWarp.Mediator --version 15.0.0-beta.2
NuGet\Install-Package TimeWarp.Mediator -Version 15.0.0-beta.2
<PackageReference Include="TimeWarp.Mediator" Version="15.0.0-beta.2" />
<PackageVersion Include="TimeWarp.Mediator" Version="15.0.0-beta.2" />
<PackageReference Include="TimeWarp.Mediator" />
paket add TimeWarp.Mediator --version 15.0.0-beta.2
#r "nuget: TimeWarp.Mediator, 15.0.0-beta.2"
#:package TimeWarp.Mediator@15.0.0-beta.2
#addin nuget:?package=TimeWarp.Mediator&version=15.0.0-beta.2&prerelease
#tool nuget:?package=TimeWarp.Mediator&version=15.0.0-beta.2&prerelease
TimeWarp.Mediator
Message contracts and the TWM001–TWM004 analyzer for TimeWarp Mediator 15.0: requests, commands, queries, notifications, and pipeline types.
Install
dotnet add package TimeWarp.Mediator --version 15.0.0-beta.2
Without --version, that command resolves 14.0.0. Through 14.0.0 this package id was the reflection runtime (AddMediator). The 14.0.0 contracts were TimeWarp.Mediator.Contracts, and the analyzers were TimeWarp.Mediator.Analyzers. 15.0 reuses this id for the contracts and the analyzer. A host also references TimeWarp.Mediator.Generators at the same version. This package ships the TWM001–TWM004 analyzer. There is no separate analyzers package.
Example
using Microsoft.Extensions.DependencyInjection;
using TimeWarp.Mediator;
using TimeWarp.Mediator.Generated;
ServiceCollection services = new();
services.AddGeneratedMediator();
using ServiceProvider provider = services.BuildServiceProvider();
using IServiceScope scope = provider.CreateScope();
string reply = await scope.ServiceProvider.GetRequiredService<ISender>().Send(new Ping());
public sealed class Ping : IRequest<string> { }
public sealed class PingHandler : IRequestHandler<Ping, string>
{
public ValueTask<string> Handle(Ping request, CancellationToken cancellationToken) =>
ValueTask.FromResult("Pong");
}
AddGeneratedMediator() is emitted into the host project by TimeWarp.Mediator.Generators, in the generated namespace (TimeWarp.Mediator.Generated unless the host sets TimeWarpMediatorNamespace). Call it from the host. Reference only this package from a project that declares messages and does not dispatch them. That project still gets TWM001–TWM004, and it opts in with [assembly: MediatorAssembly].
Migration
15.0 is a breaking release. Handlers return ValueTask. The host calls AddGeneratedMediator() and supplies IServiceProvider. Registered pipeline behaviors are woven.
- This package targets net10.0 and net11.0.
- Through 14.0.0 the id
TimeWarp.Mediatorwas the reflection runtime (AddMediator). 15.0 reuses that id for the contracts and the analyzer. The 14.0.0 contracts idTimeWarp.Mediator.Contractsis gone, and so isAddMediator. - From MediatR: change
using MediatR;tousing TimeWarp.Mediator;.
Steps: Migration to 15.0.
Documentation
License
Licensed as Unlicense AND Apache-2.0. The Apache-2.0 terms cover code derived from MediatR by Jimmy Bogard. The notice and unlicense files ship in this package.
| Product | Versions 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. net11.0 is compatible. |
-
net10.0
- No dependencies.
-
net11.0
- No dependencies.
NuGet packages (6)
Showing the top 5 NuGet packages that depend on TimeWarp.Mediator:
| Package | Downloads |
|---|---|
|
TimeWarp.State
State management for .NET. Blazor components, JavaScript interop, and render subscriptions are in TimeWarp.State.Blazor. |
|
|
TimeWarp.Nuru
Route-based CLI framework for .NET - batteries included with telemetry, REPL, and shell completion |
|
|
TimeWarp.Contracts
Transport-neutral operation contracts for HTTP, CLI, and MCP. One request type carries the canonical name; member metadata and kind are derived by each host's generator. |
|
|
TimeWarp.Foundation.Contracts
Shared contracts, request/response markers, route/auth/query source generator, and common types for the TimeWarp foundation layer. |
|
|
TimeWarp.Foundation.Server
ASP.NET server building blocks (modules, base endpoints, CORS) for the TimeWarp foundation layer. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 15.0.0-beta.10 | 117 | 11/17/2026 |
| 15.0.0-beta.9 | 359 | 11/15/2026 |
| 15.0.0-beta.8 | 218 | 11/14/2026 |
| 15.0.0-beta.6 | 397 | 11/9/2026 |
| 15.0.0-beta.5 | 190 | 11/5/2026 |
| 15.0.0-beta.4 | 964 | 10/31/2026 |
| 15.0.0-beta.2 | 237 | 10/28/2026 |
| 15.0.0-beta.1 | 60 | 10/26/2026 |
| 14.0.0 | 1,428 | 10/13/2026 |
| 14.0.0-beta.5 | 59 | 10/13/2026 |
| 14.0.0-beta.4 | 78 | 9/27/2026 |
| 14.0.0-beta.3 | 75 | 9/25/2026 |
| 14.0.0-beta.2 | 71 | 9/25/2026 |
| 14.0.0-beta.1 | 100 | 9/2/2026 |
| 13.0.0 | 16,882 | 8/4/2025 |
| 13.0.0-beta.4 | 231 | 7/30/2025 |
| 13.0.0-beta.3 | 239 | 7/28/2025 |
| 13.0.0-beta.2 | 166 | 7/5/2025 |
| 13.0.0-beta.1 | 159 | 7/5/2025 |