Smithy-http provides foundational HTTP components and primitives for Smithy tooling in Python. It defines standard interfaces for HTTP requests, responses, headers, and middleware, ensuring compliance with Smithy's protocol specifications. This library is primarily a building block for Smithy-generated Python clients and other Smithy-compliant services. The current version is 0.4.0, and releases are generally tied to the development cadence of the broader `smithy-python` project.
pip install smithy-httpVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to construct basic `HttpRequest` and `HttpResponse` objects using `smithy-http`'s core components. It highlights how to set the HTTP method, URL, headers, and body for both request and response entities. Note that `smithy-http` does not perform actual network calls; it provides the data structures for them.
Refer to the `smithy-python` project's changelog for specific migration steps when upgrading to newer 0.x.x versions.
Do not expect `smithy-http` to send or receive data over the network. It merely defines the structure for HTTP messages. You'll need to use a separate HTTP client library (e.g., `aiohttp`, `urllib3`) to handle the network I/O with `smithy-http` objects.
Always refer to the type hints in the library's source code or documentation. For request/response bodies, use `io.BytesIO` containing bytes, not strings directly.
No dependency data recorded yet.