Crates.io | menemen |
lib.rs | menemen |
version | 1.0.3 |
source | src |
created_at | 2022-01-08 00:52:13.017355 |
updated_at | 2023-04-23 21:43:15.259959 |
description | A streaming http request library |
homepage | |
repository | https://github.com/behemehal/Menemen |
max_upload_size | |
id | 510014 |
size | 78,078 |
Menemen is a Turkish food and also simple streaming http/https client.
use std::io::{Write, Read};
use menemen::request::{Request, RequestTypes};
fn main() {
let mut request = Request::new("http://postman-echo.com/get", RequestTypes::GET).unwrap();
let mut response = request.send().unwrap();
let mut text_buffer = Vec::new();
response.stream.read_to_end(&mut text_buffer);
println!("Text: {}", String::from_utf8_lossy(&text_buffer));
}
You can find examples here