HTTP client utilities for requests with TLS/mTLS and redirect following. Supports Server-Sent Events streaming, URL encoding, HTML entity escaping, and multipart/URL-encoded form body building and parsing. Delegates to http.request and http.sse for HTTP requests and SSE streaming (requires lev.run() context).
| Module | Description |
|---|---|
| http.forms | Form body building and parsing utilities: URL encoding, HTML escaping, application/x-www-form-urlencoded and multipart/form-data handling. |
| http.request | Async HTTP/1.1 client using the lev event loop. |
| http.server | Coroutine-per-connection HTTP/1.1 server using LEV async I/O, with keep-alive, chunked transfer encoding, response compression (gzip/deflate), and optional TLS with SNI support. |
| http.sse | Server-Sent Events (SSE) streaming client using the LEV event loop. |
| http.url | URL parsing, building, relative resolution, and percent-encoding per RFC 3986. |