Async wrapper for the MyAnimeList API


License
MIT
Install
pip install Tokage==0.1.12.2

Documentation

Tokage

Tokage is an async wrapper for the MyAnimeList API. This wrapper is compatible with Python 3.5+ and uses Jikan as an alternative to the default MAL API.

Documentation can be found here.

This wrapper is aimed at ease of use and an object-oriented style, and does not require your account credentials.

Example

import asyncio
import tokage

async def main():
    client = tokage.Client()  # Create a new Client instance

    anime_id = await client.search_id("anime", "re zero")  # Search for an ID
    anime = await client.get_anime(anime_id)  # Get the Anime object from the API

    print("Anime title: {}".format(anime.title))  # Print the title of the Anime
    await client.cleanup()  # cleanup after everything

loop = asyncio.get_event_loop()
loop.run_until_complete(main()) # Run main

Prints:

Anime title: Re:Zero kara Hajimeru Isekai Seikatsu