Expand description
Transport-neutral HTTP service-provider interface.
Framework, authentication, rate-limit, schema, documentation, and telemetry packages share these endpoint declarations and request/response effects. Concrete handlers, body extractors, routers, servers, and runtimes stay in adapter crates.
Structs§
- Auth
Challenge - Structured
WWW-Authenticatechallenge. - Authorization
Name - Stable authentication strategy, authorization policy, role, or permission name.
- Body
Limit Policy - Maximum accepted request body size.
- Contract
Id - Logical request or response contract identity resolved by validation and schema adapters.
- Cors
Policy - Declarative cross-origin resource-sharing policy.
- Default
Http Error Mapper - Default stable error mapper used by framework adapters unless overridden.
- Endpoint
Catalog - Ordered endpoint catalog with duplicate identity and route-shape detection.
- Endpoint
Contracts - Request and response contracts attached to one endpoint.
- Endpoint
Group - Endpoint group that applies a route prefix and shared safe defaults.
- Endpoint
Id - Stable endpoint identity used by adapters, documentation, and telemetry.
- Endpoint
Metadata - Portable endpoint definition consumed by framework, auth, docs, and telemetry adapters.
- Header
Map - A specialized multimap for header names and values.
- Header
Name - Represents an HTTP header field name
- Header
Value - Represents an HTTP header field value.
- Hsts
Policy - HTTP Strict Transport Security declaration.
- Http
Error Body - Serializer-neutral safe error response body.
- Http
Error Response - Complete serializer-neutral HTTP error response.
- Http
Request Parts - Owned neutral request parts useful for adapter composition and tests.
- Http
Response Effects - Headers, cookies, status, and redirects emitted by a transport-neutral module.
- Media
Type - Validated media type without a dependency on a serializer or schema format.
- Method
- The Request Method (VERB)
- Operation
Documentation - Human-facing operation documentation independent from OpenAPI structures.
- Rate
Limit Policy - Declarative rate limit translated by an HTTP or rate-limiter adapter.
- Redirect
- Validated redirect response effect.
- Request
Contract - Logical validation/schema contract attached to part of a request.
- Response
Cache Policy - Declarative HTTP response caching policy, distinct from application data caching.
- Response
Contract - Logical response schema contract attached to a status code.
- Response
Cookie - Transport-neutral cookie mutation returned by HTTP modules.
- Route
Path - A validated route path using
{parameter}placeholders. - Security
Headers Policy - Security response-header policy translated by framework adapters.
- Status
Code - An HTTP status code (
status-codein RFC 9110 et al.). - Telemetry
Policy - Endpoint-level telemetry instructions consumed by tracing and metrics adapters.
- Uri
- The URI component of a request.
Enums§
- Allowed
Origins - Allowed CORS origins.
- Authorization
Policy - Declarative authentication and authorization requirement.
- Cache
Visibility - HTTP response cache visibility.
- Csrf
Policy - Whether cross-site request-forgery protection is required.
- Frame
Options - Browser frame embedding policy.
- Rate
Limit Scope - Identity dimension used to derive a rate-limit key.
- Referrer
Policy - Referrer information sent by compatible clients.
- Request
Contract Location - Location from which an HTTP adapter validates or documents request data.
- Same
Site - Browser SameSite cookie behavior.
Traits§
- Http
Error Mapper - Maps application errors into safe HTTP responses.
- Http
Request View - Read-only request view implemented by framework adapters or
HttpRequestParts.
Functions§
- default_
error_ code - Stable machine-readable code for a soaprs error category.
- default_
error_ response - Builds the default safe error response.
- default_
error_ status - Returns the default HTTP status for a stable soaprs error category.