mirror of
https://github.com/fafhrd91/actix-web
synced 2025-02-20 03:14:21 +01:00
* build(deps): update derive_more requirement from 1 to 2 Updates the requirements on [derive_more](https://github.com/JelteF/derive_more) to permit the latest version. - [Release notes](https://github.com/JelteF/derive_more/releases) - [Changelog](https://github.com/JelteF/derive_more/blob/master/CHANGELOG.md) - [Commits](https://github.com/JelteF/derive_more/compare/v1.0.0...v2.0.1) --- updated-dependencies: - dependency-name: derive_more dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> * refactor: simplify derive_more calls --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Rob Ede <robjtede@icloud.com>
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
});
}