Install the package
pip install "polyester-sdk==0.11.0"Requires Python 3.11+. Realtime (Centrifugo) and on-chain Funding helpers ship with every install.
PyPI: polyester-sdk. Source: Fabric-Labs/polyester-sdk-python.
Pre-1.0
The SDK is pre-1.0, so a minor release may include breaking changes. Pin an exact version in
production (example above). It is an API-key-only SDK: it supports signed unary calls, binary
realtime subscriptions with handshake-before-return, and opaque pagination tokens for complete
trigger list/event scans. Breaking changes are called out in the repository changelog.
Testnet endpoints
Always pass environment=POLYESTER_TESTNET_ENVIRONMENT; the client does not select testnet by itself:
| Setting | Testnet |
|---|---|
| API | https://api.testnet.polyester.com |
| WebSocket | wss://api.testnet.polyester.com |
Override with constructor api_url / ws_url. See Environments.
Verify the install
Public market data needs no credentials:
from polyester import AsyncPolyester, POLYESTER_TESTNET_ENVIRONMENT
async with AsyncPolyester(environment=POLYESTER_TESTNET_ENVIRONMENT) as client: # public market data only
...import asyncio
from polyester import AsyncPolyester, POLYESTER_TESTNET_ENVIRONMENT
async def main() -> None:
async with AsyncPolyester(environment=POLYESTER_TESTNET_ENVIRONMENT) as client:
overview = await client.market_overview.list(limit=5)
for market in overview.markets:
print(market.symbol, market.last_price)
asyncio.run(main())If that prints a few markets, you are connected. Next: Quickstart.