isahc 0.9.1

The practical HTTP client that is fun to use.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use isahc::config::VersionNegotiation;
use isahc::prelude::*;

fn main() -> Result<(), isahc::Error> {
    let response = Request::get("https://nghttp2.org")
        .version_negotiation(VersionNegotiation::http2())
        .body(())
        .map_err(Into::into)
        .and_then(isahc::send)?;

    println!("{:?}", response.headers());

    Ok(())
}