hpx 2.4.9

High Performance HTTP Client
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use hpx::Proxy;

#[tokio::main]
async fn main() -> hpx::Result<()> {
    // Use the API you're already familiar with
    let resp = hpx::get("https://api.ip.sb/ip")
        .proxy(Proxy::all("socks5h://localhost:6153")?)
        .send()
        .await?;
    println!("{}", resp.text().await?);

    Ok(())
}