Trellis.FluentValidation 3.0.0-alpha.385

This is a prerelease version of Trellis.FluentValidation.
dotnet add package Trellis.FluentValidation --version 3.0.0-alpha.385
                    
NuGet\Install-Package Trellis.FluentValidation -Version 3.0.0-alpha.385
                    
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="Trellis.FluentValidation" Version="3.0.0-alpha.385" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Trellis.FluentValidation" Version="3.0.0-alpha.385" />
                    
Directory.Packages.props
<PackageReference Include="Trellis.FluentValidation" />
                    
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 Trellis.FluentValidation --version 3.0.0-alpha.385
                    
#r "nuget: Trellis.FluentValidation, 3.0.0-alpha.385"
                    
#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 Trellis.FluentValidation@3.0.0-alpha.385
                    
#: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=Trellis.FluentValidation&version=3.0.0-alpha.385&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Trellis.FluentValidation&version=3.0.0-alpha.385&prerelease
                    
Install as a Cake Tool

Trellis.FluentValidation

NuGet Package

A small bridge that turns FluentValidation output into Trellis results.

Installation

dotnet add package Trellis.FluentValidation

Quick Example

using FluentValidation;
using Trellis.FluentValidation;

public sealed record CreateUserRequest(string Email);

var validator = new InlineValidator<CreateUserRequest>();
validator.RuleFor(x => x.Email).NotEmpty().EmailAddress();

var result = validator.ValidateToResult(new CreateUserRequest("ada@example.com"));

Mediator Integration

The Mediator wire-up moved to the dedicated Trellis.Mediator.FluentValidation package in v3 so consumers that only need the standalone helpers don't take a Mediator dependency. Install that package to plug FluentValidation into the Trellis.Mediator validation stage:

dotnet add package Trellis.Mediator.FluentValidation
using Trellis.Mediator;
using Trellis.Mediator.FluentValidation;

builder.Services.AddMediator(opts => opts.ServiceLifetime = ServiceLifetime.Scoped);
builder.Services.AddTrellisBehaviors();
builder.Services.AddTrellisFluentValidation();
builder.Services.AddScoped<IValidator<MyCommand>, MyCommandValidator>();

The adapter normalizes FluentValidation property names (Metadata.Reference, Lines[0].Memo) into RFC 6901 JSON Pointers (/metadata/reference, /lines/0/memo) using JsonPointerNormalizer, which is now part of the public surface of Trellis.FluentValidation.

Key Features

  • Convert ValidationResult into Result<T> with Trellis validation errors.
  • Validate inline or through reusable validator classes.
  • JsonPointerNormalizer.ToJsonPointer(...) projects FluentValidation property names into RFC 6901 JSON Pointers — public so third-party adapters can reuse the normalization rules.
  • Plug into the Trellis.Mediator pipeline via the companion Trellis.Mediator.FluentValidation package.
  • Keep third-party validation libraries inside the same Result pipeline as the rest of your app.

Documentation

Part of Trellis

This package is part of the Trellis framework.

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 Trellis.FluentValidation:

Package Downloads
Trellis.Mediator.FluentValidation

Mediator pipeline adapter that plugs FluentValidation validators into the Trellis Mediator validation stage. Open-generic IMessageValidator<TMessage> that resolves every IValidator<TMessage> registered in DI and aggregates failures into a single Error.InvalidInput response.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.0.0-alpha.385 54 6/15/2026
3.0.0-alpha.382 59 6/12/2026
3.0.0-alpha.372 53 6/10/2026
3.0.0-alpha.360 77 6/7/2026
3.0.0-alpha.342 95 6/5/2026
3.0.0-alpha.337 64 6/3/2026
3.0.0-alpha.336 55 6/3/2026
3.0.0-alpha.304 71 5/29/2026
3.0.0-alpha.158 81 4/5/2026
3.0.0-alpha.157 69 4/4/2026
3.0.0-alpha.140 67 3/30/2026
3.0.0-alpha.137 67 3/27/2026
3.0.0-alpha.135 59 3/26/2026
3.0.0-alpha.127 59 3/23/2026
3.0.0-alpha.123 64 3/19/2026
3.0.0-alpha.118 73 3/14/2026
3.0.0-alpha.111 70 3/12/2026
3.0.0-alpha.104 58 3/9/2026
3.0.0-alpha.100 55 3/4/2026
3.0.0-alpha.99 61 3/4/2026
Loading failed