getFlowQuote
Fetches a conversion quote for a flow. The quote includes the amounts, fees, estimated time, and an expiry. Call this after attaching a source.When to call
CallgetFlowQuote when executionState is source_attached, quoted, or signing. Calling it from quoted refreshes the quote. Calling it from signing returns the flow to quoted, so do not reuse the previous signing payload.
Before restoring or retrying a flow, call getFlow and check its current state.
Usage
Parameters
Returns
Promise<Flow>: the updated flow with quote populated:
fromAmount/toAmount are raw integer strings in the token’s smallest unit. Use fromTokenInfo.decimals/toTokenInfo.decimals to convert to a human-readable value (e.g. "1500000" with decimals: 6 is 1.5).
Quotes expire in 60 seconds. If the quote expires before you submit, call
getFlowQuote again.Examples
Quote with a specific ERC-20 token
Quote with native ETH
Deposit address source
For deposit address flows,flow.depositAddress is the address the user sends funds to. We recommend displaying it as a QR code and encoding the amount from flow.quote.fromAmount so wallets can pre-fill both fields on scan. fromAmount is a raw integer string in the token’s smallest unit — divide by 10 ** flow.quote.fromTokenInfo.decimals to get the decimal amount for URI schemes that expect one (e.g., bitcoin:, solana:). See the deposit address section of the JS SDK guide for a buildDepositUri helper that handles BTC, SOL, EVM (EIP-681), and TRON URI formats.
Quote with slippage tolerance
React
useGetFlowQuote is a mutation hook. Call mutate to request a quote on demand:
Related
- Fireblocks Flow JavaScript SDK guide - End-to-end flow guide
attachFlowSource- Attach a wallet or exchange sourcesubmitFlowTransaction- Submit for signing and broadcastprepareFlowSigning- Prepare signing (advanced)