Skip to main content
POST
Python (SDK)

Authorizations

x-api-key
string
header
required

Your Compass API Key. Get your key here.

Body

application/json

Preview a buy or sell quote for a tokenized equity.

Read-only: this previews a quote without consuming a quote_id or committing an order. Use it to surface expected output, fees, and a thin-liquidity warning before the user confirms; pass the same body (plus slippage_bps) to POST /tokenized_assets/order when they do.

from_token
string
required

Token the sender is paying. Either an on-chain symbol (e.g. TSLAon), the literal USDC, or a 0x-prefixed token address.

Examples:

"USDC"

"WETH"

"0xA0b86a33E6441ccF30EE5DdEF1E9b652C91ac1c8"

to_token
string
required

Token the sender is receiving. Same accepted forms as from_token.

Examples:

"USDC"

"WETH"

"0xA0b86a33E6441ccF30EE5DdEF1E9b652C91ac1c8"

amount
string
required

Human-readable amount of from_token to swap (decimal string). Decimals are applied server-side.

owner
string
required

Wallet that owns the Tokenized Assets Account. Used to verify the account is deployed before quoting; the account address is derived deterministically from this owner.

Response

Successful Response

Preview of input/output amounts plus auction-derived risk hints.

quote
Quote · object
required

Preview of input/output amounts and fees. Identical shape to the quote block on POST /tokenized_assets/order.

Slippage tolerance in basis points (1 bp = 0.01%) the UI should echo back as slippage_bps on POST /tokenized_assets/order. Derived from the on-chain auction range (auctionEndAmount vs toTokenAmount) plus a small buffer; capped at 5000 bps.

auction_range_bps
integer
required

Worst-case basis-points gap between the auction's end amount and the reference quote amount. Surfaces as a thin-liquidity warning before the user signs.