Import
Usage
Return Type: UseQueryResult<SwapPricesWithCurrencyInfo[]>
The hook returns all properties from React Query’s UseQueryResult with swap prices data. Here’s the detailed structure:
Properties
data
SwapPricesWithCurrencyInfo[] | undefined
Array of swap price objects containing:
price (SwapPrice)
currencyAddress: Address of the currencycurrencyBalance: Balance of the currencyprice: The swap pricemaxPrice: The maximum price for the swaptransactionValue: The value of the transaction
info (ContractInfo)
chainId: Chain ID where the token existsaddress: Token contract addresssource: Source of the token informationname: Token nametype: Token typesymbol: Token symboldecimals: Token decimalslogoURI: Token logo URLdeployed: Whether the token is deployedbytecodeHash: Hash of the token’s bytecodeextensions: Additional token metadataupdatedAt: Last update timestampnotFound: Whether token was not foundqueuedAt: When token was queued for updatestatus: Token resource status
balance (Balance)
balance: User’s balance of the currency in base units
isLoading
boolean
Loading state for the data fetch.
isError
boolean
Error state indicating if the query failed.
error
Error | null
Any error that occurred during data fetching.