Last Update: 2023-12-05 13:42:13 +0000



Sentry integration

Documentation: gitlab.com/os85/httpx/-/wikis/Sentry-Adapter

httpx ships with integration for sentry-ruby to provide HTTP request specific breadcrumbs and tracing. It can be enabled via:

require "httpx/adapters/sentry"

Proxy alternative auth schemes

Besides the already previously supported (and still default) HTTP Basic Auth, the :proxy plugin supports HTTP Digest and NTLM auth as well. These are made available via the following APIs:

http = HTTPX.plugin(:proxy)
http.with_proxy_basic_auth(username: "user", password: "pass", uri: "http://proxy-uri:8126")
http.with_proxy_digest_auth(username: "user", password: "pass", uri: "http://proxy-uri:8126")
http.with_proxy_ntlm_auth(username: "user", password: "pass", uri: "http://proxy-uri:8126")

# or alternatively
http.with_proxy(proxy: "basic", username: "user", password: "pass", uri: "http://proxy-uri:8126")


  • HTTPS requests on an URL with an IP as a host, will now correctly not perform SNI during the TLS handshake, as per RFC;

  • :follow_redirects plugin will now halt redirections on 3xx responses with no "location" headers; this means it won’t crash on 304 responses.

    • If the httpx session has the :proxy plugin enabled, HTTP 305 responses will retry the request via the proxy exposed in the "location" header, as the RFC mandates.

  • alt-svc connection switch for HTTPS requests will be halted if the advertised alternative service “downgrades” to cleartext (example: alt-svc advertises "h2c", but original connection was enabled via TLS).

  • A new connection to a TLS-enabled alt-svc advertised for a previous request, will now use that request’s hostname as the SNI hostname, when performing the TLS handshake.

  • the :response_cache plugin will now correctly handle capitalized HTTP headers advertised in the "vary" header.