Skip to content

azurlane-api/azurlane-rs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

v1.0.0

azurlane-rs

Wrapper for the unofficial azur lane json api in Rust

Installation

[dependencies]
azurlane = "1.1"

Example

use azurlane::{AzurLaneRequester, Category};
use reqwest::Client;

fn main() {
    let client = Client::new();
    
    let _ = match client.get_ships(Category::RARITY, "Super Rare") {
        Ok(response) => {
            for i in 0..response.ships.len() {
                println!("[{}]: ({})", response.ships[i].id, response.ships[i].name)
            }
        }
        Err(why) => {
            panic!("{}", why)
        }
    };
}

Support

discord