Skip to main content

An asynchronous API wrapper for the pokeapi.

Project description

AioPokéApi

An Asynchronous API wrapper for the PokéApi.

Report issue · Request feature · Fork project

🗝️ Key Features

  • Use of modern Python keywords: async and await.
  • Every object is fully type hinted.
  • Objects get cached, this increases speed and avoids unnecessary API requests.

🌍 Documentation

AioPokéApi has a very minimal website, which you can find here. It also has some documentation.

☄️ Installation

pip install aiopokeapi
⚙️ Didn't work?

Depending on your Python installation, you might need to use one of the following:

  • Python is not in PATH

    path/to/python.exe -m pip install aiopokeapi
    
  • Python is in PATH but pip is not

    python -m pip install aiopokeapi
    
  • Unix systems can use pip3/python3 commands

    pip3 install aiopokeapi
    
    python3 -m pip install aiopokeapi
    
  • Using multiple Python versions

    py -m pip install aiopokeapi
    

🚀 Getting started

Aiopoke's goal is to be simple and easy to use:

import asyncio
import aiopoke

async def main():
   client = aiopoke.AiopokeClient()

   ability = await client.get_ability(1)
   generation = await ability.generation.fetch()

   await client.close()

asyncio.run(main())

Or even better, using a context manager:

# in main()
async with aiopoke.AiopokeClient() as client:
   ability = await client.get_ability(1)
   generation = await ability.generation.fetch()

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

aiopokeapi-0.1.6.tar.gz (12.3 MB view details)

Uploaded Source

Built Distribution

aiopokeapi-0.1.6-py3-none-any.whl (60.1 kB view details)

Uploaded Python 3

File details

Details for the file aiopokeapi-0.1.6.tar.gz.

File metadata

  • Download URL: aiopokeapi-0.1.6.tar.gz
  • Upload date:
  • Size: 12.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for aiopokeapi-0.1.6.tar.gz
Algorithm Hash digest
SHA256 60e2c8525408cd7a32b33e1cc5f4d4dec0dce947a6293319e8e6ffc7e5ce9a8d
MD5 c1958b2c6c77da3d690d14928464f1a3
BLAKE2b-256 14a4a07e1a887ceb7a0ef75b5c6e36fdc6a1f59d3b9922aa55dedd5610faab88

See more details on using hashes here.

File details

Details for the file aiopokeapi-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: aiopokeapi-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 60.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.17

File hashes

Hashes for aiopokeapi-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 bc353944976b18c6bfc1ff2c486f7c821c31b4ffb26eb056fd53cdc3a2e5a6de
MD5 6827522fdeb0bae666c155efecc08d0d
BLAKE2b-256 ba20ef00e58b188e7166c51c26489dc0765577e22de547ba3799b40471cdc4ca

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