Skip to main content

A Simple & Lightweight Asynchronous Python Wrapper for Kitsu's Manga & Anime API.

Project description

Kitsu.py

Python API wrapper for kitsu.io
A Simple & Lightweight Asynchronous Python Wrapper for Kitsu’s Manga & Anime API.

Features

  • Simple and Modern — Simple and Modern Pythonic API using async/await.
  • Typed — Fully typed to provide a smooth experience while programming.
  • Features — Get information about Categories, Episodes, Streaming Links and a lot more!
  • Custom Search — Find any Anime/Manga using Filters or Trending Animes & Mangas.

Requirements

Python 3.8+

Installing

To install the library, run the following commands:

# Linux/MacOS
python3 -m pip install -U kitsu.py

# Windows
py -3 -m pip install -U kitsu.py

Example

Search for an anime:

import kitsu
import asyncio

client = kitsu.Client()

async def main():
    # Search a specific anime with the name
    anime = await client.search_anime("jujutsu kaisen", limit=1)
    
    print("Canonical Title: " + anime.canonical_title)
    print("Average Rating: " + str(anime.average_rating))
    
    # This returns a list of 5 animes in the spring season 2022
    animes_in_spring = await client.search_anime(limit=5, season_year=2022, season='spring')
    
    print(*[a.title for a in animes_in_spring], sep=", ")
    
    # Close the internal aiohttp ClientSession
    await client.close()

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

This prints:

Canonical Title: Jujutsu Kaisen
Average Rating: 85.98
That Time I Got Reincarnated as a Slime: Ramiris to the Rescue, Blue Thermal, Q&A=E, Smol Adventures, Estab-Life: Great Escape

You can find more examples in the examples directory.

License

This project is distributed under the MIT license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kitsu.py-1.1.1.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

kitsu.py-1.1.1-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

Details for the file kitsu.py-1.1.1.tar.gz.

File metadata

  • Download URL: kitsu.py-1.1.1.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.10.2 Windows/10

File hashes

Hashes for kitsu.py-1.1.1.tar.gz
Algorithm Hash digest
SHA256 a5526a60e2bbe40bef84f4012cff3e27011ebfddffbeacfd55855cf6eeb9d9d8
MD5 a2cdd8939d1ca42b5a6e2cd81ef185f2
BLAKE2b-256 e213db8449b53d5a5e0d6853f008be3e184ca64398c9a122af321b9078f67cee

See more details on using hashes here.

File details

Details for the file kitsu.py-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: kitsu.py-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 12.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.13 CPython/3.10.2 Windows/10

File hashes

Hashes for kitsu.py-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1b93e2d576e840f446ccb10cfb4953072467caf266d41c4b6f80973db2eb4b16
MD5 c2b5fd70781716b3f231dac1ff97d578
BLAKE2b-256 7977b66852a2ff98ffa5d1b5439c1f02fcc30debfd15f1ea79e6495bf98fbcfb

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page