spiget

Crates.iospiget
lib.rsspiget
version0.1.0
sourcesrc
created_at2023-07-19 21:28:14.633438
updated_at2023-07-19 21:28:14.633438
descriptionSpiget client, generated from the OpenAPI spec.
homepagehttps://github.com/domirusz24/spiget-rs
repositoryhttps://github.com/domirusz24/spiget-rs
max_upload_size
id920745
size135,229
(DomiRusz24)

documentation

https://docs.rs/spiget

README

Stars Build Status Downloads Crates.io

Spiget client, generated from the OpenAPI spec.

Usage

use spiget::SpigetClient;
use spiget::model::*;
#[tokio::main]
async fn main() {
    let client = SpigetClient::from_env();
    let response = client
        .get_authors()
        .fields("your fields")
        .page(1.0)
        .size(1.0)
        .sort("your sort")
        .await
        .unwrap();
    println!("{:#?}", response);
}

This example loads configuration from environment variables, specifically:

  • SPIGET_BASE_URL

Installation

Add this to your Cargo.toml:

[dependencies]
spiget = "0.1.0"

Documentation

You can see working examples of every API call in the examples/ directory.

Contributing

Contributions are welcome!

Library created with Libninja.

Commit count: 2

cargo fmt