UNPKG

@cyberk/hyperion-sdk

Version:

Hyperion SDK from Cyberk

13 lines (12 loc) 810 B
import type { QueryObserverOptions } from "@tanstack/query-core"; import { CHAIN_IDS } from "../constants"; import { SimulationResponse } from "../types/simulation"; import { getQuoteQueryKey, GetQuoteOptions } from "../query/getQuote"; /** * Hook to get a quote for a swap operation * This will call simulate_swap_operations in the contract and return the quote */ export declare const useQuote: ({ routerContract, offerAmount, offerAsset, askAsset, chainId, options: observerOptions, }: GetQuoteOptions & { chainId: CHAIN_IDS; options?: Omit<QueryObserverOptions<SimulationResponse | undefined, Error, SimulationResponse | undefined, ReturnType<typeof getQuoteQueryKey>>, "queryKey" | "queryFn">; }) => import("@tanstack/react-query").DefinedUseQueryResult<SimulationResponse | undefined, Error>;