Expand description
axum extractors for JSON:API requests.
Each extractor is a thin binding: it reads the relevant part of the request
and delegates to jsonapi_http, turning failures into a JsonApiError
rejection.
Structs§
- BaseUrl
- The application’s base URL for building
self/relatedlinks and theLocationheader, provided from application state viaFromRef. - JsonApi
- Typed JSON:API request-body extractor. Validates the
Content-Type, buffers the body, and deserializes aDocument<T>, rejecting with a JSON:API error document (415 / 400 / 409 / 422) on failure. - Json
ApiQuery - JSON:API query-parameter extractor (
sort/page/filter/fields/include). Does not validate include paths — useJsonApiQueryValidatedfor that. Requires no application state. - Json
ApiQuery Validated - JSON:API query extractor that additionally validates
includepaths against anArc<TypeRegistry>pulled from application state, rooted atT’s resource type. Opt-in: apps without a registry useJsonApiQueryinstead. - Negotiated
Media Type - The response media type negotiated by
AcceptLayer, read back out of the request extensions where the layer stored it.