Skip to main content

maxy-labs (Python)

The Maxy HTTP API from Python 3.10 or later, under the TypeScript client's resource names in snake_case. One dependency, httpx. MIT licence (see LICENSE). It installs as maxy-labs and imports as maxy; the types are inline (py.typed).

pip install maxy-labs
export MAXY_API_KEY=$(curl -s -X POST https://openapi.maxy.co/v1/sandbox/keys | jq -r .secretKey)
from maxy import Maxy, MaxyError

maxy = Maxy()  # reads MAXY_API_KEY
price = maxy.prices.get("ETH on base", "BTC", "0.01")
quote = maxy.quotes.get("ETH on base", "BTC", "0.01", from_address=wallet, to_address="bc1q…")
if not quote.get("order"):
    raise SystemExit(quote.get("message") or "This quote cannot become an order: see its issues.")

signature = your_signer.sign_typed_data(quote["signing"]["payloads"][0]["typedData"])
placed = maxy.orders.create(quote["order"], signature=signature, external_id="inv-42")

for state in maxy.orders.watch(placed["orderId"]):
    print(state["state"], state.get("btcTxId"))

Every route takes your key, apart from the few that need none (GET /, /openapi.json, /health, /ping, /config, /chains, the status page's routes and POST /sandbox/keys). A test key (mxk_test_…) runs everything in the sandbox.

Resource Methods
prices get, stream
pairs list, get, search_tokens
chains list
quotes get, batch, seconds_until_expiry
orders create, submit_signature, submit, get, list, iterate, export_csv, cancel, events, stream, refund, deposit, claim, bridge, steps, follow, watch, resume
status by_tx_hash, by_intent_hash, by_bitcoin_txid
addresses validate
limits, health, key, config, ping, openapi get
webhooks verify, create, list, remove, test, events, replay
sandbox_controls advance, scenarios, rates
account get, usage
keys create, rotate, revoke, set_origins
limit_requests create, list
statements get, download
explorer lookup
system status, history, incidents, maintenance, verified, subscribe, confirm, unsubscribe
checkout verify
feedback, security_reports send

Not here, because a server has no use for them: the two stream tickets (POST /prices/stream-ticket and POST /orders/{id}/stream-ticket, a browser's way to open a stream without sending its key) and the status feed (GET /system/feed.xml, RSS). prices.stream and orders.stream send the key in a header.

AsyncMaxy is the same client, awaited; orders.watch, orders.iterate and the two streams are async iterators there.

Every failure is a MaxyError subclass with code, status, request_id, retryable, details and docs_url: the same names and classes as TypeScript. Reads, and calls carrying an idempotency key, retry twice on 429, 502, 503, 504 or a dropped connection, honouring Retry-After. orders.create sets its key from the order id.

Answers are plain dicts, each with its own .meta (request id, status, retries, latency, rate limit). Maxy(models=True) gives pydantic models instead, generated from the OpenAPI document (maxy/models.py; pip install "maxy-labs[models]"). Flow helpers that need a browser wallet stay in TypeScript.

Release signing key (ed25519, namespace maxy-sdk): SHA256:TYUfXuFNZbCUxy2c0P3mWnJjZhpEurFU0ZkuSJgAxfo. It signs https://maxy.co/sdk/SHA256SUMS, which lists this wheel's SHA-256; how to check: https://maxy.co/docs/security-checks

Metadata

Release files for maxy-labs 1.1.11

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

Source distribution (sdist)

Source distribution for maxy-labs 1.1.11
File Size Uploaded Provenance Actions
maxy_labs-1.1.11.tar.gz 31.5 kB Without provenance Details for maxy_labs-1.1.11.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for maxy-labs 1.1.11
File Interpreter ABI Platform Actions
maxy_labs-1.1.11-py3-none-any.whl Python 3 none any Details for maxy_labs-1.1.11-py3-none-any.whl

Total release size: 56.5 kB

Release files / maxy_labs-1.1.11.tar.gz

Download URL maxy_labs-1.1.11.tar.gz
Size 31.5 kB
Tags Source
SHA-256 checksum
How to use checksums
1bee4c84513f2ea325cd5b089ec0a15450ac34db74c3b249af6237151dee6917
BLAKE2b-256 checksum
How to use checksums
d2cef40f85f7878da93490cf31c02640a138bf23720f1588a0d5008ba7c99f51
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Release files / maxy_labs-1.1.11-py3-none-any.whl

Download URL maxy_labs-1.1.11-py3-none-any.whl
Size 25.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8bcedd346aba7aadf7c6466441ed2473bf5a10cbe9b3239fd67a9c89d9af5a2d
BLAKE2b-256 checksum
How to use checksums
bd2de651565d6d3745c89c109911374c095459a6d699f6eb0782a22adf5ea17b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.8

Security for maxy-labs 1.1.11

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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