Expand description
Helpers for building Spin wasi-http
components.
Modules§
- Traits for converting between the various types
- Helper functions for creating responses
Macros§
- A macro to help with constructing a Router from a stream of tokens.
Structs§
- A Body extractor
- This following block defines the
fields
resource which corresponds to HTTP standard Fields. Fields are a common representation used for both Headers and Trailers. - A header value.
- Represents an incoming HTTP Request.
- Represents an incoming HTTP Response.
- A Json extractor
- An error parsing a JSON body
- An error when the body is not UTF-8
- Represents an outgoing HTTP Request or Response’s Body.
- Represents an outgoing HTTP Request.
- Represents an outgoing HTTP Response.
- A unified request object that can represent both incoming and outgoing requests.
- A request builder
- A unified response object that can represent both outgoing and incoming responses.
- A builder for `Response``
- The out param for setting an
OutgoingResponse
- Exports HTTP Router items. The Spin SDK HTTP router.
Enums§
- These cases are inspired by the IANA HTTP Proxy Error Types: https://www.iana.org/assignments/http-proxy-status/http-proxy-status.xhtml#table-http-proxy-error-types
- This type corresponds to HTTP standard Methods.
- This type corresponds to HTTP standard Related Schemes.
- An error encountered when performing an HTTP request
Traits§
- Exports HTTP Router items. An HTTP request handler.
- A trait for any type that can be turned into a
Response
Functions§
- Send an outgoing request
Type Aliases§
- Headers is an alias for Fields.
- Exports HTTP Router items. Route parameters extracted from a URI that match a route pattern.
- This type corresponds to the HTTP standard Status Code.
- Trailers is an alias for Fields.