A batteries-included HTTP client for Elixir
open sourceApache-2.0free
Req is a batteries-included HTTP client for Elixir. A couple of lines get automatic response decoding, redirects, retries on errors, compression and decompression (gzip, brotli, zstd), JSON and form encoding, Basic, Digest, Bearer and .netrc authentication, AWS SigV4 signing, range requests and streaming. Its features are built as reusable steps you can rearrange or extend, it ships Plug-based test stubs, and it runs on Finch by default through pluggable adapters. Apache 2.0 licensed.
Problems it solves
- make HTTP requests from Elixir without wiring retries and JSON decoding myself
- stub HTTP calls in my Elixir tests
- an Elixir HTTP client that streams large responses
Features
- Automatic response body decoding
- Follows redirects and retries on errors
- Request compression and response decompression (gzip, brotli, zstd)
- JSON and form encoding
- Basic, Digest, Bearer and .netrc auth
- AWS SigV4 signing
- Request and response streaming
- Extensible through steps
- Plug-based test stubs
Alternatives
The same job
These do what Req does.
- HTTPoison Yet another HTTP client for Elixir, powered by hackney
- Tesla The flexible HTTP client library for Elixir, with middleware and multiple adapters
- Mint Functional, low-level HTTP/1 and HTTP/2 client for Elixir
- hackney An HTTP client for Erlang. Simple, reliable, fast.
- Finch Performance-focused HTTP client for Elixir
- ibrowse HTTP client for Erlang with connection pools and streaming
