mal-rs
The purpose of this library is to provide high-level access to the MyAnimeList API. It currently allows you to search for anime and manga, as well as add, update, and remove anime / manga from a user's list.
Please note that while most data fields are parsed from the API, there are some that are purposely ignored because they are only available when making certain types of requests.
Usage
By default, the library builds with support to access a user's anime and manga list.
If you plan on performing operations on both, you can simply add mal
as a dependency to your Cargo.toml
file:
[]
= "0.3"
If you only need to access one type of list (or none at all), you should use the following feature gates to reduce the final binary size and compilation time:
If you only need access to the user's anime list, use the anime-list
feature:
[]
= "0.3"
= false
= ["anime-list"]
If you only need access to a user's manga list, use the manga-list
feature:
[]
= "0.3"
= false
= ["manga-list"]
Or, if you don't need to access either, just disable the default features:
[]
= "0.3"
= false
Example
The following will update an existing anime on a user's list, but the code to add / delete an anime is similar:
extern crate mal;
use MAL;
use List;
use WatchStatus;