Expand description
§vld-web — HTTP integrations for the vld validation library
Extractors, filters and error responses that validate request data with
vld schemas, one module per web framework. Every module is behind its
feature; none is on by default:
vld-web = { version = "0.8", features = ["axum"] }| Module | Feature | Framework |
|---|---|---|
common | — | framework-agnostic parsing helpers and the shared error type, for custom adapters |
axum | axum | axum 0.8 extractors |
actix | actix | actix-web 4 extractors |
ntex3 / ntex4 | ntex-3 / ntex-4 (+ ntex-compress) | ntex 3 / ntex 4 extractors |
poem | poem | poem 3 extractors |
rocket | rocket | Rocket 0.5 data guards, request guards and catchers |
salvo | salvo | salvo 1 extractors |
warp | warp | warp 0.3 – 0.4 filters |
rama | rama | rama 0.4 extractors and a validation layer |
tower | tower | a Tower layer validating JSON bodies (any Tower-based framework) |
tonic | tonic | tonic 0.12 – 0.14 message and metadata validation |
Every HTTP module answers with the same error bodies (422 / 413 / 415,
see common#error-bodies) and parses query
strings, forms, paths, headers and cookies by the same rules.
ⓘ
use vld_web::axum::{VldJson, VldQuery};Some features need a newer compiler than the crate’s rust-version
(see MSRV.md); cargo reports the framework’s rust-version then.
Modules§
- actix
vld_web::actix— Actix-web integration for thevldvalidation library- axum
vld_web::axum— Axum integration for thevldvalidation library- common
- Shared HTTP helpers for the
vldweb integrations. - ntex3
vld_web::ntex3— ntex 3 integration forvld- ntex4
vld_web::ntex4— ntex 4 integration forvld- poem
vld_web::poem— Poem integration forvld- rama
vld_web::rama— Rama integration forvld- rocket
vld_web::rocket— Rocket integration forvld- salvo
vld_web::salvo— Salvo integration forvld- tonic
vld_web::tonic— tonic gRPC integration forvld- tower
vld_web::tower— Tower middleware forvld- warp
vld_web::warp— Warp integration forvld