Hosts
PMXT serves two hostnames.api.pmxt.dev— reads, catalog search via Router, MCP server, venue passthrough (/api/*).trade.pmxt.dev— hosted writes (build / submit / cancel) and hosted account state (orders, positions, balances, trades) via/v0/trade/*,/v0/user/*, and/v0/orders/*.
pmxt_api_key authenticates against both — no separate credentials.
Reads and writes have different latency and availability profiles; the trading host is the hot path for signed-order submission and is operated independently.
API key
Every request tohttps://api.pmxt.dev needs a Bearer token. Get one
from pmxt.dev/dashboard — it works
immediately.
X-Api-Key: pmxt_live_... also works as a fallback, but Bearer is
canonical and what every SDK sends.
SDK setup
SetPMXT_API_KEY and the SDK automatically routes to the hosted
endpoint. No code changes versus local development.
- Python
- TypeScript
Venue credentials
Hosted writes (recommended)
In hosted mode, trade writes use PMXT’s PreFundedEscrow custody plus a locally-signed EIP-712 payload. You pass yourpmxt_api_key, the wallet
address you trade from, and a private key used only for local signing —
the private key never leaves your machine, and PMXT custodies USDC in
the escrow contract on your behalf.
Self-hosted / direct venue credentials (advanced)
When you run pmxt-core locally, or when you need venue-native trading where the venue exposes writes but hosted mode does not, you pass venue-native credentials (Polymarket private key, Kalshi RSA, Smarkets session, etc.) directly:Some venues (Polymarket, Limitless, Probable, Opinion, Baozi) require
raw wallet private keys with full fund control. Use a dedicated
trading wallet and read Security & Credential Handling
before passing private keys to PMXT — hosted or self-hosted.
Rotating keys
- Create a new key from the dashboard.
- Deploy the new key to your application.
- Revoke the old key once traffic has drained.
Errors
Today the SDKs raise the base
pmxt.errors.PmxtError for both 401 cases
— match on the message string. A dedicated InvalidApiKey subclass may
be added in a future SDK release; this doc will be updated when that
ships.
