From 7bb0b5ce2397d0af781f3a2774c211c706f99247 Mon Sep 17 00:00:00 2001 From: trails-docs-agent Date: Thu, 17 Sep 2026 03:19:09 +0000 Subject: [PATCH] docs: correct quote expiry to 15 minutes in api reference MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Quotes are valid for 15 minutes, not 5. CommitIntent does not create a separate 10-minute window — committed intents share the same 15-minute quote expiry checked by ExecuteIntent on a QUOTED intent. #110 landed with the wrong timings; correcting them here. Source of truth: 0xsequence/trails-api release - lib/intentmachine/handle_quote.go:476-478 — "Set intent expiry to 15 minutes: gives users enough time for QR scanning and slow wallets." Sets intent.ExpiresAt = time.Now().Add(15 * time.Minute). - lib/intentmachine/handle_commit.go:80 — CommitIntent rejects when dbIntent.QuoteExpired() using the same ExpiresAt; no separate committed-window bump. Files updated: - api-reference/endpoints/quote-intent.mdx — 5 → 15 minutes - api-reference/endpoints/execute-intent.mdx — 5 → 15; drop bogus "10 minutes after CommitIntent" window - api-reference/endpoints/execute-intent-edge.mdx — 5 → 15 minutes - api-reference/endpoints/commit-intent.mdx — replace bogus 10-minute post-commit window with the shared quote expiry - api-reference/introduction.mdx — quickstart warning + timing table Co-Authored-By: Claude Opus 4.7 (1M context) Claude-Session: https://claude.ai/code/session_017M77Ao94G6NcdUGvVMyNzT --- api-reference/endpoints/commit-intent.mdx | 2 +- api-reference/endpoints/execute-intent-edge.mdx | 6 ++++++ api-reference/endpoints/execute-intent.mdx | 2 +- api-reference/endpoints/quote-intent.mdx | 2 +- api-reference/introduction.mdx | 8 ++++---- 5 files changed, 13 insertions(+), 7 deletions(-) diff --git a/api-reference/endpoints/commit-intent.mdx b/api-reference/endpoints/commit-intent.mdx index d2996f9..2127d8d 100644 --- a/api-reference/endpoints/commit-intent.mdx +++ b/api-reference/endpoints/commit-intent.mdx @@ -76,7 +76,7 @@ console.log('Intent committed:', intentId); ## Important Notes -Committed intents must be executed within **10 minutes**. Call `ExecuteIntent` before this window expires or the intent will expire and require a fresh quote. +Committed intents share the quote's expiry — call `ExecuteIntent` within **15 minutes** of the original `QuoteIntent` call. `CommitIntent` does not extend the window; if the quote expires, request a fresh one. diff --git a/api-reference/endpoints/execute-intent-edge.mdx b/api-reference/endpoints/execute-intent-edge.mdx index dc8e773..9055206 100644 --- a/api-reference/endpoints/execute-intent-edge.mdx +++ b/api-reference/endpoints/execute-intent-edge.mdx @@ -79,6 +79,12 @@ const { intentStatus } = await armResponse.json() // Step 4: Poll GetIntentReceipt / WaitIntentReceipt for completion. ``` +## Timing Requirements + + +Arm the intent within the quote's expiration window (**15 minutes** from `QuoteIntentEdge`). After arming, the user must complete the edge deposit before the intent's overall expiry, otherwise the intent refunds. + + ## Errors | Error | When | diff --git a/api-reference/endpoints/execute-intent.mdx b/api-reference/endpoints/execute-intent.mdx index f1a1b8e..a7bc7a8 100644 --- a/api-reference/endpoints/execute-intent.mdx +++ b/api-reference/endpoints/execute-intent.mdx @@ -183,7 +183,7 @@ console.log('Receipt:', receipt); ## Timing Requirements -Call `ExecuteIntent` within the quote's expiration window (**5 minutes** from `QuoteIntent`). If the quote expires before execution, request a new quote and execute again. Legacy callers that committed first have **10 minutes** after `CommitIntent` to execute. +Call `ExecuteIntent` within the quote's expiration window (**15 minutes** from `QuoteIntent`). If the quote expires before execution, request a new quote and execute again. Legacy callers that committed first still share this same quote-expiry window — `CommitIntent` does not extend it. ## Error Handling diff --git a/api-reference/endpoints/quote-intent.mdx b/api-reference/endpoints/quote-intent.mdx index f01e07e..43c7f16 100644 --- a/api-reference/endpoints/quote-intent.mdx +++ b/api-reference/endpoints/quote-intent.mdx @@ -98,7 +98,7 @@ console.log('Quote:', quote); ## Quote Expiration -Quotes expire **5 minutes** after being issued. You must call `ExecuteIntent` (or `ExecuteIntentEdge` for a Solana/Tron origin) before the quote expires, or you'll need to request a new quote. +Quotes expire **15 minutes** after being issued. You must call `ExecuteIntent` (or `ExecuteIntentEdge` for a Solana/Tron origin) before the quote expires, or you'll need to request a new quote. ## Next Steps diff --git a/api-reference/introduction.mdx b/api-reference/introduction.mdx index 9d12487..7556bed 100644 --- a/api-reference/introduction.mdx +++ b/api-reference/introduction.mdx @@ -122,7 +122,7 @@ Use `EXACT_INPUT` when you know how much you want to spend, and `EXACT_OUTPUT` w The `intent` object contains everything needed to execute the intent and the server rejects mutated payloads, so pass it back unchanged. -Quotes expire **5 minutes** after being issued. Call `ExecuteIntent` (or `ExecuteIntentEdge` for Solana/Tron origins) within this window, or request a new quote. Legacy callers that commit first have **10 minutes** after commit to execute. +Quotes expire **15 minutes** after being issued. Call `ExecuteIntent` (or `ExecuteIntentEdge` for Solana/Tron origins) within this window, or request a new quote. Committing first does not extend the window; legacy callers still share the same 15-minute quote expiry. @@ -536,12 +536,12 @@ Quotes have strict time limits: | Stage | Time Limit | What Happens | |-------|------------|--------------| -| Quote validity | 5 minutes | Quote expires, request a new one | +| Quote validity | 15 minutes | Quote expires, request a new one | | After ExecuteIntent / ExecuteIntentEdge | N/A | Trails handles execution timing | -| Legacy: After CommitIntent | 10 minutes | Must call ExecuteIntent within this window | +| Legacy: After CommitIntent | Shares quote expiry | Must call ExecuteIntent before the original 15-minute window closes | -Always check quote expiration before executing. The `intent.expiresAt` timestamp indicates when the quote becomes invalid. +Always check quote expiration before executing. The `intent.expiresAt` timestamp is the single deadline for calling `ExecuteIntent` (or `ExecuteIntentEdge`), whether or not you committed first. ## Rate Limiting