Methods
Get quotes, routes and orders
Overview
static init(config: MetaRouterConfig): MetaRouterClientquote(params: QuotesParams): Promise<QuotesResponse>getTokenRoutes(params: TokenRoutesParams): Promise<TokenRoutesResponse>getSupportedChains(params: SupportedChainsParams): Promise<SupportedChainsResponse>getOrder(params: OrderParams): Promise<OrderResponse>getOrders(params: OrdersParams): Promise<OrdersResponse>
React Hooks
The SDK provides React hooks for easy integration:
useQuoteuseTokenRoutesuseSupportedChainsuseOrderPollinguseWalletOrders
useQuote
Get quotes for a transfer:CopyAsk AI
useTokenRoutes
Fetch available token routes:CopyAsk AI
useSupportedChains with useTokenRoutes
Fetch supported chains and token routes, using chain and token data to display route information with icons:CopyAsk AI
useOrderPolling
Poll for order status:CopyAsk AI
useWalletOrders
Fetch orders for a wallet:CopyAsk AI
Last updated