10 releases (breaking)

0.8.0 Dec 9, 2023
0.7.0 Oct 18, 2023
0.6.0 Apr 30, 2023
0.5.0 Jan 15, 2023
0.1.0 Sep 6, 2022

#1837 in Web programming

Download history 1415/week @ 2024-07-19 1126/week @ 2024-07-26 1351/week @ 2024-08-02 572/week @ 2024-08-09 690/week @ 2024-08-16 969/week @ 2024-08-23 1110/week @ 2024-08-30 933/week @ 2024-09-06 963/week @ 2024-09-13 1047/week @ 2024-09-20 1268/week @ 2024-09-27 1156/week @ 2024-10-04 1230/week @ 2024-10-11 1108/week @ 2024-10-18 1113/week @ 2024-10-25 1427/week @ 2024-11-01

5,023 downloads per month
Used in 8 crates (4 directly)

MIT/Apache

1MB
2K SLoC

Rust 1.5K SLoC // 0.0% comments JavaScript 424 SLoC // 0.0% comments

axum-jsonschema

A drop-in replacement for Json extractor and response that validates requests based on JSON schemas.


lib.rs:

A simple crate provides a drop-in replacement for axum::Json that uses jsonschema to validate requests schemas generated via schemars.

You might want to do this in order to provide a better experience for your clients and not leak serde's error messages.

All schemas are cached in a thread-local storage for the life of the application (or thread).

Features

  • aide: support for aide

Dependencies

~14–22MB
~321K SLoC