Skip to main content

Typed Aster

A fully typed, validated async client for the Aster API.

PyPI version Python versions Docs License



from typed_aster import Aster

async with Aster.new(public=True) as client:
  book = await client.futures.market.depth('BTCUSDT', limit=5)
  print(book['bids'][0])

One Aster client covers five surfaces:

  • client.futures: perpetual futures
  • client.spot: spot trading
  • client.prediction: prediction markets
  • client.chain: Aster Chain (staking, transfers, withdrawals, and on-chain reads by address)
  • client.bapi: the web app's public API (every asset that can be deposited or withdrawn)

Public market data needs no credentials. Everything signed uses Aster's Pro API wallets. See Authenticated Setup.

Why Typed Aster?

  • 🎯 Precise Types: Typed order unions and datetime timestamps across futures, spot, prediction and Aster Chain, not dict/Any. Prices and quantities Aster sends as strings are Decimal; the few amounts it sends as JSON numbers (Aster Chain balances such as walletBalance, withdrawal fee estimates, fee caps) are float.
  • ✅ Runtime Validation: Every REST, JSON-RPC and WebSocket response is validated by default, not just typed on paper.
  • ⚡ Async First: Async HTTP plus WebSocket market and user-data streams, built for concurrent workflows.
  • 📚 Full Surface: Every documented Pro API endpoint, including strategy orders, sub-accounts, builders, prediction outcomes and staking.

Installation

pip install typed-aster

How To

Reference

Design Philosophy

Typed Aster follows the principles outlined in this blog post.

Details matter. Developer experience matters.

License

MIT — see LICENSE.

Metadata

Release files for typed-aster 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for typed-aster 0.3.0
File Size Uploaded
typed_aster-0.3.0.tar.gz 142.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for typed-aster 0.3.0
File Interpreter ABI Platform
typed_aster-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 498.9 kB

Release files / typed_aster-0.3.0.tar.gz

Download URL typed_aster-0.3.0.tar.gz
Size 142.5 kB
Tags Source
SHA-256 checksum
How to use checksums
bdf88aa5333464a2a8f865cbe731f9d8795968065096a80a99d5267ff94ee1e1
BLAKE2b-256 checksum
How to use checksums
e019ff3ff3f7b2340977a5fc2b49e2724a7eda162e0839e66f2e6df0441b2beb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release files / typed_aster-0.3.0-py3-none-any.whl

Download URL typed_aster-0.3.0-py3-none-any.whl
Size 356.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aeb0a6467530c88f0a6a2c3caf902e820014010628a3ce122b4297baf7d28bc1
BLAKE2b-256 checksum
How to use checksums
292ad2585f03946cba45b678d0d980bc9164718c9cc39815a72c7aa60c6cbf0b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 6, 2026.

Transparency log

Release history Release notifications | RSS feed

0.5.0

2 release files

0.4.0

2 release files

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page