Unofficial asyncio client for the YNAB API.
Project description
asyncio-for-ynab
Asyncio client for the YNAB API.
This package is generated from the YNAB OpenAPI spec and uses the OpenAPI Generator Python httpx client.
This project is not affiliated with, endorsed by, or officially connected with YNAB.
Install
python -m pip install asyncio-for-ynab
For local development:
python -m pip install -e ".[dev]"
Quick Start
import asyncio
from asyncio_for_ynab import ApiClient
from asyncio_for_ynab import Configuration
from asyncio_for_ynab import PlansApi
from asyncio_for_ynab import UserApi
async def main() -> None:
configuration = Configuration(access_token="your-access-token")
async with ApiClient(configuration) as api_client:
user_api = UserApi(api_client)
plans_api = PlansApi(api_client)
user = await user_api.get_user()
plans = await plans_api.get_plans()
print(user)
print(plans)
asyncio.run(main())
Common Patterns
Create a client once and pass it to any generated API class:
from asyncio_for_ynab import AccountsApi
from asyncio_for_ynab import ApiClient
from asyncio_for_ynab import Configuration
configuration = Configuration(access_token="your-access-token")
async with ApiClient(configuration) as api_client:
accounts_api = AccountsApi(api_client)
accounts = await accounts_api.get_accounts()
The package also exports generated models, response objects, and exceptions at the top level:
from asyncio_for_ynab import AccountResponse
from asyncio_for_ynab import ApiException
from asyncio_for_ynab import TransactionResponse
Development
Run the repository checks with pre-commit:
pre-commit run --all-files
Run the test suite:
tox -e py
Release Notes
Package versions mirror the YNAB API spec version.
For example, spec 1.83.0 is published as asyncio-for-ynab==1.83.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file asyncio_for_ynab-1.83.0.tar.gz.
File metadata
- Download URL: asyncio_for_ynab-1.83.0.tar.gz
- Upload date:
- Size: 103.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba9a3f3a63fd5a6c7ffba345533f851aed026a1940b6b34d9e9ac6b09e094afa
|
|
| MD5 |
af1d6ddedfe964ec5ea645b75b98351f
|
|
| BLAKE2b-256 |
ceafa86f19b16329424888048c8cd2b9b684a2e141aa75ed1f25ca7393fcabb0
|
File details
Details for the file asyncio_for_ynab-1.83.0-py3-none-any.whl.
File metadata
- Download URL: asyncio_for_ynab-1.83.0-py3-none-any.whl
- Upload date:
- Size: 254.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
07fd94db3f9483ac8a9cb73a5963d97c50eec1e66b93642143864cfc4e94888c
|
|
| MD5 |
8fa9c26215051fd9fdb6357b707457e3
|
|
| BLAKE2b-256 |
c65fbcc687e5f7bd515380155ab45982bfed546bc14ea7948c0195cc6dd5c35f
|
File details
Details for the file asyncio_for_ynab-1.83.0-py2.py3-none-any.whl.
File metadata
- Download URL: asyncio_for_ynab-1.83.0-py2.py3-none-any.whl
- Upload date:
- Size: 390.9 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.20
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e0ab3b9402eed34788a6abe3dcb77fafc040d4057287f679f087e0fe949a048b
|
|
| MD5 |
80a22e9226a05f38c62bfe729803a6a8
|
|
| BLAKE2b-256 |
a068afaf82f7d614b60e5d09057927159e598e58f0805657e64a054fd14dff4c
|