The Mee client instance used for API interactions
Extends the client with additional functionality
Extended client with both base and new functionality
Function that adds new properties/methods to the base client
Makes HTTP requests to the Http node
Parameters for generating the quote
Promise resolving to either a permit quote or on-chain quote payload
const quote = await getFusionQuote(client, {
chainId: "1",
walletProvider: "metamask",
trigger: {
chainId: "1",
paymentToken: "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48" // USDC
},
instructions: [{
to: "0x742d35Cc6634C0532925a3b844Bc454e4438f44e",
data: "0x...",
value: "0"
}]
});
// Returns either GetPermitQuotePayload or GetOnChainQuotePayload
// depending on USDC's permit support
Will throw an error if:
Gets a quote using either permit or standard on-chain transaction based on token capabilities. This function automatically determines whether to use permit-based or standard transactions by checking the payment token's permit support.