Crate axum_extra

Crate axum_extra 

Source
Expand description

Extra utilities for axum.

§Feature flags

axum-extra uses a set of [feature flags] to reduce the amount of compiled and optional dependencies.

The following optional features are available:

NameDescriptionDefault?
async-read-bodyEnables the AsyncReadBody body
attachmentEnables the Attachment response
cachedEnables the Cached extractor
cookieEnables the CookieJar extractor
cookie-privateEnables the PrivateCookieJar extractor
cookie-signedEnables the SignedCookieJar extractor
cookie-key-expansionEnables the Key::derive_from method
erased-jsonEnables the ErasedJson response
error-responseEnables the InternalServerError response
formEnables the Form extractor
handlerEnables the handler utilities
json-deserializerEnables the JsonDeserializer extractor
json-linesEnables the JsonLines extractor and response
middlewareEnables the middleware utilities
multipartEnables the Multipart extractor
optional-pathEnables the OptionalPath extractor
protobufEnables the Protobuf extractor and response
queryEnables the Query extractor
routingEnables the routing utilities
tracingLog rejections from built-in extractors
typed-routingEnables the TypedPath routing utilities and the routing feature.
typed-headerEnables the TypedHeader extractor and response
file-streamEnables the FileStream response
with-rejectionEnables the WithRejection extractor

Re-exports§

pub use headers;typed-header

Modules§

body
Additional bodies.
either
Either* types for combining extractors or responses into a single type.
extract
Additional extractors.
handlerhandler
Additional handler utilities.
json_linesjson-lines
Newline delimited JSON extractor and response.
middlewaremiddleware
Additional middleware utilities.
protobufprotobuf
Protocol Buffer extractor and response.
response
Additional types for generating responses.
routingrouting
Additional types for defining routes.
typed_headertyped-header
Extractor and response for typed headers.

Macros§

json
Construct an ErasedJson response from a JSON literal.
vpath
This macro aborts compilation if the path is invalid.

Structs§

TypedHeadertyped-header
Extractor and response that works with typed header values from headers.