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 |
#70 in HTTP client
145,151 downloads per month
Used in 393 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
~13–29MB
~551K SLoC