63 releases (15 stable)
3.5.1 | Aug 10, 2024 |
---|---|
3.5.0 | May 19, 2024 |
3.4.0 | Feb 4, 2024 |
3.3.0 | Dec 24, 2023 |
0.1.0-alpha.2 | Mar 30, 2019 |
#73 in HTTP client
143,619 downloads per month
Used in 392 crates
(91 directly)
1MB
20K
SLoC
awc
(Actix Web Client)
Async HTTP and WebSocket client library.
Examples
Example project using TLS-enabled client →
Basic usage:
use actix_rt::System;
use awc::Client;
fn main() {
System::new().block_on(async {
let client = Client::default();
let res = client
.get("http://www.rust-lang.org") // <- Create request builder
.insert_header(("User-Agent", "Actix-web"))
.send() // <- Send http request
.await;
println!("Response: {:?}", res); // <- server http response
});
}
Dependencies
~12–28MB
~544K SLoC