Order Types
Supported SDK enums are MARKET, LIMIT, PEG, STOP_MARKET, and STOP_LIMIT.
Summary
| Type | Price field | Notes | Typical TIF |
|---|---|---|---|
MARKET | Optional cap | Optional slippage_bps; quantity XOR quote_notional | IOC only |
LIMIT | Required | Supports post-only/reduce-only/STP | GTC, GTD, IOC, FOK |
PEG | Not accepted | peg_offset_bps from Pyth mark | GTC, GTD |
STOP_MARKET | Not accepted | trigger_price; optional slippage_bps | GTC, GTD |
STOP_LIMIT | Required | trigger_price + price | GTC, GTD |
See Order Compatibility for the full matrix. Public TIF strings are GTC / IOC / FOK / GTD.
Market
Executes immediately at the best available prices. Walks the book until the order is filled or liquidity is exhausted.
{
"symbol": "BTC-USDC-PERP",
"side": "BUY",
"order_type": "MARKET",
"quantity": "0.1",
"time_in_force": "IOC",
"slippage_bps": 50
}
If price is supplied on a market order, it acts as a price cap. slippage_bps optionally caps walk vs mark (basis points); omitted → venue max.
Limit
Executes at the specified price or better. Unfilled remainder rests in the book until matched, cancelled, or expired (per time_in_force).
{
"symbol": "BTC-USDC-PERP",
"side": "BUY",
"order_type": "LIMIT",
"quantity": "0.1",
"price": "95000",
"time_in_force": "GTC"
}
Peg
Tracks the sequencer's Pyth mark plus a signed basis-point offset.
{
"symbol": "BTC-USDC-PERP",
"side": "BUY",
"order_type": "PEG",
"peg_offset_bps": -5,
"quantity": "0.1",
"time_in_force": "GTC"
}
price is not accepted on PEG; the effective price is Pyth mark adjusted by peg_offset_bps.
Stop market / stop limit
Stop orders arm at trigger_price, then submit a market or limit child. slippage_bps applies to stop-market the same way as market.