"The cat api " async api wrapper in python Archived because I felt is was useless but is was fun making this project I learned so much.
pip install -U cat.py
Set your own client by first getting an apikey at thecatapi
import asyncio
from cat import Client
def main():
neko = Client("my_api_key")
...
await neko.close()
asyncio.run(main())
Getting five cats in page 1 in ascending order.
cat = await neko.get_cat(5, 1, "asc")
Getting cyprus breeded cat.
cat = await neko.get_cat_breed("Cyprus")
Getting all cats in the category 69. Sadly there is None.
cat = await neko.get_cat_category(69)
Getting cat with the gif type image.
cat = await neko.get_cat_image_type("gif")