cijiugechu / dmzj

An async dmzj client for Rust. 动漫之家 api

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dmzj

Cargo Documentation

An async dmzj client for Rust.

Mostly taken from tachiyomi extensions & flutter_dmzj.

Example

use dmzj::Api;

#[tokio::main]
async fn main() {
    let api = Api::new();

    let popular_manga = api.fetch_latest_updates_manga(0).await.unwrap();
    let first = &popular_manga[0];
    let first_id = first.id;

    println!("manga id = {:?}", first_id);

    let response = api.fetch_manga_details(first_id).await.unwrap();

    let description = &response.data.description;
    let title = &response.data.title;
    let cover = &response.data.cover;
    let authors = &response.data.authors;

    println!("title = {}", title);
    println!("description = {}", description);
    println!("cover = {}", cover);
    println!("authors = {:?}", authors);
}

For more examples, please check out examples.

About

An async dmzj client for Rust. 动漫之家 api

License:Apache License 2.0


Languages

Language:Rust 99.9%Language:Just 0.1%