Skip to main content

A modern Python HTTP client. Drop-in replacement for httpx.

Project description

httpdex

Drop-in replacement for httpx with HTTP/1.1, HTTP/2, and HTTP/3 support.

Highlights

  • httpx-compatible API
  • Async and sync clients
  • HTTP/2 via http2=True, HTTP/3 via http3=True
  • Request helpers: httpdex.get(), httpdex.post(), etc.
  • Cookie storage via CookieStore
  • ASGI-native testing with ASGITransport and MockTransport

Usage

import httpdex

# Simple request
response = httpdex.get("https://example.com")

# Client with connection reuse
with httpdex.Client() as client:
    response = client.get("https://example.com")

# HTTP/2
with httpdex.Client(http2=True) as client:
    response = client.get("https://example.com")

# Async
async with httpdex.AsyncClient() as client:
    response = await client.get("https://example.com")

# Streaming
with httpdex.Client() as client:
    with client.stream("GET", "https://example.com/large") as response:
        for chunk in response.iter_bytes():
            process(chunk)

Related Packages

  • httpdex-core - connection pool and transport layer
  • httpdex-parse - sans-I/O HTTP/1.1 parsing
  • httpdex-h2 - HTTP/2 framing and HPACK
  • httpdex-h3 - HTTP/3 over QUIC
  • httpdex-cookies - RFC 6265 cookie parsing and storage

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

httpdex-0.1.0.tar.gz (35.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

httpdex-0.1.0-py3-none-any.whl (44.4 kB view details)

Uploaded Python 3

File details

Details for the file httpdex-0.1.0.tar.gz.

File metadata

  • Download URL: httpdex-0.1.0.tar.gz
  • Upload date:
  • Size: 35.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for httpdex-0.1.0.tar.gz
Algorithm Hash digest
SHA256 340dca070585c31d8fa9d837c2af99b9512e0ec2dca66d580a72a4ebbefea192
MD5 6409178269b7cb5e8f76eb97c4fb6cdc
BLAKE2b-256 7096d21df22aa8734ea553492d28054da5367cef86df4730e9bd66f776d3eb71

See more details on using hashes here.

File details

Details for the file httpdex-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: httpdex-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 44.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for httpdex-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e557c8d3a47baef89f04d932d231af0027114c2a41623f8c4695643db6b753bd
MD5 68325dad361331e5215242317de9b587
BLAKE2b-256 f9b0f248d290d835d550e538f0d4d19c365e0aeebdd400c1a3382525a6f8e567

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page