Skip to content

Latest commit

 

History

History
68 lines (55 loc) · 2.08 KB

File metadata and controls

68 lines (55 loc) · 2.08 KB

cyper

MIT licensed crates.io docs.rs Check Test

An HTTP library based on compio and hyper.

This project references code from reqwest.

Quick start

Add compio and cyper as dependency:

cargo add cyper
cargo add compio --features macros

Then we can start a simple HTTP request:

use cyper::Client;

#[compio::main]
async fn main() {
    let client = Client::new();
    let response = client
        .get("https://compio.rs/")
        .unwrap()
        .send()
        .await
        .unwrap();
    println!("{}", response.text().await.unwrap());
}

Features

  • HTTPS - powered by compio-tls
    • native-tls
    • rustls
  • HTTP 2
  • HTTP 3 - powered by compio-quic
    • Alt-Svc
  • cookies
  • charset
  • serde-json
  • multipart
  • proxy
    • HTTP proxy tunnel
    • Socks 4/5
  • redirect
  • decompression
  • hickory DNS

Nyquest support

cyper supports nyquest experimentally. Start with registering:

cyper::nyquest::register();

Contributing

There are opportunities to contribute to Cyper at any level. It doesn't matter if you are just getting started with Rust or are the most weathered expert, we can use your help. If you have any question about Cyper, feel free to join our telegram group. Before contributing, please checkout our contributing guide.