aiogithubapi
raw JSON → 26.0.0 verified Fri May 01 auth: no python
Asynchronous Python client for the GitHub API. Current version 26.0.0, requires Python >=3.13. Uses aiohttp and supports the full GitHub REST API via an async client model. Release cadence is irregular with major breaking changes in 26.0.0 (SemVer switch, Python 3.13 minimum, removal of deprecated helpers).
pip install aiogithubapi Common errors
error RuntimeError: Client is not initialized correctly. ↓
cause Creating GitHubAPI without async context manager.
fix
Use
async with GitHubAPI(token='...') as api: error ModuleNotFoundError: No module named 'aiogithubapi' ↓
cause Library not installed.
fix
Run
pip install aiogithubapi Warnings
breaking Version 26.0.0 drops Python <3.13 and removes the deprecated sigstore_verify_release_asset helper. ↓
fix Upgrade to Python >=3.13 and replace any use of sigstore_verify_release_asset with direct sigstore calls.
breaking Version 26.0.0 switches from CalVer to SemVer. Older versions like 23.2.0 used CalVer; 26.0.0 is the first SemVer release. Do not expect backwards compatibility. ↓
fix Pin to exact version and test before upgrading.
gotcha The library uses context managers; forgetting to use `async with` will raise a RuntimeError. ↓
fix Always use `async with GitHubAPI(...) as api:`.
Imports
- GitHubAPI
from aiogithubapi import GitHubAPI - GitHubClient
from aiogithubapi import GitHubClient
Quickstart
import os
from aiogithubapi import GitHubAPI
async def main():
token = os.environ.get('GITHUB_TOKEN', '')
async with GitHubAPI(token=token) as api:
user = await api.user.get()
print(user.login)