Deboa

A very simple and straightforward HTTP client written in Rust.

View the Project on GitHub ararog/deboa

Deboa

crates.io Build Status Documentation License: MIT

A straightforward, non-opinionated, developer-centric HTTP client library for Rust. Built on top of hyper.

Features

Quick Start

Add to your Cargo.toml:

[dependencies]
deboa = { version = "0.0.7", features = ["http1", "tokio-rt"] }

Basic usage:

use deboa::{Deboa, request::get};
use serde::Deserialize;

#[derive(Deserialize)]
struct Post {
    id: u64,
    title: String,
    body: String,
}

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let client = Deboa::new();
    
    let posts: Vec<Post> = get("https://jsonplaceholder.typicode.com/posts")
        .send_with(&client)
        .await?
        .body_as_json()?;
    
    println!("First post: {}", posts[0].title);
    Ok(())
}

Crates

Crate Description Documentation
deboa Core HTTP client library docs.rs
deboa-extras Additional functionality and middleware docs.rs
deboa-bora Macro for easy REST client generation docs.rs
deboa-macros Procedural macros for Deboa docs.rs
vamo DRY REST client wrapper docs.rs
vamo-macros Macros for Vamo docs.rs

Examples

Check out the examples directory for complete examples of how to use Deboa in your projects.

Documentation

License

This project is licensed under the MIT License.

Author

Rogerio Pereira Araujo rogerio.araujo@gmail.com