Expand description
Vespera - OpenAPI generation for Rust web frameworks
This crate provides macros and utilities for generating OpenAPI documentation
from your route definitions.
Re-exports§
pub use serve::Serve;pub use serde_json;pub use chrono;pub use tempfile;pub use tower_layer;pub use tower_service;
Modules§
- axum
- axum_
extra - multipart
- Native multipart form data extraction for Vespera.
- openapi
- route
- schema
- serve
- One-liner
Router::serve(addr)extension — seeserve::Serve.Serve— extension trait that lets you start anaxum::Routerwith a one-liner.
Macros§
- export_
app - Export a vespera app as a reusable component.
- schema
- Generate an
OpenAPISchema from a type with optional field filtering. - schema_
type - Generate a new struct type derived from an existing type with field filtering.
- vespera
Structs§
- OpenApi
OpenAPIdocument (root structure)- Validated
- Extractor wrapper that validates the inner extractor’s output via
garde::Validatebefore handing it to the handler. - Vespera
Router - A router wrapper that defers merging until
with_state()is called.
Traits§
- Validate
Payload - Helper trait that pulls the validatable payload out of common axum
extractors so
Validated<Json<U>>can callU::validate(&u, &()).