useGetSwapPrice hook.
Extends
Partial<GetSwapPriceOptions>
Properties
| Property | Type | Description | Inherited from |
|---|---|---|---|
enabled? | boolean | Set to false to prevent automatic fetching even when all parameters are present. Defaults to true. | - |
network? | EvmSwapsNetwork | The network on which to perform the swap. | Partial.network |
fromToken? | `0x${string}` | The 0x-prefixed contract address of the token to sell. | Partial.fromToken |
toToken? | `0x${string}` | The 0x-prefixed contract address of the token to buy. | Partial.toToken |
fromAmount? | string | The amount of fromToken to sell, in atomic units. | Partial.fromAmount |
slippageBps? | number | Maximum slippage in basis points (100 = 1%). Default is 100. | Partial.slippageBps |
account? | `0x${string}` | The taker account address. If omitted, auto-selected from the signed-in user’s accounts. | Partial.account |