Intent API
Intent-based trading with JIT optimization
Intent API
The Intent API provides methods for intent-based trading with just-in-time (JIT) optimization and MEV protection.
Access
Methods
create_intent
Create a trading intent.
Parameters
| Parameter | Type | Description |
|---|---|---|
market_id | str | The market to trade on |
side | str | "yes" or "no" |
type | str | "buy" or "sell" |
size | float | Number of contracts |
user_public_key | str | User's Solana public key |
min_price | float | None | Minimum acceptable price |
max_price | float | None | Maximum acceptable price |
deadline | int | None | Unix timestamp deadline |
Example
get_intent_quote
Get a quote for an intent without submitting.