Documentation Index
Fetch the complete documentation index at: https://0xcaptain.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
IntentClient wraps the IntentRouter contract. Access it via client.intent.
Methods
postIntent
Post a new deposit intent to the auction system.PostIntentParams):
| Field | Type | Description |
|---|---|---|
asset | Address | Deposit token |
amount | string | Human-readable deposit amount |
minApyBps | number | Minimum APY in basis points |
maxDrawdownBps | number | Max acceptable drawdown in bps |
duration | number | Lock duration in seconds |
decimals | number | Asset decimals (default 18) |
Promise<Hash>
submitBid
Submit a solver bid on an open intent.SubmitBidParams):
| Field | Type | Description |
|---|---|---|
intentId | bigint | The intent to bid on |
tierVault | Address | Vault address the solver proposes |
promisedApy | number | Promised APY in bps |
bondAmount | string | Bond amount (human-readable) |
decimals | number | Bond token decimals (default 18) |
Promise<Hash>
settleAuction
Settle the auction for an intent (callable by anyone after the deadline).Promise<Hash>
cancelIntent
Cancel an open intent before the deadline (intent creator only).Promise<Hash>
getOpenIntents
Fetch recent open intents by scanning backwards from the latest ID.For production use, query the The Graph subgraph instead of using this method — it scans the chain directly and can be slow for large intent counts.
Promise<IntentData[]>