aionap is a Python asyncio enabled REST client. It uses a similar API like slumber and copies shameless other parts of it.
Feel free to contribute via pull requests, issues or email messages.
Install aionap:
$ pip install aionap
Install Optional Requirement:
pip install pyyaml
Use it!
- Get an API object
import aionap
api = aionap.API('https://demo.api-platform.com')
- Fetch a url/resource (e.g. https://demo.api-platform.com/books)
async with api.books as resource:
response = await resource.get()
For more see the documenation, the test/test_demo_api.py file or the example directory.
aionap is available via PyPI, just install it as usual.
$ pip install aionap
aionap
requires Python >= 3.6.
[OPTIONAL] PyYaml (Required for the yaml serializer):
$ pip install pyyaml
- Basic Auth support
- JSON, YAML serializers
- GET, POST, PUT, PATCH, DELETE of resources
- Good test coverage
- OAuth support
- Readthedocs API documentation (SSL_CERT_FILE)
Python >= 3.6
BSD 2-Clause License
- Christian Assing (Main author)