Client class

Handles MyAnimeList API requests.

Common behaviour:

At any point in time, if an error occurs while a request is being made to the MyAnimeList API, a ClientException will be thrown.

Common parameters:

fields - Specify which fields the MyAnimeList API should return. By default, certain fields are returned by the API. However, to ensure that the field you need will be returned, specify it explicitly.

Note that a field may have one or more sub-fields which can also be specified explicitly.

Also note that even if a field is explicitly specified, there are times (e.g. missing information) where the field will not be returned. Thus, make sure to check for null values.

limit - For methods that return a list, this limits the number of items in the list.

nsfw - Specifies whether NSFW content should be returned.

offset - For methods that return a list, this specifies the page number to be requested. For example, after requesting for 100 Animes in a user's anime list, specify an offset of 100 to get the next 100 Animes.

Constructors

Client(Client client)
Create a Client using an oauth2 authenticated client.
Client.fromJson({required String credentialsJson, required String id, required String secret})
Create a Client that will be authenticated using credentialsJson, id and secret.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

deleteMyAnimeListItem(int id) Future<void>
Delete the user's entry for the anime associated with id.
deleteMyMangaListItem(int id) Future<void>
Delete the user's entry for the manga associated with id.
getAnimeDetails(int id, {List<AnimeField>? fields, bool nsfw = false}) Future<Anime>
Get the Anime associated with id.
getAnimeList(String q, {List<AnimeField>? fields, int limit = 100, bool nsfw = false, int offset = 0}) Future<List<Anime>>
Get a list of Anime matching the specified query q.
getAnimeRanking(AnimeRankingType rankingType, {List<AnimeRankingField>? fields, int limit = 100, bool nsfw = false, int offset = 0}) Future<List<RankedAnime>>
Get a list of the top ranked Animes ranked by rankingType along with their ranking information.
getForumBoards() Future<List<ForumCategory>>
Get a list of ForumBoards grouped by their ForumCategory.
getForumTopicDetail(int topicId, {int limit = 100, int offset = 0}) Future<ForumTopic>
Get the ForumTopic associated with topicId.
getForumTopics({int? boardId, int limit = 100, int offset = 0, String? q, int? subboardId, String? topicUserName, String? userName}) Future<List<ForumTopicInfo>>
Get a list of ForumTopicInfo that match the provided parameters.
getMangaDetails(int id, {List<MangaField>? fields, bool nsfw = false}) Future<Manga>
Get the Manga associated with id.
getMangaList(String q, {List<MangaField>? fields, int limit = 100, bool nsfw = false, int offset = 0}) Future<List<Manga>>
Get a list of Manga matching the specified query q.
getMangaRanking(MangaRankingType rankingType, {List<MangaRankingField>? fields, int limit = 100, bool nsfw = false, int offset = 0}) Future<List<RankedManga>>
Get a list of the top ranked Mangas ranked by rankingType along with their ranking information.
getSeasonalAnime(int year, Season season, {List<AnimeField>? fields, int limit = 100, bool nsfw = false, int offset = 0, SeasonalAnimeSortingMethod sort = SeasonalAnimeSortingMethod.animeScore}) Future<List<Anime>>
Get a list of the Animes belonging to the season and year sorted by sort.
getSuggestedAnime({List<AnimeField>? fields, int limit = 100, bool nsfw = false, int offset = 0}) Future<List<Anime>>
Get a list of Animes suggested by MyAnimeList.
getUserAnimeList({List<AnimeField>? fields, int limit = 100, bool nsfw = false, int offset = 0, WatchStatus? status, UserAnimeListSortingMethod? sort, String username = '@me'}) Future<List<Anime>>
Get a list of Animes in the list of the user with username.
getUserInformation({List<UserField>? fields}) Future<User>
Get information about the user.
getUserMangaList({List<MangaField>? fields, int limit = 100, bool nsfw = false, int offset = 0, ReadStatus? status, UserMangaListSortingMethod? sort, String username = '@me'}) Future<List<Manga>>
Get a list of Mangas in the list of the user with username.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
updateMyAnimeListStatus(int id, UserAnimeListStatus status) Future<UserAnimeListStatus>
Update the user's status regarding the anime associated with id.
updateMyMangaListStatus(int id, UserMangaListStatus status) Future<UserMangaListStatus>
Update the user's status regarding the manga associated with id.

Operators

operator ==(Object other) bool
The equality operator.
inherited