// sdk · Python
Python SDK for the AstroWay API
Official `astroway` on PyPI — `Astroway` (sync) + `AsyncAstroway` (async) on top of `httpx`. Identical surface — the same API on both clients. Stainless-style error hierarchy, retry on 408/409/429/5xx, PEP 561 typed package. Python 3.9+, Trusted Publisher OIDC.
// 01 / install
Install
pip install astroway import: from astroway import Astroway
View on registry → astroway
// 02 / highlights
Highlights
- Sync + Async clients
- httpx + Pydantic
- Built-in retry + backoff
- PEP 561 typed
- Trusted Publisher OIDC
// 03 / first request
Make your first request
from astroway import Astroway
aw = Astroway(api_key=os.environ['ASTROWAY_API_KEY'])
chart = aw.post('/chart', body={
'date': '1990-07-14',
'time': '14:30:00',
'timezoneOffset': 3,
'latitude': 50.4501,
'longitude': 30.5234,
'houseSystem': 'P',
})
print(chart['angles']['asc']) Start building with Python
10,000 credits free per month. Open-source SDK, generated from OpenAPI 3.1, always in sync with the backend.