@coinbase/agentkit
Version:
Coinbase AgentKit core primitives
35 lines (34 loc) • 1.42 kB
TypeScript
import { z } from "zod";
import { ActionProvider } from "../actionProvider";
import { Network } from "../../network";
import { EnsoActionProviderParams, EnsoRouteSchema } from "./schemas";
import { EvmWalletProvider } from "../../wallet-providers";
import { EnsoClient } from "@ensofinance/sdk";
/**
* EnsoActionProvider is an action provider for Enso.
*/
export declare class EnsoActionProvider extends ActionProvider<EvmWalletProvider> {
readonly ensoClient: EnsoClient;
/**
* Constructor for the EnsoActionProvider
*
* @param params - The initialization parameters for the Enso action provider
*/
constructor(params?: EnsoActionProviderParams);
/**
* Finds the optimal route from a token to a token and executes it.
*
* @param walletProvider - The wallet to execute the transaction from.
* @param args - The input arguments for the action.
* @returns A message containing the token route details.
*/
route(walletProvider: EvmWalletProvider, args: z.infer<typeof EnsoRouteSchema>): Promise<string>;
/**
* Checks if the Enso action provider supports the given network.
*
* @param network - The network to check.
* @returns True if the Enso action provider supports the network, false otherwise.
*/
supportsNetwork: (network: Network) => boolean;
}
export declare const ensoActionProvider: () => EnsoActionProvider;