diff --git a/typescript/.changeset/beige-pants-make.md b/typescript/.changeset/beige-pants-make.md new file mode 100644 index 000000000..cd6ac0cbc --- /dev/null +++ b/typescript/.changeset/beige-pants-make.md @@ -0,0 +1,5 @@ +--- +"@coinbase/agentkit": patch +--- + +Updated Vaults.fyi provider to use the v2 API diff --git a/typescript/agentkit/README.md b/typescript/agentkit/README.md index da128eaf5..f965c6c1b 100644 --- a/typescript/agentkit/README.md +++ b/typescript/agentkit/README.md @@ -575,25 +575,45 @@ const agent = createReactAgent({ Gets historical APY and TVL data for a specific vault over time. - deposit - Deposits assets into a selected vault to start earning yield. + transaction_context + Gets the available balances and operations for a given vault. - redeem - Redeems assets from a vault to withdraw principal and earned yield. - - - claim - Claims rewards from a vault without withdrawing the principal deposit. + execute_step + Executes an operation on a given vault. - balances - Retrieves user's native token and ERC20 token balances across supported networks. + user_idle_assets + Gets the user's idle assets. positions Gets user's current positions in vaults including balances and unclaimed rewards. + + rewards_context + Gets the available rewards for a given user. + + + claim_rewards + Claims requested rewards for a given user. + + + benchmark_apy + Gets the benchmark APY. + + + historical_benchmark_apy + Gets the historical benchmark APY. + + + total_vault_returns + Gets the total returns for a given vault. + + + user_events + Gets the user's events for a given vault. +
diff --git a/typescript/agentkit/package.json b/typescript/agentkit/package.json index be7a80692..69ac8a251 100644 --- a/typescript/agentkit/package.json +++ b/typescript/agentkit/package.json @@ -45,12 +45,14 @@ "@coinbase/cdp-sdk": "^1.38.0", "@coinbase/coinbase-sdk": "^0.20.0", "@coinbase/x402": "^0.6.3", + "@ensofinance/sdk": "^2.0.6", "@jup-ag/api": "^6.0.39", "@privy-io/public-api": "2.18.5", "@privy-io/server-auth": "1.18.4", "@solana/kit": "^2.1.1", "@solana/spl-token": "^0.4.12", "@solana/web3.js": "^1.98.1", + "@vaultsfyi/sdk": "^2.1.9", "@zerodev/ecdsa-validator": "^5.4.5", "@zerodev/intent": "^0.0.24", "@zerodev/sdk": "^5.4.28", @@ -67,9 +69,8 @@ "opensea-js": "^7.1.18", "reflect-metadata": "^0.2.2", "sushi": "6.2.1", - "@ensofinance/sdk": "^2.0.6", "twitter-api-v2": "^1.18.2", - "viem": "^2.22.16", + "viem": "2.38.3", "x402": "^0.6.0", "x402-axios": "^0.6.0", "zod": "^3.23.8" diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/README.md b/typescript/agentkit/src/action-providers/vaultsfyi/README.md index 2e58c1819..817a5b527 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/README.md +++ b/typescript/agentkit/src/action-providers/vaultsfyi/README.md @@ -15,11 +15,7 @@ vaultsfyi/ ├── schemas.ts # Action schemas and types ├── constants.ts # Provider constants ├── utils.ts # Provider utility functions -├── /api - ├── actions.ts # vaultsfyi transactional API actions - ├── types.ts # vaultsfyi API types - ├── vaults.ts # vaults list getter - ├── historicalData.ts # vaults historical data getter +├── sdk.ts # vaultsfyi SDK client ├── index.ts # Package exports └── README.md # Documentation (this file) ``` @@ -27,12 +23,17 @@ vaultsfyi/ ## Actions - `vaults`: Get the list of available vaults on vaultsfyi. - `vault_details`: Get details of a specific vault. -- `historical_data`: Get historical data for a specific vault. -- `deposit`: Deposit assets into a vault. -- `redeem`: Redeem assets from a vault. -- `claim`: Claim rewards from a vault. -- `user-wallet-balances`: Get the user's native token and compatible ERC20 token balances. -- `positions`: Get the user's positions in vaults. +- `vault_historical_data`: Get historical data for a specific vault. +- `transaction_context`: Get the transaction context for a vault. +- `execute_step`: Execute a step in a vault. +- `user_idle_assets`: Get the user's idle assets. +- `positions`: Get the user's positions. +- `rewards_context`: Get the rewards context. +- `claim_rewards`: Claim rewards. +- `benchmark_apy`: Get the benchmark APY. +- `historical_benchmark_apy`: Get the historical benchmark APY. +- `total_vault_returns`: Get the total returns for a vault. +- `user_events`: Get the user's events for a vault. ## Network Support This provider supports selected evm networks. diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/api/actions.ts b/typescript/agentkit/src/action-providers/vaultsfyi/api/actions.ts deleted file mode 100644 index 38eb8ae2c..000000000 --- a/typescript/agentkit/src/action-providers/vaultsfyi/api/actions.ts +++ /dev/null @@ -1,66 +0,0 @@ -import z from "zod"; -import { claimActionSchema, depositActionSchema, redeemActionSchema } from "../schemas"; -import { createSearchParams } from "../utils"; -import { VAULTS_API_URL } from "../constants"; -import { ApiError } from "./types"; -import { Address, Hex } from "viem"; - -type FetchVaultActionsParams = ( - | { - action: "deposit"; - args: z.infer; - } - | { - action: "redeem"; - args: z.infer; - } - | { - action: "claim-rewards"; - args: z.infer; - } -) & { - sender: string; - apiKey: string; -}; - -export type Actions = { - actions: { - tx: { - to: Address; - data: Hex; - value: string; - chainId: number; - }; - description: string; - }[]; - currentActionIndex: number; -}; - -/** - * Fetches a list of actions for a vault from the vaultsfyi API. - * - * @param root0 - The fetch parameters - * @param root0.action - The action to fetch - * @param root0.args - The action parameters - * @param root0.sender - The sender address - * @param root0.apiKey - The vaultsfyi API key - * @returns The list of actions - */ -export async function fetchVaultActions({ - action, - args, - sender, - apiKey, -}: FetchVaultActionsParams): Promise { - const params = createSearchParams({ - ...args, - sender, - }); - const response = await fetch(`${VAULTS_API_URL}/transactions/vaults/${action}?${params}`, { - method: "GET", - headers: { - "x-api-key": apiKey, - }, - }); - return (await response.json()) as Actions | ApiError; -} diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/api/historicalData.ts b/typescript/agentkit/src/action-providers/vaultsfyi/api/historicalData.ts deleted file mode 100644 index a4e4bfb2d..000000000 --- a/typescript/agentkit/src/action-providers/vaultsfyi/api/historicalData.ts +++ /dev/null @@ -1,71 +0,0 @@ -import z from "zod"; -import { VAULTS_API_URL } from "../constants"; -import { VaultHistoricalDataActionSchema } from "../schemas"; -import { ApiError } from "./types"; -import { createSearchParams } from "../utils"; - -type ApyData = { - timestamp: number; - blockNumber: number; - apy: { - base: number; - rewards: number; - total: number; - }; -}; - -type TvlData = { - timestamp: number; - blockNumber: number; - tvlDetails: { - tvlUsd: number; - }; -}; - -/** - * Fetch historical data for a vault - * - * @param args - The arguments for the action - * @param apiKey - The API key to use for the request - * @returns The historical data for the vault - */ -export async function fetchVaultHistoricalData( - args: z.infer, - apiKey: string, -) { - const params = createSearchParams({ - interval: args.apyRange ?? "7day", - }); - const timestamp = new Date(args.date).getTime() / 1000; - const [tvlResponse, apyResponse] = await Promise.all([ - fetch( - `${VAULTS_API_URL}/vaults/${args.network}/${args.vaultAddress}/historical-tvl/${timestamp}?${params}`, - { - method: "GET", - headers: { - "x-api-key": apiKey, - }, - }, - ), - fetch( - `${VAULTS_API_URL}/vaults/${args.network}/${args.vaultAddress}/historical-apy/${timestamp}?${params}`, - { - method: "GET", - headers: { - "x-api-key": apiKey, - }, - }, - ), - ]); - const [apy, tvl] = await Promise.all([ - apyResponse.json() as Promise, - tvlResponse.json() as Promise, - ]); - if ("error" in apy) return apy; - if ("error" in tvl) return tvl; - - return { - apy, - tvl, - }; -} diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/api/types.ts b/typescript/agentkit/src/action-providers/vaultsfyi/api/types.ts deleted file mode 100644 index 816112b5a..000000000 --- a/typescript/agentkit/src/action-providers/vaultsfyi/api/types.ts +++ /dev/null @@ -1,36 +0,0 @@ -export type ApiError = { - statusCode: number; - error: string; - message: string; -}; - -export type Balances = { - [network: string]: { - address: string; - name: string; - symbol: string; - balance: string; - decimals: number; - }[]; -}; - -export type Positions = { - [network: string]: { - vaultName: string; - vaultAddress: string; - asset: { - assetAddress: string; - name: string; - symbol: string; - decimals: number; - }; - balanceNative: string; - balanceLp: string; - unclaimedUsd: string; - apy: { - base: number; - rewards: number; - total: number; - }; - }[]; -}; diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/api/vaults.ts b/typescript/agentkit/src/action-providers/vaultsfyi/api/vaults.ts deleted file mode 100644 index 0684ac4a2..000000000 --- a/typescript/agentkit/src/action-providers/vaultsfyi/api/vaults.ts +++ /dev/null @@ -1,115 +0,0 @@ -import z from "zod"; -import { VaultDetailsActionSchema, VaultsActionSchema } from "../schemas"; -import { createSearchParams } from "../utils"; -import { VAULTS_API_URL } from "../constants"; -import { ApiError } from "./types"; - -type ApyData = { - "1day": number; - "7day": number; - "30day": number; -}; - -export type ApiVault = { - name: string; - address: string; - network: string; - protocol: string; - isTransactional: boolean; - tvlDetails: { - tvlUsd: string; - }; - token: { - name: string; - assetAddress: string; - symbol: string; - decimals: number; - }; - apy: { - base: ApyData; - rewards: ApyData; - total: ApyData; - }; - numberOfHolders: number; - rewards: { - apy: ApyData; - asset: { - name: string; - symbol: string; - assetAddress: string; - decimals: number; - }; - }[]; - description: string; - additionalIncentives: string; - score: { - vaultScore: number; - vaultTvlScore: number; - protocolTvlScore: number; - holderScore: number; - networkScore: number; - assetScore: number; - }; -}; - -type ApiResult = { - data: ApiVault[]; - next_page: string | undefined; -}; - -/** - * Fetches a list of vaults from the vaultsfyi API. - * - * @param args - The action parameters - * @param apiKey - The vaultsfyi API key - * @returns The list of vaults - */ -export async function fetchVaults( - args: z.infer, - apiKey: string, -): Promise { - const vaults: ApiVault[] = []; - - const params = createSearchParams({ - per_page: 250, - token: args.token, - network: args.network, - tvl_min: args.minTvl ?? 100_000, - transactionalOnly: true, - }); - for (let i = 0; i < 10; i++) { - const response = await fetch(`${VAULTS_API_URL}/detailed/vaults?${params}`, { - method: "GET", - headers: { - "x-api-key": apiKey, - }, - }); - const data = (await response.json()) as ApiResult | ApiError; - if ("error" in data) return data; - - vaults.push(...data.data); - - if (!data.next_page) break; - else params.set("page", data.next_page); - } - - return vaults; -} - -/** - * Fetches the details of a specific vault from the vaultsfyi API. - * - * @param args - The action parameters - * @param apiKey - The vaultsfyi API key - * @returns The vault details - */ -export async function fetchVault(args: z.infer, apiKey: string) { - const response = await fetch(`${VAULTS_API_URL}/vaults/${args.network}/${args.vaultAddress}`, { - method: "GET", - headers: { - "x-api-key": apiKey, - }, - }); - const data = (await response.json()) as ApiVault | ApiError; - return data; -} diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/constants.ts b/typescript/agentkit/src/action-providers/vaultsfyi/constants.ts index f573503ce..01ef6aa9f 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/constants.ts +++ b/typescript/agentkit/src/action-providers/vaultsfyi/constants.ts @@ -1,12 +1,16 @@ -export const VAULTS_API_URL = "https://api.vaults.fyi/v1"; -export const VAULTSFYI_SUPPORTED_CHAINS = { - 1: "mainnet", - 42161: "arbitrum", - 10: "optimism", - 137: "polygon", - 100: "gnosis", - 8453: "base", - 130: "unichain", - 1923: "swellchain", - 42220: "celo", -} as const; +import { SUPPORTED_NETWORKS } from "@vaultsfyi/sdk"; +import * as viemChains from "viem/chains"; + +export const SUPPORTED_CHAIN_IDS = SUPPORTED_NETWORKS.map(network => + viemChains[network]?.id.toString(), +).filter(id => id !== undefined) as string[]; + +/** + * Get the network name from a chain id + * + * @param chainId - The chain id + * @returns The network name + */ +export function getNetworkNameFromChainId(chainId: string): string | undefined { + return SUPPORTED_NETWORKS.find(network => viemChains[network]?.id.toString() === chainId); +} diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/schemas.ts b/typescript/agentkit/src/action-providers/vaultsfyi/schemas.ts index fb0fe36e7..4e8469230 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/schemas.ts +++ b/typescript/agentkit/src/action-providers/vaultsfyi/schemas.ts @@ -1,5 +1,5 @@ import { z } from "zod"; -import { VAULTSFYI_SUPPORTED_CHAINS } from "./constants"; +import { SUPPORTED_NETWORKS } from "@vaultsfyi/sdk"; /** * Action schemas for the vaultsfyi action provider. @@ -8,42 +8,37 @@ import { VAULTSFYI_SUPPORTED_CHAINS } from "./constants"; * rules for action parameters in the vaultsfyi action provider. */ -const NetworkSchema = z.enum(Object.values(VAULTSFYI_SUPPORTED_CHAINS) as [string, ...string[]]); +const NetworkSchema = z.enum(SUPPORTED_NETWORKS); /** * Vaults list action schema. */ export const VaultsActionSchema = z.object({ - token: z - .string() - .transform(val => (val === "" ? undefined : val)) + allowedAssets: z + .array(z.string()) .optional() - .describe("Optional: Name or symbol of the token to filter vaults by"), - protocol: z - .string() - .transform(val => (val === "" ? undefined : val)) + .describe("Optional: Symbols of the assets to filter vaults by"), + allowedProtocols: z + .array(z.string()) .optional() - .describe("Optional: Protocol to filter vaults by"), - network: NetworkSchema.or(z.enum(["", "all"])) + .describe("Optional: Protocols to filter vaults by. Leave undefined to include all protocols."), + allowedNetworks: z + .array(NetworkSchema) .optional() - .transform(val => (val === "" || val === "all" ? undefined : val)) - .describe( - "Optional: Network name to filter vaults by. Supported networks: mainnet, arbitrum, optimism, polygon, base, gnosis, unichain", - ), - minTvl: z.number().optional().describe("Optional: Minimum TVL to filter vaults by"), + .describe("Optional: Networks to filter vaults by. Leave undefined to include all networks."), + minTvl: z.coerce.number().optional().describe("Optional: Minimum TVL to filter vaults by"), sort: z .object({ - field: z.enum(["tvl", "apy", "name"]).optional().describe("Sort field"), + field: z.enum(["tvl", "apy1day", "apy7day", "apy30day"]).optional().describe("Sort field"), direction: z.enum(["asc", "desc"]).optional().describe("Sort direction"), }) .optional() .describe("Sort options"), - apyRange: z - .enum(["1day", "7day", "30day"]) + perPage: z.coerce + .number() .optional() - .describe("Optional: APY moving average range (default: 7day)"), - take: z.number().optional().describe("Optional: Limit the number of results"), - page: z.number().optional().describe("Optional: Page number"), + .describe("Optional: Number of results per page (default: 5)"), + page: z.coerce.number().optional().describe("Optional: Page number starting from 0 (default: 0)"), }); /** @@ -52,35 +47,78 @@ export const VaultsActionSchema = z.object({ export const VaultDetailsActionSchema = z.object({ vaultAddress: z.string().describe("The address of the vault to fetch details for"), network: NetworkSchema.describe("The network of the vault"), - apyRange: z - .enum(["1day", "7day", "30day"]) - .optional() - .describe("Optional: APY moving average range (default: 7day)"), }); export const VaultHistoricalDataActionSchema = z.object({ vaultAddress: z.string().describe("The address of the vault to fetch historical data for"), network: NetworkSchema.describe("The network of the vault"), - date: z.string().datetime().describe("The date to fetch historical data for"), - apyRange: z - .enum(["1day", "7day", "30day"]) - .optional() - .describe("Optional: APY moving average range (default: 7day)"), + fromDate: z.string().datetime().describe("The date to fetch historical data from"), + toDate: z.string().datetime().describe("The date to fetch historical data to"), + granularity: z.enum(["1hour", "1day", "1week"]).describe("The granularity of the data"), + apyInterval: z.enum(["1day", "7day", "30day"]).describe("The interval of the apy data"), + page: z.coerce.number().optional().describe("The page number to fetch"), + perPage: z.coerce.number().optional().describe("The number of results per page"), }); + /** * Base transaction params schema. */ -const TransactionActionSchema = z.object({ +export const transactionContextActionSchema = z.object({ vaultAddress: z.string().describe("The address of the vault to interact with"), - assetAddress: z.string().describe("The address of the vault's underlying token"), network: NetworkSchema.describe("The network of the vault"), - amount: z.number().describe("The amount of assets to use"), }); -export const depositActionSchema = TransactionActionSchema; -export const redeemActionSchema = TransactionActionSchema.extend({ - all: z.boolean().optional().describe("Should redeem all assets"), +export const executeStepActionSchema = transactionContextActionSchema.extend({ + action: z + .enum([ + "deposit", + "redeem", + "request-redeem", + "request-deposit", + "claim-redeem", + "claim-deposit", + "claim-rewards", + "start-redeem-cooldown", + ]) + .describe("The action to execute"), + assetAddress: z.string().describe("The address of the vault's underlying token"), + amount: z.coerce + .bigint() + .or(z.literal("all")) + .optional() + .describe("The amount of assets to use as a number with decimals"), +}); + +export const claimRewardsActionSchema = z.object({ + claimIds: z.array(z.string()).describe("The ids of the rewards to claim"), +}); + +export const benchmarkActionSchema = z.object({ + network: NetworkSchema.describe("The network to retrieve benchmark data for"), + benchmarkCode: z.enum(["eth", "usd"]).describe("The benchmark code to retrieve data for"), }); -export const claimActionSchema = TransactionActionSchema.omit({ - amount: true, + +export const historicalBenchmarkActionSchema = benchmarkActionSchema.extend({ + fromDate: z.string().datetime().describe("The date to fetch historical data from"), + toDate: z.string().datetime().describe("The date to fetch historical data to"), + page: z.coerce.number().optional().describe("The page number to fetch"), + perPage: z.coerce.number().optional().describe("The number of results per page"), +}); + +export const totalVaultReturnsActionSchema = z.object({ + vaultAddress: z.string().describe("The address of the vault to fetch total returns for"), + userAddress: z + .string() + .optional() + .describe("The address of the user to fetch total returns for. (default: user's address)"), + network: NetworkSchema.describe("The network of the vault"), +}); + +export const userEventsActionSchema = z.object({ + vaultAddress: z.string().describe("The address of the vault to fetch user events for"), + userAddress: z + .string() + .optional() + .describe("The address of the user to fetch user events for. (default: user's address)"), + network: NetworkSchema.describe("The network of the vault"), }); diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/sdk.ts b/typescript/agentkit/src/action-providers/vaultsfyi/sdk.ts new file mode 100644 index 000000000..e6e2bcf65 --- /dev/null +++ b/typescript/agentkit/src/action-providers/vaultsfyi/sdk.ts @@ -0,0 +1,13 @@ +import { VaultsSdk } from "@vaultsfyi/sdk"; + +/** + * Get the vaults.fyi SDK + * + * @param apiKey - The API key for the vaults.fyi API + * @returns The vaults.fyi SDK client + */ +export function getVaultsSdk(apiKey: string) { + return new VaultsSdk({ + apiKey, + }); +} diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/utils.ts b/typescript/agentkit/src/action-providers/vaultsfyi/utils.ts index 953ad1992..b37054f25 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/utils.ts +++ b/typescript/agentkit/src/action-providers/vaultsfyi/utils.ts @@ -1,7 +1,6 @@ -import { Address, erc20Abi } from "viem"; +import { Address, Hex } from "viem"; import { EvmWalletProvider } from "../../wallet-providers"; -import { ApiVault } from "./api/vaults"; -import { Actions } from "./api/actions"; +import { VaultsSdk } from "@vaultsfyi/sdk"; /** * Get the link to the vaults.fyi page for a vault @@ -9,12 +8,8 @@ import { Actions } from "./api/actions"; * @param vault - The vault * @returns The link to the vaults.fyi page */ -export function getVaultsLink(vault: ApiVault): string { - if (vault.isTransactional) { - return `https://app.vaults.fyi/opportunity/${vault.network}/${vault.address}`; - } else { - return `https://analytics.vaults.fyi/vaults/${vault.network}/${vault.address}`; - } +export function getVaultsLink(vault: Awaited>): string { + return `https://app.vaults.fyi/opportunity/${vault.network.name}/${vault.address}`; } /** @@ -24,105 +19,85 @@ export function getVaultsLink(vault: ApiVault): string { * @param actions - The list of actions to execute * @returns nothing */ -export async function executeActions(wallet: EvmWalletProvider, actions: Actions) { +export async function executeActions( + wallet: EvmWalletProvider, + actions: Awaited>, +) { for (let i = actions.currentActionIndex; i < actions.actions.length; i++) { const action = actions.actions[i]; const txHash = await wallet.sendTransaction({ - ...action.tx, + to: action.tx.to as Address, + data: action.tx.data as Hex, value: action.tx.value ? BigInt(action.tx.value) : undefined, }); await wallet.waitForTransactionReceipt(txHash); } } -/** - * Create a URLSearchParams object from an object - * - * @param obj - The object to convert - * @returns The URLSearchParams object - */ -export function createSearchParams( - obj: Record, -): URLSearchParams { - const params = new URLSearchParams(); - for (const key in obj) { - if (obj[key] !== undefined) { - params.append(key, obj[key].toString()); - } - } - return params; -} +type Apy = { + base: number; + reward: number; + total: number; +}; + +type ApyObject = { + "1day": Apy; + "7day": Apy; + "30day": Apy; + "1hour"?: Apy; +}; /** - * Parse an asset amount with decimals + * Transform the apy object to a more readable format * - * @param wallet - The wallet provider - * @param assetAddress - The address of the asset - * @param amount - The amount to parse - * @returns The parsed amount + * @param apy - The apy + * @returns The transformed apy */ -export async function parseAssetAmount( - wallet: EvmWalletProvider, - assetAddress: string, - amount: number, -): Promise { - const decimals = await wallet.readContract({ - address: assetAddress as Address, - abi: erc20Abi, - functionName: "decimals", - }); - return Math.floor(amount * 10 ** decimals); +export function transformApyObject(apy: ApyObject) { + return (["1day", "7day", "30day", "1hour"] as const).reduce( + (acc, curr) => { + if (!(curr in apy)) { + return acc; + } + acc[curr] = transformApy(apy[curr]!); + return acc; + }, + {} as Record< + string, + { + base: string; + reward: string; + total: string; + } + >, + ); } /** - * Transform a vault from the API to a format that can be used by the agent + * Transform the apy to a more readable format * - * @param vault - The vault to transform - * @param apyRange - The APY range to use - * @returns The transformed vault + * @param apy - The apy + * @returns The transformed apy */ -export function transformVault(vault: ApiVault, apyRange: "1day" | "7day" | "30day") { +export function transformApy(apy: Apy) { return { - name: vault.name, - address: vault.address, - network: vault.network, - protocol: vault.protocol, - tvlInUsd: Number(vault.tvlDetails.tvlUsd), - numberOfHolders: vault.numberOfHolders, - apy: { - base: vault.apy.base[apyRange] / 100, - rewards: vault.apy.rewards?.[apyRange] ? vault.apy.rewards[apyRange] / 100 : undefined, - total: vault.apy.total[apyRange] / 100, - }, - token: { - address: vault.token.assetAddress, - name: vault.token.name, - symbol: vault.token.symbol, - }, - vaultsFyiScore: vault.score.vaultScore, - link: getVaultsLink(vault), + base: `${(apy.base * 100).toFixed(2)}%`, + reward: `${(apy.reward * 100).toFixed(2)}%`, + total: `${(apy.total * 100).toFixed(2)}%`, }; } /** - * Transform a detailed vault from the API to a format that can be used by the agent + * Transform the vault to a more readable format * - * @param vault - The vault to transform - * @param apyRange - The APY range to use + * @param vault - The vault * @returns The transformed vault */ -export function transformDetailedVault(vault: ApiVault, apyRange: "1day" | "7day" | "30day") { +export function transformVault(vault: Awaited>) { return { - ...transformVault(vault, apyRange), - rewards: vault.rewards.map(reward => ({ - apy: reward.apy[apyRange] / 100, - asset: { - address: reward.asset.assetAddress, - name: reward.asset.name, - symbol: reward.asset.symbol, - }, - })), - description: vault.description, - additionalIncentives: vault.additionalIncentives, + ...vault, + apy: transformApyObject(vault.apy), + link: getVaultsLink(vault), + lastUpdateTimestamp: new Date(vault.lastUpdateTimestamp * 1000).toISOString(), }; } diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.test.ts b/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.test.ts index d75283a66..b5e770c4c 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.test.ts +++ b/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.test.ts @@ -1,7 +1,7 @@ import { VaultsfyiActionProvider } from "./vaultsfyiActionProvider"; import { Network } from "../../network"; import { EvmWalletProvider } from "../../wallet-providers"; -import { VAULTSFYI_SUPPORTED_CHAINS } from "./constants"; +import { SUPPORTED_CHAIN_IDS } from "./constants"; const mockFetchResult = (status: number, data: object) => { return { @@ -13,46 +13,109 @@ const mockFetchResult = (status: number, data: object) => { const mockVault = (num: number) => ({ apiResult: { - address: `0x${num.toString(16).padStart(40, "0")}`, - network: `network-${num}`, + address: "0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + network: { + name: "base", + chainId: 8453, + networkCaip: "eip155:8453", + }, + asset: { + address: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", + assetCaip: "eip155:8453/erc20:0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", + name: "USD Coin", + symbol: "USDC", + decimals: 6, + assetLogo: "https://images.vaults.fyi/tokens/usdc.png", + assetPriceInUsd: "0.99983592", + assetGroup: "USD", + }, + isTransactional: true, + isAppFeatured: true, name: `vault-${num}`, - protocol: `protocol-${num}`, - token: { - name: `token-${num}`, - assetAddress: `0x${num.toString(16).padStart(40, "0")}`, - symbol: `T${num}`, - decimals: 18, + protocol: { + name: "40acres", + product: "", + version: "", + protocolLogo: "https://images.vaults.fyi/protocols/40acres.png", }, - tvlDetails: { - tvlUsd: num.toString(), + lendUrl: "https://app.vaults.fyi/opportunity/base/0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + description: `Description for vault-${num}`, + protocolVaultUrl: "https://www.40acres.finance/", + tags: ["Lending"], + holdersData: { + totalCount: num, + totalBalance: (num * 1000000).toString(), + topHolders: [ + { + address: "0x1d59868D7767d703929393bDaB313302840f533c", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x1c6586f4895A569d9EFac5ABd231b79E0D47cAAD", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x011b0a055E02425461A1ae95B30F483c4fF05bE7", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x9551EeC2a31025D582Be358E05D88a9c95cAD86E", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x10076ed296571cE4Fde5b1FDF0eB9014a880e47B", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x9e33Fef28A75303B4FEB7b4c713c27Fed2AC78DD", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x166B9a0390474C455115dFb64579D1D79286588F", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x318962D28813fe14B9b6265fE2dAFB241C7F7777", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x22e4bB70905c7Ad93B65BC9Bd5B1b06e67378124", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x57609a91CC6eA77D9805137656A9308F5bF52f23", + lpTokenBalance: (num * 1000000).toString(), + }, + ], }, apy: { - base: { - "7day": num * 100, + "1day": { + base: num, + reward: num, + total: num, }, - rewards: { - "7day": num * 100, + "7day": { + base: num, + reward: num, + total: num, }, - total: { - "7day": num * 100, + "30day": { + base: num, + reward: num, + total: num, }, - }, - numberOfHolders: num, - rewards: [ - { - apy: { - "7day": num * 100, - }, - asset: { - name: `reward-token-${num}`, - symbol: `RT${num}`, - assetAddress: `0x${num.toString(16).padStart(40, "0")}`, - decimals: 18, - }, + "1hour": { + base: num, + reward: num, + total: num, }, - ], - description: `Description for vault-${num}`, - additionalIncentives: `Incentives for vault-${num}`, + }, + tvl: { + usd: num.toString(), + native: (num * 1000000).toString(), + }, + lastUpdateTimestamp: 1764259200, + rewards: [], score: { vaultScore: num, vaultTvlScore: num, @@ -61,27 +124,146 @@ const mockVault = (num: number) => ({ networkScore: num, assetScore: num, }, - isTransactional: true, + lpToken: { + address: "0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + tokenCaip: "eip155:8453/erc20:0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + name: `Vault-${num}`, + symbol: `VAULT-${num}`, + decimals: 6, + }, + transactionalProperties: { + depositStepsType: "instant", + redeemStepsType: "instant", + rewardsSupported: false, + }, + warnings: [], }, transformedResult: { + address: "0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + network: { + name: "base", + chainId: 8453, + networkCaip: "eip155:8453", + }, + asset: { + address: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", + assetCaip: "eip155:8453/erc20:0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", + name: "USD Coin", + symbol: "USDC", + decimals: 6, + assetLogo: "https://images.vaults.fyi/tokens/usdc.png", + assetPriceInUsd: "0.99983592", + assetGroup: "USD", + }, + isTransactional: true, + isAppFeatured: true, name: `vault-${num}`, - address: `0x${num.toString(16).padStart(40, "0")}`, - network: `network-${num}`, - protocol: `protocol-${num}`, - tvlInUsd: num, - token: { - name: `token-${num}`, - address: `0x${num.toString(16).padStart(40, "0")}`, - symbol: `T${num}`, + protocol: { + name: "40acres", + product: "", + version: "", + protocolLogo: "https://images.vaults.fyi/protocols/40acres.png", + }, + lendUrl: "https://app.vaults.fyi/opportunity/base/0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + description: `Description for vault-${num}`, + protocolVaultUrl: "https://www.40acres.finance/", + tags: ["Lending"], + holdersData: { + totalCount: num, + totalBalance: (num * 1000000).toString(), + topHolders: [ + { + address: "0x1d59868D7767d703929393bDaB313302840f533c", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x1c6586f4895A569d9EFac5ABd231b79E0D47cAAD", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x011b0a055E02425461A1ae95B30F483c4fF05bE7", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x9551EeC2a31025D582Be358E05D88a9c95cAD86E", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x10076ed296571cE4Fde5b1FDF0eB9014a880e47B", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x9e33Fef28A75303B4FEB7b4c713c27Fed2AC78DD", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x166B9a0390474C455115dFb64579D1D79286588F", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x318962D28813fe14B9b6265fE2dAFB241C7F7777", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x22e4bB70905c7Ad93B65BC9Bd5B1b06e67378124", + lpTokenBalance: (num * 1000000).toString(), + }, + { + address: "0x57609a91CC6eA77D9805137656A9308F5bF52f23", + lpTokenBalance: (num * 1000000).toString(), + }, + ], }, apy: { - base: num, - rewards: num, - total: num, + "1day": { + base: `${(num * 100).toFixed(2)}%`, + reward: `${(num * 100).toFixed(2)}%`, + total: `${(num * 100).toFixed(2)}%`, + }, + "7day": { + base: `${(num * 100).toFixed(2)}%`, + reward: `${(num * 100).toFixed(2)}%`, + total: `${(num * 100).toFixed(2)}%`, + }, + "30day": { + base: `${(num * 100).toFixed(2)}%`, + reward: `${(num * 100).toFixed(2)}%`, + total: `${(num * 100).toFixed(2)}%`, + }, + "1hour": { + base: `${(num * 100).toFixed(2)}%`, + reward: `${(num * 100).toFixed(2)}%`, + total: `${(num * 100).toFixed(2)}%`, + }, + }, + tvl: { + usd: num.toString(), + native: (num * 1000000).toString(), + }, + lastUpdateTimestamp: new Date(1764259200 * 1000).toISOString(), + rewards: [], + score: { + vaultScore: num, + vaultTvlScore: num, + protocolTvlScore: num, + holderScore: num, + networkScore: num, + assetScore: num, + }, + lpToken: { + address: "0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + tokenCaip: "eip155:8453/erc20:0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5", + name: `Vault-${num}`, + symbol: `VAULT-${num}`, + decimals: 6, + }, + transactionalProperties: { + depositStepsType: "instant", + redeemStepsType: "instant", + rewardsSupported: false, }, - vaultsFyiScore: num, - numberOfHolders: num, - link: `https://app.vaults.fyi/opportunity/network-${num}/0x${num.toString(16).padStart(40, "0")}`, + warnings: [], + link: `https://app.vaults.fyi/opportunity/base/0xB99B6dF96d4d5448cC0a5B3e0ef7896df9507Cf5`, }, }); @@ -119,11 +301,11 @@ describe("VaultsfyiActionProvider", () => { describe("network support", () => { it("should support all vaultsfyi networks", () => { - Object.keys(VAULTSFYI_SUPPORTED_CHAINS).forEach(network => { + SUPPORTED_CHAIN_IDS.forEach(chainId => { expect( provider.supportsNetwork({ protocolFamily: "evm", - chainId: network, + chainId: chainId, }), ).toBe(true); }); @@ -150,81 +332,7 @@ describe("VaultsfyiActionProvider", () => { const args = {}; const result = await provider.vaults(mockWalletProvider, args); expect(JSON.parse(result)).toStrictEqual({ - totalResults: 1, - nextPage: false, - results: [mockedVault.transformedResult], - }); - }); - - it("should filter by protocol", async () => { - const mockedVaults = [mockVault(1), mockVault(2)]; - mockedFetch.mockResolvedValue( - mockFetchResult(200, { data: mockedVaults.map(v => v.apiResult) }), - ); - const args = { protocol: "protocol-1" }; - const result = await provider.vaults(mockWalletProvider, args); - expect(JSON.parse(result)).toStrictEqual({ - totalResults: 1, - nextPage: false, - results: [mockedVaults[0].transformedResult], - }); - }); - - it("should take a limit", async () => { - const mockedVaults = [mockVault(1), mockVault(2)]; - mockedFetch.mockResolvedValue( - mockFetchResult(200, { data: mockedVaults.map(v => v.apiResult) }), - ); - const args = { take: 1 }; - const result = await provider.vaults(mockWalletProvider, args); - expect(JSON.parse(result)).toStrictEqual({ - totalResults: 2, - nextPage: true, - results: [mockedVaults[0].transformedResult], - }); - }); - - describe("sorting", () => { - it("should sort by TVL", async () => { - const mockedVaults = [mockVault(2), mockVault(1)]; - mockedFetch.mockResolvedValue( - mockFetchResult(200, { data: mockedVaults.map(v => v.apiResult) }), - ); - const args = { sort: { field: "tvl", direction: "asc" } } as const; - const result = await provider.vaults(mockWalletProvider, args); - expect(JSON.parse(result)).toStrictEqual({ - totalResults: 2, - nextPage: false, - results: [mockedVaults[1].transformedResult, mockedVaults[0].transformedResult], - }); - }); - - it("should sort by APY", async () => { - const mockedVaults = [mockVault(2), mockVault(1)]; - mockedFetch.mockResolvedValue( - mockFetchResult(200, { data: mockedVaults.map(v => v.apiResult) }), - ); - const args = { sort: { field: "apy", direction: "asc" } } as const; - const result = await provider.vaults(mockWalletProvider, args); - expect(JSON.parse(result)).toStrictEqual({ - totalResults: 2, - nextPage: false, - results: [mockedVaults[1].transformedResult, mockedVaults[0].transformedResult], - }); - }); - - it("should sort by name by default", async () => { - const mockedVaults = [mockVault(2), mockVault(1)]; - mockedFetch.mockResolvedValue( - mockFetchResult(200, { data: mockedVaults.map(v => v.apiResult) }), - ); - const args = {}; - const result = await provider.vaults(mockWalletProvider, args); - expect(JSON.parse(result)).toStrictEqual({ - totalResults: 2, - nextPage: false, - results: [mockedVaults[1].transformedResult, mockedVaults[0].transformedResult], - }); + data: [mockedVault.transformedResult], }); }); @@ -234,12 +342,12 @@ describe("VaultsfyiActionProvider", () => { ); const args = {}; expect(await provider.vaults(mockWalletProvider, args)).toBe( - "Failed to fetch vaults: Internal Server Error, some more info", + "Failed to fetch vaults: some more info", ); }); }); - describe("deposit action", () => { + describe("execute_step action", () => { it("should execute deposit", async () => { mockedFetch.mockResolvedValue( mockFetchResult(200, { @@ -261,15 +369,15 @@ describe("VaultsfyiActionProvider", () => { vaultAddress: "0x123", assetAddress: "0x456", network: "mainnet", - amount: 1, + amount: 1n, + action: "deposit", } as const; - const response = await provider.deposit(mockWalletProvider, args); - expect(response).toBe("Deposit successful"); + const response = await provider.executeStep(mockWalletProvider, args); + expect(response).toBe("Successfully executed deposit step"); expect(mockWalletProvider.sendTransaction).toHaveBeenCalledWith({ to: "0x123", data: "0x456", value: 1n, - chainId: 1, }); expect(mockWalletProvider.waitForTransactionReceipt).toHaveBeenCalledWith(MOCK_TX_HASH); }); @@ -304,72 +412,20 @@ describe("VaultsfyiActionProvider", () => { vaultAddress: "0x123", assetAddress: "0x456", network: "mainnet", - amount: 1, + amount: 1n, + action: "deposit", } as const; - const response = await provider.deposit(mockWalletProvider, args); - expect(response).toBe("Deposit successful"); + const response = await provider.executeStep(mockWalletProvider, args); + expect(response).toBe("Successfully executed deposit step"); expect(mockWalletProvider.sendTransaction).toHaveBeenCalledWith({ to: "0x123", data: "0x456", value: 1n, - chainId: 1, }); expect(mockWalletProvider.sendTransaction).toHaveBeenCalledWith({ to: "0x789", data: "0xabc", value: 2n, - chainId: 1, - }); - expect(mockWalletProvider.waitForTransactionReceipt).toHaveBeenCalledWith(MOCK_TX_HASH); - }); - - it("should return an error if the API request fails", async () => { - mockedFetch.mockResolvedValue( - mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), - ); - const args = { - vaultAddress: "0x123", - assetAddress: "0x456", - network: "mainnet", - amount: 1, - } as const; - expect(await provider.deposit(mockWalletProvider, args)).toBe( - "Failed to fetch deposit transactions: Internal Server Error, some more info", - ); - }); - }); - - describe("redeem action", () => { - it("should execute redeem", async () => { - mockedFetch.mockResolvedValue( - mockFetchResult(200, { - currentActionIndex: 0, - actions: [ - { - tx: { - to: "0x123", - data: "0x456", - value: "1", - chainId: 1, - }, - description: "Redeem from vault", - }, - ], - }), - ); - const args = { - vaultAddress: "0x123", - assetAddress: "0x456", - network: "mainnet", - amount: 1, - } as const; - const response = await provider.redeem(mockWalletProvider, args); - expect(response).toBe("Redeem successful"); - expect(mockWalletProvider.sendTransaction).toHaveBeenCalledWith({ - to: "0x123", - data: "0x456", - value: 1n, - chainId: 1, }); expect(mockWalletProvider.waitForTransactionReceipt).toHaveBeenCalledWith(MOCK_TX_HASH); }); @@ -382,67 +438,17 @@ describe("VaultsfyiActionProvider", () => { vaultAddress: "0x123", assetAddress: "0x456", network: "mainnet", - amount: 1, + amount: 1n, + action: "deposit", } as const; - expect(await provider.redeem(mockWalletProvider, args)).toBe( - "Failed to fetch redeem transactions: Internal Server Error, some more info", + expect(await provider.executeStep(mockWalletProvider, args)).toBe( + "Failed to execute step: some more info", ); }); }); - describe("claim rewards action", () => { - it("should execute claim rewards", async () => { - mockedFetch.mockResolvedValue( - mockFetchResult(200, { - currentActionIndex: 0, - actions: [ - { - tx: { - to: "0x123", - data: "0x456", - value: "1", - chainId: 1, - }, - description: "Claim rewards from vault", - }, - ], - }), - ); - const args = { - vaultAddress: "0x123", - assetAddress: "0x456", - network: "mainnet", - amount: 1, - } as const; - const response = await provider.claim(mockWalletProvider, args); - expect(response).toBe("Claim successful"); - expect(mockWalletProvider.sendTransaction).toHaveBeenCalledWith({ - to: "0x123", - data: "0x456", - value: 1n, - chainId: 1, - }); - expect(mockWalletProvider.waitForTransactionReceipt).toHaveBeenCalledWith(MOCK_TX_HASH); - }); - - it("should return an error if the API request fails", async () => { - mockedFetch.mockResolvedValue( - mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), - ); - const args = { - vaultAddress: "0x123", - assetAddress: "0x456", - network: "mainnet", - amount: 1, - } as const; - expect(await provider.claim(mockWalletProvider, args)).toBe( - "Failed to fetch claim transactions: Internal Server Error, some more info", - ); - }); - }); - - describe("wallet balances action", () => { - it("should strip and transform balances correctly", async () => { + describe("user_idle_assets action", () => { + it("should return the response", async () => { mockedFetch.mockResolvedValue( mockFetchResult(200, { mainnet: [ @@ -452,19 +458,19 @@ describe("VaultsfyiActionProvider", () => { symbol: "T1", balance: (10 ** 18).toString(), decimals: 18, - somethingElse: "should be stripped", }, ], }), ); - const response = await provider.balances(mockWalletProvider); + const response = await provider.idleAssets(mockWalletProvider); expect(JSON.parse(response)).toStrictEqual({ mainnet: [ { address: "0x123", name: "token-1", symbol: "T1", - balance: 1, + balance: (10 ** 18).toString(), + decimals: 18, }, ], }); @@ -474,17 +480,17 @@ describe("VaultsfyiActionProvider", () => { mockedFetch.mockResolvedValue( mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), ); - expect(await provider.balances(mockWalletProvider)).toBe( - "Failed to fetch wallet balances: Internal Server Error, some more info", + expect(await provider.idleAssets(mockWalletProvider)).toBe( + "Failed to fetch idle assets: some more info", ); }); }); describe("wallet positions action", () => { - it("should strip and transform positions correctly", async () => { + it("should transform the response correctly", async () => { mockedFetch.mockResolvedValue( mockFetchResult(200, { - mainnet: [ + data: [ { vaultName: "vault-1", vaultAddress: "0x123", @@ -498,9 +504,9 @@ describe("VaultsfyiActionProvider", () => { balanceLp: (10 ** 18).toString(), unclaimedUsd: "100", apy: { - base: 100, - rewards: 100, - total: 100, + base: 0.1, + reward: 0.1, + total: 0.1, }, }, ], @@ -508,22 +514,23 @@ describe("VaultsfyiActionProvider", () => { ); const response = await provider.positions(mockWalletProvider); expect(JSON.parse(response)).toStrictEqual({ - mainnet: [ + data: [ { - name: "vault-1", + vaultName: "vault-1", vaultAddress: "0x123", asset: { - address: "0x456", + assetAddress: "0x456", name: "token-1", symbol: "T1", + decimals: 18, }, - underlyingTokenBalance: 1, - lpTokenBalance: 1, - unclaimedRewards: true, + balanceNative: (10 ** 18).toString(), + balanceLp: (10 ** 18).toString(), + unclaimedUsd: "100", apy: { - base: 1, - rewards: 1, - total: 1, + base: "10.00%", + reward: "10.00%", + total: "10.00%", }, }, ], @@ -535,20 +542,20 @@ describe("VaultsfyiActionProvider", () => { mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), ); expect(await provider.positions(mockWalletProvider)).toBe( - "Failed to fetch positions: Internal Server Error, some more info", + "Failed to fetch positions: some more info", ); }); }); - describe("vault_details action", () => { - it("should transform vault details correctly", async () => { + describe("detailed_vault action", () => { + it("should return the response", async () => { const detailedVault = mockVault(1); mockedFetch.mockResolvedValue(mockFetchResult(200, detailedVault.apiResult)); const args = { vaultAddress: "0x123456", - network: "mainnet", + network: "mainnet" as const, }; const result = await provider.vaultDetails(mockWalletProvider, args); @@ -556,18 +563,6 @@ describe("VaultsfyiActionProvider", () => { expect(parsedResult).toStrictEqual({ ...detailedVault.transformedResult, - description: detailedVault.apiResult.description, - additionalIncentives: detailedVault.apiResult.additionalIncentives, - rewards: [ - { - apy: detailedVault.apiResult.rewards[0].apy["7day"] / 100, - asset: { - name: detailedVault.apiResult.rewards[0].asset.name, - symbol: detailedVault.apiResult.rewards[0].asset.symbol, - address: detailedVault.apiResult.rewards[0].asset.assetAddress, - }, - }, - ], }); }); @@ -578,136 +573,335 @@ describe("VaultsfyiActionProvider", () => { const args = { vaultAddress: "0x123456", - network: "mainnet", + network: "mainnet" as const, }; expect(await provider.vaultDetails(mockWalletProvider, args)).toBe( - "Failed to fetch vault: Internal Server Error, some more info", + "Failed to fetch vault: some more info", ); }); }); describe("vault_historical_data action", () => { - it("should fetch and transform historical data correctly", async () => { - // Mock API responses for both TVL and APY data - const mockApyData = { - timestamp: 1704067200, // Jan 1, 2024 - blockNumber: 12345678, - apy: { - base: 500, - rewards: 300, - total: 800, - }, + it("transforms the response correctly", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + data: [ + { + timestamp: 1704067200, + blockNumber: 12345678, + apy: { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + tvl: { + usd: 1000000, + native: 1000000, + }, + }, + ], + }), + ); + const args = { + vaultAddress: "0x123456", + network: "mainnet" as const, + fromDate: "2024-01-01T00:00:00Z", + toDate: "2024-01-02T00:00:00Z", + granularity: "1hour" as const, + apyInterval: "1day" as const, }; - const mockTvlData = { - timestamp: 1704067200, // Jan 1, 2024 - blockNumber: 12345678, - tvlDetails: { - tvlUsd: 1000000, - }, - }; + const result = await provider.vaultHistoricalData(mockWalletProvider, args); + const parsedResult = JSON.parse(result); - // Set up the mock to return appropriate data for each call - mockedFetch.mockImplementation(url => { - if (url.includes("/historical-apy/")) { - return Promise.resolve(mockFetchResult(200, mockApyData)); - } else if (url.includes("/historical-tvl/")) { - return Promise.resolve(mockFetchResult(200, mockTvlData)); - } - return Promise.resolve(mockFetchResult(500, { error: "Unexpected URL" })); + expect(parsedResult).toEqual({ + data: [ + { + timestamp: "2024-01-01T00:00:00.000Z", + blockNumber: 12345678, + apy: { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + tvl: { + usd: 1000000, + native: 1000000, + }, + }, + ], }); + }); + + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); const args = { vaultAddress: "0x123456", - network: "mainnet", - date: "2024-01-01T00:00:00Z", + network: "mainnet" as const, + fromDate: "2024-01-01T00:00:00Z", + toDate: "2024-01-02T00:00:00Z", + granularity: "1hour" as const, + apyInterval: "1day" as const, }; - const result = await provider.vaultHistoricalData(mockWalletProvider, args); - const parsedResult = JSON.parse(result); + expect(await provider.vaultHistoricalData(mockWalletProvider, args)).toBe( + "Failed to fetch vault historical data: some more info", + ); + }); + }); + + describe("rewards_context action", () => { + it("should return the response", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + data: [ + { + some: "data", + }, + ], + }), + ); + const response = await provider.rewardsContext(mockWalletProvider); + expect(JSON.parse(response)).toStrictEqual({ data: [{ some: "data" }] }); + }); + + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); + expect(await provider.rewardsContext(mockWalletProvider)).toBe( + "Failed to fetch rewards context: some more info", + ); + }); + }); + describe("get_benchmark_apy action", () => { + it("should transform the response correctly", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + apy: { + "1day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + "7day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + "30day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + }, + timestamp: 1704067200, + }), + ); + const args = { + network: "mainnet" as const, + benchmarkCode: "eth" as const, + }; + const result = await provider.benchmarkApy(mockWalletProvider, args); + const parsedResult = JSON.parse(result); expect(parsedResult).toEqual({ apy: { - apy: { - base: 5, - rewards: 3, - total: 8, + "1day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + "7day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + "30day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", }, - date: "2024-01-01T00:00:00.000Z", - blockNumber: 12345678, - }, - tvl: { - tvlInUsd: 1000000, - date: "2024-01-01T00:00:00.000Z", - blockNumber: 12345678, }, + timestamp: new Date(1704067200 * 1000).toISOString(), }); }); - it("should return an error if the APY API request fails", async () => { - // Set up the mock to fail for APY but succeed for TVL - mockedFetch.mockImplementation(url => { - if (url.includes("/historical-apy/")) { - return Promise.resolve( - mockFetchResult(500, { - error: "Internal Server Error", - message: "Failed to get historical APY data", - }), - ); - } else if (url.includes("/historical-tvl/")) { - return Promise.resolve( - mockFetchResult(200, { + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); + const args = { + network: "mainnet" as const, + benchmarkCode: "eth" as const, + }; + expect(await provider.benchmarkApy(mockWalletProvider, args)).toBe( + "Failed to fetch benchmark: some more info", + ); + }); + }); + + describe("historical_benchmark_apy action", () => { + it("should transform the response correctly", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + data: [ + { timestamp: 1704067200, - blockNumber: 12345678, - tvlDetails: { tvlUsd: 1000000 }, - }), - ); - } - return Promise.resolve(mockFetchResult(500, { error: "Unexpected URL" })); + apy: { + "1day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + "7day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + + "30day": { + base: 0.5, + reward: 0.3, + total: 0.8, + }, + }, + }, + ], + }), + ); + const args = { + network: "mainnet" as const, + benchmarkCode: "eth" as const, + fromDate: "2024-01-01T00:00:00Z", + toDate: "2024-01-02T00:00:00Z", + page: 1, + perPage: 10, + }; + const result = await provider.historicalBenchmarkApy(mockWalletProvider, args); + const parsedResult = JSON.parse(result); + expect(parsedResult).toEqual({ + data: [ + { + timestamp: "2024-01-01T00:00:00.000Z", + apy: { + "1day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + "7day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + "30day": { + base: "50.00%", + reward: "30.00%", + total: "80.00%", + }, + }, + }, + ], }); + }); + + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); + const args = { + network: "mainnet" as const, + benchmarkCode: "eth" as const, + fromDate: "2024-01-01T00:00:00Z", + toDate: "2024-01-02T00:00:00Z", + page: 1, + perPage: 10, + }; + expect(await provider.historicalBenchmarkApy(mockWalletProvider, args)).toBe( + "Failed to fetch historical benchmark: some more info", + ); + }); + }); + describe("total_vault_returns action", () => { + it("should return the response", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + data: { + totalReturns: 1000000, + }, + }), + ); const args = { vaultAddress: "0x123456", - network: "mainnet", - date: "2024-01-01T00:00:00Z", + network: "mainnet" as const, }; + const result = await provider.totalVaultReturns(mockWalletProvider, args); + expect(JSON.parse(result)).toEqual({ + data: { + totalReturns: 1000000, + }, + }); + }); - expect(await provider.vaultHistoricalData(mockWalletProvider, args)).toBe( - "Failed to fetch vault: Internal Server Error, Failed to get historical APY data", + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); + const args = { + vaultAddress: "0x123456", + network: "mainnet" as const, + }; + expect(await provider.totalVaultReturns(mockWalletProvider, args)).toBe( + "Failed to fetch total vault returns: some more info", ); }); + }); - it("should return an error if the TVL API request fails", async () => { - // Set up the mock to succeed for APY but fail for TVL - mockedFetch.mockImplementation(url => { - if (url.includes("/historical-apy/")) { - return Promise.resolve( - mockFetchResult(200, { + describe("user_events action", () => { + it("should transform the response correctly", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(200, { + data: [ + { timestamp: 1704067200, - blockNumber: 12345678, - apy: { base: 500, rewards: 300, total: 800 }, - }), - ); - } else if (url.includes("/historical-tvl/")) { - return Promise.resolve( - mockFetchResult(500, { - error: "Internal Server Error", - message: "Failed to get historical TVL data", - }), - ); - } - return Promise.resolve(mockFetchResult(500, { error: "Unexpected URL" })); + action: "deposit", + amount: 1000000, + }, + ], + }), + ); + const args = { + vaultAddress: "0x123456", + network: "mainnet" as const, + }; + const result = await provider.userEvents(mockWalletProvider, args); + expect(JSON.parse(result)).toEqual({ + data: [ + { + timestamp: "2024-01-01T00:00:00.000Z", + action: "deposit", + amount: 1000000, + }, + ], }); + }); + it("should return an error if the API request fails", async () => { + mockedFetch.mockResolvedValue( + mockFetchResult(500, { error: "Internal Server Error", message: "some more info" }), + ); const args = { vaultAddress: "0x123456", - network: "mainnet", - date: "2024-01-01T00:00:00Z", + network: "mainnet" as const, }; - - expect(await provider.vaultHistoricalData(mockWalletProvider, args)).toBe( - "Failed to fetch vault: Internal Server Error, Failed to get historical TVL data", + expect(await provider.userEvents(mockWalletProvider, args)).toBe( + "Failed to fetch user events: some more info", ); }); }); diff --git a/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.ts b/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.ts index 8ebc59a29..aa45599f2 100644 --- a/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.ts +++ b/typescript/agentkit/src/action-providers/vaultsfyi/vaultsfyiActionProvider.ts @@ -13,22 +13,23 @@ import { Network } from "../../network"; import { CreateAction } from "../actionDecorator"; import { EvmWalletProvider } from "../../wallet-providers"; import { - claimActionSchema, - depositActionSchema, - redeemActionSchema, + executeStepActionSchema, + transactionContextActionSchema, VaultDetailsActionSchema, VaultHistoricalDataActionSchema, VaultsActionSchema, + claimRewardsActionSchema, + benchmarkActionSchema, + historicalBenchmarkActionSchema, + totalVaultReturnsActionSchema, + userEventsActionSchema, } from "./schemas"; -import { executeActions, parseAssetAmount, transformDetailedVault, transformVault } from "./utils"; -import { VAULTSFYI_SUPPORTED_CHAINS, VAULTS_API_URL } from "./constants"; -import { fetchVaultActions } from "./api/actions"; -import { fetchVault, fetchVaults } from "./api/vaults"; -import { ApiError, Balances, Positions } from "./api/types"; -import { fetchVaultHistoricalData } from "./api/historicalData"; +import { executeActions, transformApy, transformApyObject, transformVault } from "./utils"; +import { getNetworkNameFromChainId, SUPPORTED_CHAIN_IDS } from "./constants"; +import { getVaultsSdk } from "./sdk"; /** - * Configuration options for the OpenseaActionProvider. + * Configuration options for the VaultsfyiActionProvider. */ export interface VaultsfyiActionProviderConfig { /** @@ -71,24 +72,24 @@ export class VaultsfyiActionProvider extends ActionProvider { @CreateAction({ name: "vaults", description: ` - This action returns a list of available vaults. + This action returns a list of available vaults. All asset/lp token amounts returned are in the smallest unit of the token. Small vaults (under 100k TVL) are probably best avoided as they may be more risky. Unless the user is looking for high-risk, high-reward opportunities, don't include them. When the user asks for best vaults, optimize for apy, and if the user asks for safest/reliable vaults, optimize for TVL. - Try to take a reasonable number of results so its easier to analyze the data. Include vaults.fyi links for each vault. - Format result apys as: x% (base: x%, rewards: x%) if rewards apy is available, otherwise: x% + Include vaults.fyi links for each vault. + By default, it's best to check only the vaults for the users network (check with another action if you're not sure). Examples: User: "Show me the best vaults" - args: { sort: { field: 'apy', direction: 'desc' }, take: 5 } + args: { sort: { field: 'apy7day', direction: 'desc' }, perPage: 5 } User: "Show me the safest vaults" - args: { sort: { field: 'tvl', direction: 'desc' }, take: 5 } + args: { sort: { field: 'tvl', direction: 'desc' }, perPage: 5 } User: "Show me the best vaults on Arbitrum" - args: { network: 'arbitrum', sort: { field: 'apy', direction: 'desc' }, take: 5 } + args: { allowedNetworks: ['arbitrum'], sort: { field: 'apy7day', direction: 'desc' }, perPage: 5 } User: "I want to earn yield on my usdc on base!" - args: { token: 'usdc', network: 'base', sort: { field: 'apy', direction: 'desc' }, take: 5 } + args: { allowedAssets: ['usdc'], allowedNetworks: ['base'], sort: { field: 'apy7day', direction: 'desc' }, perPage: 5 } User: "What are some of the most profitable degen vaults on polygon" - args: { network: 'polygon', sort: { field: 'apy', direction: 'desc' }, take: 5, minTvl: 0 } + args: { allowedNetworks: ['polygon'], sort: { field: 'apy7day', direction: 'desc' }, perPage: 5, minTvl: 0 } User: "Show me some more of those" - args: { network: 'polygon', sort: { field: 'apy', direction: 'desc' }, take: 5, minTvl: 0, page: 2 } + args: { allowedNetworks: ['polygon'], sort: { field: 'apy7day', direction: 'desc' }, perPage: 5, minTvl: 0, page: 2 } All optional fields should be null if not specified. `, schema: VaultsActionSchema, @@ -97,44 +98,31 @@ export class VaultsfyiActionProvider extends ActionProvider { wallet: EvmWalletProvider, args: z.infer, ): Promise { - const apyRange = args.apyRange ?? "7day"; - const vaults = await fetchVaults(args, this.apiKey); - if ("error" in vaults) { - return `Failed to fetch vaults: ${vaults.error}, ${vaults.message}`; - } - if (args.protocol && !vaults.find(vault => vault.protocol === args.protocol)) { - const supportedProtocols = vaults - .map(vault => vault.protocol) - .filter((value, index, self) => self.indexOf(value) === index); - return `Protocol ${args.protocol} is not supported. Supported protocols are: ${supportedProtocols.join(", ")}`; - } + try { + const sdk = getVaultsSdk(this.apiKey); + const vaults = await sdk.getAllVaults({ + query: { + page: args.page || 1, + perPage: args.perPage || 5, + allowedAssets: args.allowedAssets ? args.allowedAssets : undefined, + allowedNetworks: args.allowedNetworks ? args.allowedNetworks : undefined, + allowedProtocols: args.allowedProtocols ? args.allowedProtocols : undefined, + minTvl: args.minTvl ?? 100_000, + onlyTransactional: true, + sortBy: args.sort?.field, + sortOrder: args.sort?.direction, + }, + }); - const transformedVaults = vaults.map(vault => transformVault(vault, apyRange)); + const transformedVaults = vaults.data.map(transformVault); - const filteredVaults = transformedVaults.filter(vault => - args.protocol ? vault.protocol === args.protocol : true, - ); - const sortedVaults = filteredVaults.sort((a, b) => { - if (args.sort?.field === "tvl") { - return args.sort.direction === "asc" ? a.tvlInUsd - b.tvlInUsd : b.tvlInUsd - a.tvlInUsd; - } else if (args.sort?.field === "apy") { - return args.sort.direction === "asc" - ? a.apy.total - b.apy.total - : b.apy.total - a.apy.total; - } - return a.name.localeCompare(b.name); - }); - - const take = args.take || 10; - const page = args.page || 1; - const start = (page - 1) * take; - const end = start + take; - const results = sortedVaults.slice(start, end); - return JSON.stringify({ - totalResults: sortedVaults.length, - nextPage: end < sortedVaults.length, - results, - }); + return JSON.stringify({ + ...vaults, + data: transformedVaults, + }); + } catch (error) { + return `Failed to fetch vaults: ${error instanceof Error ? error.message : String(error)}`; + } } /** @@ -145,16 +133,9 @@ export class VaultsfyiActionProvider extends ActionProvider { * @returns A detailed view of a single vault. */ @CreateAction({ - name: "vault_details", - description: ` - This action returns a more detailed view of a single vault. Additional details include: - - Description - - Additional incentives (points etc) - - Rewards breakdown - Params: - - vaultAddress: The address of the vault to fetch details for - - network: The network of the vault - - apyRange: The APY moving average range (default: 7day) + name: "detailed_vault", + description: `This action returns single vault details. + All asset/lp token amounts returned are in the smallest unit of the token. `, schema: VaultDetailsActionSchema, }) @@ -162,11 +143,18 @@ export class VaultsfyiActionProvider extends ActionProvider { wallet: EvmWalletProvider, args: z.infer, ): Promise { - const vault = await fetchVault(args, this.apiKey); - if ("error" in vault) { - return `Failed to fetch vault: ${vault.error}, ${vault.message}`; + try { + const sdk = getVaultsSdk(this.apiKey); + const vault = await sdk.getVault({ + path: { + vaultAddress: args.vaultAddress, + network: args.network, + }, + }); + return JSON.stringify(transformVault(vault)); + } catch (error) { + return `Failed to fetch vault: ${error instanceof Error ? error.message : String(error)}`; } - return JSON.stringify(transformDetailedVault(vault, args.apyRange ?? "7day")); } /** @@ -179,60 +167,67 @@ export class VaultsfyiActionProvider extends ActionProvider { @CreateAction({ name: "vault_historical_data", description: ` - This action returns a historical data of a vault. It returns the APY and TVL data closest to the given date. - Always check if the results date is close to the requested date, as the data may not be available for the exact date. - If there is a more than 7 day difference between the requested date and the resulting date, don't provide the data, but rather with a message explaining the missing data. - If the resulting date is a lot later than the requested date, the reason for missing data might be that the vault has not been deployed yet. - Example queries: - params: { vaultAddress: "0x1234567890abcdef1234567890abcdef12345678", network: "arbitrum", date: "2025-01-01T00:00:00Z" } - result: { ..., date: "2025-02-16T14:59:59.000Z" } - response: "The requested date was 2025-01-01T00:00:00Z, but the closest data available is from 2025-02-16T14:59:59.000Z. This may indicate that the vault was not deployed at the requested date." - `, + This action returns a historical APY, TVL and share price of a vault. + It returns an array of data points with the requested granularity. (hourly, daily weekly), + The pricing is 3 credits base and 3 credits for each datapoint. + Estimate the credits usage and warn the user before executing the action. + All asset/lp token amounts returned are in the smallest unit of the token. +`, schema: VaultHistoricalDataActionSchema, }) async vaultHistoricalData( wallet: EvmWalletProvider, args: z.infer, ): Promise { - const data = await fetchVaultHistoricalData(args, this.apiKey); - if ("error" in data) { - return `Failed to fetch vault: ${data.error}, ${data.message}`; - } - return JSON.stringify({ - apy: { - apy: { - base: data.apy.apy.base / 100, - rewards: data.apy.apy.rewards ? data.apy.apy.rewards / 100 : undefined, - total: data.apy.apy.total / 100, + try { + const sdk = getVaultsSdk(this.apiKey); + const data = await sdk.getVaultHistoricalData({ + path: { + vaultAddress: args.vaultAddress, + network: args.network, + }, + query: { + granularity: args.granularity, + fromTimestamp: Math.floor(new Date(args.fromDate).getTime() / 1000), + toTimestamp: Math.floor(new Date(args.toDate).getTime() / 1000), + apyInterval: args.apyInterval, + page: args.page, + perPage: args.perPage, }, - date: new Date(data.apy.timestamp * 1000).toISOString(), - blockNumber: data.apy.blockNumber, - }, - tvl: { - tvlInUsd: data.tvl.tvlDetails.tvlUsd, - date: new Date(data.tvl.timestamp * 1000).toISOString(), - blockNumber: data.tvl.blockNumber, - }, - }); + }); + return JSON.stringify({ + ...data, + data: data.data.map(d => ({ + ...d, + timestamp: new Date(d.timestamp * 1000).toISOString(), + apy: transformApy(d.apy), + })), + }); + } catch (error) { + return `Failed to fetch vault historical data: ${error instanceof Error ? error.message : String(error)}`; + } } /** - * Deposit action + * Transaction context action * * @param wallet - The wallet provider instance for blockchain interactions * @param args - Input arguments * @returns A result message */ @CreateAction({ - name: "deposit", + name: "transaction_context", description: ` - This action deposits assets into a selected vault. Before depositing make sure you have the required assets in your wallet using the wallet-balances action. - Even if you received the balance from some other source, double-check the user balance. - Use examples: + This action returns the transaction context for a given vault. It returns a list of steps for a deposit/redeem from a vault. + These steps can be executed using the execute_step action. Check the "redeemStepsType"/"depositStepsType" to see if it's "instant" or "complex". + Complex steps might require delay between steps like request and claim flows. Status of these can usually be found in the "vaultSpecificData" field of the context. + All asset/lp token amounts returned are in the smallest unit of the token. For example, USDC has 6 decimals, so 1000 USDC is 1000000000. Use smallest unit for the amount field in the execute_step action. + Usage examples: User: "Deposit 1000 USDC into the vault" actions: - - check wallet balance for USDC - - deposit USDC into the vault if balance is sufficient + - check if the wallet has 1000 USDC + - check vault context to see the deposit steps + - execute the deposit steps sequentially User: "I want more yield on my DAI" actions: - check positions that the user already has for dai @@ -246,92 +241,70 @@ export class VaultsfyiActionProvider extends ActionProvider { - create a diversified strategy using the users assets - propose the strategy to the user before executing `, - schema: depositActionSchema, + schema: transactionContextActionSchema, }) - async deposit( + async transactionContext( wallet: EvmWalletProvider, - args: z.infer, + args: z.infer, ): Promise { - const actions = await fetchVaultActions({ - action: "deposit", - args: { ...args, amount: await parseAssetAmount(wallet, args.assetAddress, args.amount) }, - sender: wallet.getAddress(), - apiKey: this.apiKey, - }); - if ("error" in actions) { - return `Failed to fetch deposit transactions: ${actions.error}, ${actions.message}`; + try { + const sdk = getVaultsSdk(this.apiKey); + const context = await sdk.getTransactionsContext({ + path: { + userAddress: wallet.getAddress(), + vaultAddress: args.vaultAddress, + network: args.network, + }, + }); + return JSON.stringify(context); + } catch (error) { + return `Failed to fetch transaction context: ${error instanceof Error ? error.message : String(error)}`; } - - await executeActions(wallet, actions); - - return "Deposit successful"; } /** - * Redeem action + * Deposit action * * @param wallet - The wallet provider instance for blockchain interactions * @param args - Input arguments * @returns A result message */ @CreateAction({ - name: "redeem", + name: "execute_step", description: ` - This action redeems assets from a selected vault. Before redeeming make sure you have the required lp tokens in your wallet using the positions action. - Even if you received the lp tokens from some other source, double-check the amount before redeeming. - lp tokens aren't always 1:1 with the underlying asset, so make sure to check the amount of lp tokens you have before redeeming even if you know the amount of the underlying asset you want to redeem. - `, - schema: redeemActionSchema, + This action executes a given step on a vault. If you're not sure what steps are available, use the transaction context to get more information. + The amount should be a in smallest unit of the token (f.e. 1000000 for 1 USDC) and for redeeming should be the amount of lpTokens in smallest units. + If you want to redeem all shares, use {"amount":"all"}. + Even if you received the balance from some other source, double-check the user balance with idle_assets/positions/context actions before deposit/redeem.`, + schema: executeStepActionSchema, }) - async redeem( + async executeStep( wallet: EvmWalletProvider, - args: z.infer, + args: z.infer, ): Promise { - const actions = await fetchVaultActions({ - action: "redeem", - args: { ...args, amount: await parseAssetAmount(wallet, args.assetAddress, args.amount) }, - sender: wallet.getAddress(), - apiKey: this.apiKey, - }); - if ("error" in actions) { - return `Failed to fetch redeem transactions: ${actions.error}, ${actions.message}`; - } - - await executeActions(wallet, actions); + try { + const sdk = getVaultsSdk(this.apiKey); + const amount = args.amount === "all" ? 0 : args.amount; + const actions = await sdk.getActions({ + path: { + action: args.action, + userAddress: wallet.getAddress(), + vaultAddress: args.vaultAddress, + network: args.network, + }, + query: { + assetAddress: args.assetAddress, + amount: amount ? amount.toString() : undefined, + all: args.amount === "all", + }, + }); - return "Redeem successful"; - } + await executeActions(wallet, actions); - /** - * Claim rewards action - * - * @param wallet - The wallet provider instance for blockchain interactions - * @param args - Input arguments - * @returns A result message - */ - @CreateAction({ - name: "claim_rewards", - description: ` - This action claims rewards from a selected vault. - assetAddress is the address of the vaults underlying token. - If you're not sure what vaults have rewards claimable, use the positions action. - `, - schema: claimActionSchema, - }) - async claim(wallet: EvmWalletProvider, args: z.infer): Promise { - const actions = await fetchVaultActions({ - action: "claim-rewards", - args, - sender: wallet.getAddress(), - apiKey: this.apiKey, - }); - if ("error" in actions) { - return `Failed to fetch claim transactions: ${actions.error}, ${actions.message}`; + return `Successfully executed ${args.action} step`; + } catch (error) { + return `Failed to execute step: ${error instanceof Error ? error.message : String(error)}`; } - - await executeActions(wallet, actions); - - return "Claim successful"; } /** @@ -341,9 +314,10 @@ export class VaultsfyiActionProvider extends ActionProvider { * @returns A record of the users balances */ @CreateAction({ - name: "user_wallet_balances", + name: "user_idle_assets", description: ` This action returns the users wallet balances of all tokens supported by vaults.fyi. Useful when you don't know token addresses but want to check if the user has an asset. + All asset/lp token amounts returned are in the smallest unit of the token. Example queries: User: "What tokens do I have?" User: "What tokens do I have on Arbitrum?" @@ -351,35 +325,19 @@ export class VaultsfyiActionProvider extends ActionProvider { `, schema: z.object({}), }) - async balances(wallet: EvmWalletProvider): Promise { - const params = new URLSearchParams({ - account: wallet.getAddress(), - }); - const result = await fetch(`${VAULTS_API_URL}/portfolio/wallet-balances?${params.toString()}`, { - method: "GET", - headers: { - "x-api-key": this.apiKey, - }, - }); - const balances = (await result.json()) as Balances | ApiError; - if ("error" in balances) { - return `Failed to fetch wallet balances: ${balances.error}, ${balances.message}`; - } + async idleAssets(wallet: EvmWalletProvider): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const idleAssets = await sdk.getIdleAssets({ + path: { + userAddress: wallet.getAddress(), + }, + }); - const entries = Object.entries(balances).map( - ([network, balances]: [string, Balances[string]]) => { - return [ - network, - balances.map(balance => ({ - address: balance.address, - name: balance.name, - symbol: balance.symbol, - balance: Number(balance.balance) / 10 ** balance.decimals, - })), - ]; - }, - ); - return JSON.stringify(Object.fromEntries(entries)); + return JSON.stringify(idleAssets); + } catch (error) { + return `Failed to fetch idle assets: ${error instanceof Error ? error.message : String(error)}`; + } } /** @@ -392,6 +350,7 @@ export class VaultsfyiActionProvider extends ActionProvider { name: "positions", description: ` This action returns the users positions in vaults. + All asset/lp token amounts returned are in the smallest unit of the token. Example queries: User: "Show me my positions" User: "What vaults am i invested in?" @@ -401,42 +360,253 @@ export class VaultsfyiActionProvider extends ActionProvider { schema: z.object({}), }) async positions(wallet: EvmWalletProvider): Promise { - const result = await fetch(`${VAULTS_API_URL}/portfolio/positions/${wallet.getAddress()}`, { - method: "GET", - headers: { - "x-api-key": this.apiKey, - }, - }); - const positions = (await result.json()) as Positions | ApiError; - if ("error" in positions) { - return `Failed to fetch positions: ${positions.error}, ${positions.message}`; + try { + const sdk = getVaultsSdk(this.apiKey); + const positions = await sdk.getPositions({ + path: { + userAddress: wallet.getAddress(), + }, + }); + + return JSON.stringify({ + ...positions, + data: positions.data.map(p => ({ + ...p, + apy: transformApy(p.apy), + })), + }); + } catch (error) { + return `Failed to fetch positions: ${error instanceof Error ? error.message : String(error)}`; } + } - const entries = Object.entries(positions).map( - ([network, positions]: [string, Positions[string]]) => { - return [ - network, - positions.map(position => ({ - name: position.vaultName, - vaultAddress: position.vaultAddress, - asset: { - address: position.asset.assetAddress, - name: position.asset.name, - symbol: position.asset.symbol, - }, - underlyingTokenBalance: Number(position.balanceNative) / 10 ** position.asset.decimals, - lpTokenBalance: Number(position.balanceLp) / 10 ** position.asset.decimals, - unclaimedRewards: Number(position.unclaimedUsd) > 0, - apy: { - base: position.apy.base / 100, - rewards: position.apy.rewards / 100, - total: position.apy.total / 100, - }, - })), - ]; - }, - ); - return JSON.stringify(Object.fromEntries(entries)); + /** + * Rewards context action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @returns A record of rewards that are available to the user each with a unique claim id + */ + @CreateAction({ + name: "rewards_context", + description: ` + This action returns a record of rewards that are available to the user each with a unique claim id. You can use these ids in the claim_rewards action to claim specific rewards. + All asset/lp token amounts returned are in the smallest unit of the token. + `, + schema: z.object({}), + }) + async rewardsContext(wallet: EvmWalletProvider): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const context = await sdk.getRewardsTransactionsContext({ + path: { + userAddress: wallet.getAddress(), + }, + }); + return JSON.stringify(context); + } catch (error) { + return `Failed to fetch rewards context: ${error instanceof Error ? error.message : String(error)}`; + } + } + + /** + * Claim rewards action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @param args - Input arguments: claimIds + * @returns A message indicating the success of the claim + */ + @CreateAction({ + name: "claim_rewards", + description: ` + This action claims rewards for a given reward id. + `, + schema: claimRewardsActionSchema, + }) + async claimRewards( + wallet: EvmWalletProvider, + args: z.infer, + ): Promise { + const chainId = wallet.getNetwork().chainId; + if (!chainId) return "Invalid network"; + const networkName = getNetworkNameFromChainId(chainId); + if (!networkName) return "Invalid network"; + try { + const sdk = getVaultsSdk(this.apiKey); + const actions = await sdk.getRewardsClaimActions({ + path: { + userAddress: wallet.getAddress(), + }, + query: { + claimIds: args.claimIds, + }, + }); + + if (Object.keys(actions).some(network => network !== networkName)) { + return `Error: You're trying to claim rewards from a different network. Agent network is ${networkName}.`; + } + if (!actions[networkName]) return "No actions found"; + await executeActions(wallet, actions[networkName]); + + return `Successfully claimed rewards for ${args.claimIds.length} rewards`; + } catch (error) { + return `Failed to claim rewards: ${error instanceof Error ? error.message : String(error)}`; + } + } + + /** + * Benchmark APY action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @param args - Input arguments: network, benchmarkCode + * @returns benchmark APY data + */ + @CreateAction({ + name: "benchmark_apy", + description: ` + This action retrieves benchmark APY data for the specified network and benchmark code. It's a weighted average of top yields for the network and asset. Can be used to benchmark vaults against. + `, + schema: benchmarkActionSchema, + }) + async benchmarkApy( + wallet: EvmWalletProvider, + args: z.infer, + ): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const benchmark = await sdk.getBenchmarks({ + path: { + network: args.network, + }, + query: { + code: args.benchmarkCode, + }, + }); + return JSON.stringify({ + ...benchmark, + apy: benchmark.apy ? transformApyObject(benchmark.apy) : null, + timestamp: new Date(benchmark.timestamp * 1000).toISOString(), + }); + } catch (error) { + return `Failed to fetch benchmark: ${error instanceof Error ? error.message : String(error)}`; + } + } + + /** + * Historical benchmark APY action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @param args - Input arguments: network, benchmarkCode, fromDate, toDate, page, perPage + * @returns A list of historical benchmark APY data + */ + @CreateAction({ + name: "historical_benchmark_apy", + description: ` + This action retrieves historical benchmark APY data for the specified network and benchmark code. It's a weighted average of top yields for the network and asset. Can be used to benchmark vaults against. + `, + schema: historicalBenchmarkActionSchema, + }) + async historicalBenchmarkApy( + wallet: EvmWalletProvider, + args: z.infer, + ): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const historicalBenchmarks = await sdk.getHistoricalBenchmarks({ + path: { + network: args.network, + }, + query: { + code: args.benchmarkCode, + fromTimestamp: Math.floor(new Date(args.fromDate).getTime() / 1000), + toTimestamp: Math.floor(new Date(args.toDate).getTime() / 1000), + page: args.page, + perPage: args.perPage, + }, + }); + return JSON.stringify({ + ...historicalBenchmarks, + data: historicalBenchmarks.data.map(d => ({ + timestamp: new Date(d.timestamp * 1000).toISOString(), + apy: d.apy ? transformApyObject(d.apy) : null, + })), + }); + } catch (error) { + return `Failed to fetch historical benchmark: ${error instanceof Error ? error.message : String(error)}`; + } + } + + /** + * Total vault returns action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @param args - Input arguments: vaultAddress, network, userAddress + * @returns An amount of the users total returns + */ + @CreateAction({ + name: "total_vault_returns", + description: ` + This action retrieves the total returns earned by a given user for a given vault. Uses your address if userAddress not specified. + "returnsNative" amounts returned are in the smallest unit of the token. + `, + schema: totalVaultReturnsActionSchema, + }) + async totalVaultReturns( + wallet: EvmWalletProvider, + args: z.infer, + ): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const totalReturns = await sdk.getUserVaultTotalReturns({ + path: { + vaultAddress: args.vaultAddress, + network: args.network, + userAddress: args.userAddress || wallet.getAddress(), + }, + }); + return JSON.stringify(totalReturns); + } catch (error) { + return `Failed to fetch total vault returns: ${error instanceof Error ? error.message : String(error)}`; + } + } + + /** + * User events action + * + * @param wallet - The wallet provider instance for blockchain interactions + * @param args - Input arguments: vaultAddress, network, userAddress + * @returns A list of the users actions on a vault + */ + @CreateAction({ + name: "user_events", + description: ` + This action retrieves historical actions performed by a given user on a given vault. + All asset/lp token amounts returned are in the smallest unit of the token. + `, + schema: userEventsActionSchema, + }) + async userEvents( + wallet: EvmWalletProvider, + args: z.infer, + ): Promise { + try { + const sdk = getVaultsSdk(this.apiKey); + const userEvents = await sdk.getUserVaultEvents({ + path: { + vaultAddress: args.vaultAddress, + network: args.network, + userAddress: args.userAddress || wallet.getAddress(), + }, + }); + return JSON.stringify({ + ...userEvents, + data: userEvents.data.map(d => ({ + ...d, + timestamp: new Date(d.timestamp * 1000).toISOString(), + })), + }); + } catch (error) { + return `Failed to fetch user events: ${error instanceof Error ? error.message : String(error)}`; + } } /** @@ -447,8 +617,8 @@ export class VaultsfyiActionProvider extends ActionProvider { */ supportsNetwork(network: Network): boolean { return ( - network.protocolFamily == "evm" && - (network.chainId ? Object.keys(VAULTSFYI_SUPPORTED_CHAINS).includes(network.chainId) : false) + network.protocolFamily === "evm" && + (network.chainId ? SUPPORTED_CHAIN_IDS.includes(network.chainId) : false) ); } } @@ -459,5 +629,5 @@ export class VaultsfyiActionProvider extends ActionProvider { * @param config - Configuration options for the provider * @returns A new VaultsfyiActionProvider instance */ -export const vaultsfyiActionProvider = (config: VaultsfyiActionProviderConfig) => +export const vaultsfyiActionProvider = (config: VaultsfyiActionProviderConfig = {}) => new VaultsfyiActionProvider(config); diff --git a/typescript/pnpm-lock.yaml b/typescript/pnpm-lock.yaml index 8f85d98c9..931b0ffa6 100644 --- a/typescript/pnpm-lock.yaml +++ b/typescript/pnpm-lock.yaml @@ -64,7 +64,7 @@ importers: dependencies: '@across-protocol/app-sdk': specifier: ^0.2.0 - version: 0.2.0(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 0.2.0(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@alloralabs/allora-sdk': specifier: ^0.1.0 version: 0.1.0 @@ -91,7 +91,7 @@ importers: version: 2.18.5(bufferutil@4.0.9)(utf-8-validate@5.0.10) '@privy-io/server-auth': specifier: 1.18.4 - version: 1.18.4(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 1.18.4(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@solana/kit': specifier: ^2.1.1 version: 2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) @@ -101,18 +101,21 @@ importers: '@solana/web3.js': specifier: ^1.98.1 version: 1.98.1(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10) + '@vaultsfyi/sdk': + specifier: ^2.1.9 + version: 2.1.9(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) '@zerodev/ecdsa-validator': specifier: ^5.4.5 - version: 5.4.5(@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 5.4.5(@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@zerodev/intent': specifier: ^0.0.24 - version: 0.0.24(@zerodev/webauthn-key@5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 0.0.24(@zerodev/webauthn-key@5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@zerodev/sdk': specifier: ^5.4.28 - version: 5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@zoralabs/coins-sdk': specifier: 0.2.8 - version: 0.2.8(abitype@1.0.8(typescript@5.8.2)(zod@3.24.2))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 0.2.8(abitype@1.0.8(typescript@5.8.2)(zod@3.24.2))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@zoralabs/protocol-deployments': specifier: 0.6.1 version: 0.6.1 @@ -127,7 +130,7 @@ importers: version: 2.1.0 clanker-sdk: specifier: ^4.1.18 - version: 4.1.19(@types/node@22.13.14)(typescript@5.8.2)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + version: 4.1.19(@types/node@22.13.14)(typescript@5.8.2)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) decimal.js: specifier: ^10.5.0 version: 10.5.0 @@ -148,13 +151,13 @@ importers: version: 0.2.2 sushi: specifier: 6.2.1 - version: 6.2.1(typescript@5.8.2)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.24.2) + version: 6.2.1(typescript@5.8.2)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.24.2) twitter-api-v2: specifier: ^1.18.2 version: 1.22.0 viem: - specifier: ^2.22.16 - version: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + specifier: 2.38.3 + version: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) x402: specifier: ^0.6.0 version: 0.6.1(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) @@ -539,13 +542,13 @@ importers: version: link:../../framework-extensions/langchain '@langchain/core': specifier: ^0.3.19 - version: 0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + version: 0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) '@langchain/langgraph': specifier: ^0.2.21 - version: 0.2.59(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)(zod-to-json-schema@3.24.5(zod@3.24.2)) + version: 0.2.59(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)(zod-to-json-schema@3.24.5(zod@3.24.2)) '@langchain/openai': specifier: ^0.3.14 - version: 0.3.17(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10)) + version: 0.3.17(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10)) dotenv: specifier: ^16.4.5 version: 16.4.7 @@ -684,6 +687,9 @@ packages: '@adraffy/ens-normalize@1.11.0': resolution: {integrity: sha512-/3DDPKHqqIqxUULp8yP4zODUY1i+2xvVWsv8A79xGWdCAG+8sb0hRh0Rk2QyOJUnnbyPUAZYcpBuRe3nS2OIUg==} + '@adraffy/ens-normalize@1.11.1': + resolution: {integrity: sha512-nhCBV3quEgesuf7c7KYfperqSS14T8bYuvJ8PcLJp6znkZpFc0AuW4qBtr8eKVyPPe/8RSr7sglCWPU5eaxwKQ==} + '@ai-sdk/openai@1.3.3': resolution: {integrity: sha512-CH57tonLB4DwkwqwnMmTCoIOR7cNW3bP5ciyloI7rBGJS/Bolemsoo+vn5YnwkyT9O1diWJyvYeTh7A4UfiYOw==} engines: {node: '>=18'} @@ -1397,6 +1403,9 @@ packages: '@jridgewell/sourcemap-codec@1.5.0': resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + '@jridgewell/sourcemap-codec@1.5.5': + resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==} + '@jridgewell/trace-mapping@0.3.25': resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} @@ -1562,6 +1571,10 @@ packages: resolution: {integrity: sha512-warwspo+UYUPep0Q+vtdVB4Ugn8GGQj8iyB3gnRWsztmUHTI3S1nhdiWNsPUGL0vud7JlRRk1XEu7Lq1KGTnMQ==} engines: {node: ^14.21.3 || >=16} + '@noble/curves@1.8.2': + resolution: {integrity: sha512-vnI7V6lFNe0tLAuJMu+2sX+FcL14TaCWy1qiczg1VwRmPrpQCdq5ESXQMqUc2tluRNf6irBXrWbl1mGN8uaU/g==} + engines: {node: ^14.21.3 || >=16} + '@noble/curves@1.9.0': resolution: {integrity: sha512-7YDlXiNMdO1YZeH6t/kvopHHbIZzlxrCV9WLqCY6QhcXOoXiNCMDqJIglZ9Yjx5+w7Dz30TITFrlTjnRg7sKEg==} engines: {node: ^14.21.3 || >=16} @@ -1570,8 +1583,8 @@ packages: resolution: {integrity: sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==} engines: {node: ^14.21.3 || >=16} - '@noble/curves@1.9.6': - resolution: {integrity: sha512-GIKz/j99FRthB8icyJQA51E8Uk5hXmdyThjgQXRKiv9h0zeRlzSCLIzFw6K1LotZ3XuB7yzlf76qk7uBmTdFqA==} + '@noble/curves@1.9.7': + resolution: {integrity: sha512-gbKGcRUYIjA3/zCCNaWDciTMFI0dCkvou3TL8Zmy5Nc7sJ47a0jtOeZoTaMxkuqRo9cRhjOdZJXegxYE5FN/xw==} engines: {node: ^14.21.3 || >=16} '@noble/hashes@1.3.2': @@ -1590,6 +1603,10 @@ packages: resolution: {integrity: sha512-B8XBPsn4vT/KJAGqDzbwztd+6Yte3P4V7iafm24bxgDe/mlRuK6xmWPuCNrKt2vDafZ8MfJLlchDG/vYafQEjQ==} engines: {node: ^14.21.3 || >=16} + '@noble/hashes@1.7.2': + resolution: {integrity: sha512-biZ0NUSxyjLLqo6KxEJ1b+C2NAx0wtDoFvCaXHGgUkeHzf3Xc1xKumFKREuT7f7DARNZ/slvYUwFG6B0f2b6hQ==} + engines: {node: ^14.21.3 || >=16} + '@noble/hashes@1.8.0': resolution: {integrity: sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==} engines: {node: ^14.21.3 || >=16} @@ -2103,6 +2120,10 @@ packages: peerDependencies: typescript: '>=5.3.3' + '@solana/wallet-standard-features@1.3.0': + resolution: {integrity: sha512-ZhpZtD+4VArf6RPitsVExvgkF+nGghd1rzPjd97GmBximpnt1rsUxMOEyoIEuH3XBxPyNB6Us7ha7RHWQR+abg==} + engines: {node: '>=16'} + '@solana/web3.js@1.98.0': resolution: {integrity: sha512-nz3Q5OeyGFpFCR+erX2f6JPt3sKhzhYcSycBCSPkWjzSVDh/Rr1FqTVMRe58FKO16/ivTUcuJjeS5MyBvpkbzA==} @@ -2123,8 +2144,8 @@ packages: peerDependencies: react: ^18 || ^19 - '@tsconfig/node10@1.0.11': - resolution: {integrity: sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==} + '@tsconfig/node10@1.0.12': + resolution: {integrity: sha512-UCYBaeFvM11aU2y3YPZ//O5Rhj+xKyzy7mvcIoAjASbigy8mHMryP5cK7dgjlz2hWxh1g5pLw084E0a/wlUSFQ==} '@tsconfig/node12@1.0.11': resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} @@ -2323,6 +2344,9 @@ packages: resolution: {integrity: sha512-JQkXcpRI3jFG8y3/CGC4TS8NkDgcxXaOQuYW8Qdvd6DcDiIyg2vVYCG9igFEzF0G6UvxgHkBKC7cWCgzZNYvQg==} engines: {node: '>=10'} + '@vaultsfyi/sdk@2.1.9': + resolution: {integrity: sha512-pXxEGh24/dnRQjF2uIUHaLtu0WC9+V2wpWCvyEBfS/zfFdKt35AY8Jgr6rOe3T3ehBQMq8BKCJZq+WPJFGj+ig==} + '@wagmi/connectors@5.10.0': resolution: {integrity: sha512-pG9a9PIOkxfJQF7kSdMUfPjZ52LOPjXboga99LnZHh+VXmXd2J93r7NGYO3kF0lhrt3hdbmYYsZCOgbPkXiHig==} peerDependencies: @@ -2345,6 +2369,18 @@ packages: typescript: optional: true + '@wallet-standard/app@1.1.0': + resolution: {integrity: sha512-3CijvrO9utx598kjr45hTbbeeykQrQfKmSnxeWOgU25TOEpvcipD/bYDQWIqUv1Oc6KK4YStokSMu/FBNecGUQ==} + engines: {node: '>=16'} + + '@wallet-standard/base@1.1.0': + resolution: {integrity: sha512-DJDQhjKmSNVLKWItoKThJS+CsJQjR9AOBOirBVT1F9YpRyC9oYHE+ZnSf8y8bxUphtKqdQMPVQ2mHohYdRvDVQ==} + engines: {node: '>=16'} + + '@wallet-standard/features@1.1.0': + resolution: {integrity: sha512-hiEivWNztx73s+7iLxsuD1sOJ28xtRix58W7Xnz4XzzA/pF0+aicnWgjOdA10doVDEDZdUuZCIIqG96SFNlDUg==} + engines: {node: '>=16'} + '@walletconnect/core@2.21.0': resolution: {integrity: sha512-o6R7Ua4myxR8aRUAJ1z3gT9nM+jd2B2mfamu6arzy1Cc6vi10fIwFWb6vg3bC8xJ6o9H3n/cN5TOW3aA9Y1XVw==} engines: {node: '>=18'} @@ -2572,6 +2608,11 @@ packages: engines: {node: '>=0.4.0'} hasBin: true + acorn@8.15.0: + resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==} + engines: {node: '>=0.4.0'} + hasBin: true + aes-js@3.0.0: resolution: {integrity: sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==} @@ -2801,6 +2842,9 @@ packages: bn.js@5.2.1: resolution: {integrity: sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==} + bn.js@5.2.2: + resolution: {integrity: sha512-v2YAxEmKaBLahNwE1mjp4WON6huMNeuDvagFZW+ASCuA/ku0bXR9hSMw0XpiqMoA3+rmnyck/tPRSFQkoC9Cuw==} + body-parser@2.1.0: resolution: {integrity: sha512-/hPxh61E+ll0Ujp24Ilm64cykicul1ypfwjVttduAiEdtnJFvLePSrIPk+HMImtNv5270wOGCb1Tns2rybMkoQ==} engines: {node: '>=18'} @@ -3155,6 +3199,15 @@ packages: supports-color: optional: true + debug@4.4.3: + resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + decamelize-keys@1.1.1: resolution: {integrity: sha512-WiPxgEirIV0/eIOMcnFBA3/IJZAZqKnwAwWyvvdi4lsr1WCN22nhdf/3db3DoZcUjTV2SqfzIwNyp6y2xs3nmg==} engines: {node: '>=0.10.0'} @@ -4915,14 +4968,6 @@ packages: typescript: optional: true - ox@0.9.3: - resolution: {integrity: sha512-KzyJP+fPV4uhuuqrTZyok4DC7vFzi7HLUFiUNEmpbyh59htKWkOC98IONC1zgXJPbHAhQgqs6B0Z6StCGhmQvg==} - peerDependencies: - typescript: '>=5.4.0' - peerDependenciesMeta: - typescript: - optional: true - ox@0.9.6: resolution: {integrity: sha512-8SuCbHPvv2eZLYXrNmC0EC12rdzXQLdhnOMlHDW2wiCPLxBrOOJwX5L5E61by+UjTPOryqQiRSnjIKCI+GykKg==} peerDependencies: @@ -5081,6 +5126,9 @@ packages: preact@10.24.2: resolution: {integrity: sha512-1cSoF0aCC8uaARATfrlz4VCBqE8LwZwRfLgkxJOQwAlQt6ayTmi0D9OF7nXid1POI5SZidFuG9CnlXbDfLqY/Q==} + preact@10.27.2: + resolution: {integrity: sha512-5SYSgFKSyhCbk6SrXyMpqjb5+MQBgfvEKE/OC+PujcY34sOpqtr+0AZQtPYx5IA6VxynQ7rUPCtKzyovpj9Bpg==} + prelude-ls@1.2.1: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} @@ -5383,6 +5431,11 @@ packages: engines: {node: '>=10'} hasBin: true + semver@7.7.3: + resolution: {integrity: sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==} + engines: {node: '>=10'} + hasBin: true + send@1.1.0: resolution: {integrity: sha512-v67WcEouB5GxbTWL/4NeToqcZiAWEq90N888fczVArY8A79J0L4FD7vj5hm3eUMua5EpoQ59wa/oovY6TLvRUA==} engines: {node: '>= 18'} @@ -5413,6 +5466,11 @@ packages: resolution: {integrity: sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==} hasBin: true + sha.js@2.4.12: + resolution: {integrity: sha512-8LzC5+bvI45BjpfXU8V5fdU2mfeKiQe1D1gIMn7XUlF3OTUrpdJpPPH4EMAnF0DsHHdSZqCdSss5qCmJKuiO3w==} + engines: {node: '>= 0.10'} + hasBin: true + shebang-command@2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} engines: {node: '>=8'} @@ -5689,6 +5747,10 @@ packages: tmpl@1.0.5: resolution: {integrity: sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw==} + to-buffer@1.2.2: + resolution: {integrity: sha512-db0E3UJjcFhpDhAF4tLo03oli3pwl3dbnzXOUIlRKrp+ldk/VUxzpWYZENsw2SZiuBjHAk7DfB0VU7NKdpb6sw==} + engines: {node: '>= 0.4'} + to-regex-range@5.0.1: resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} engines: {node: '>=8.0'} @@ -6119,16 +6181,16 @@ packages: typescript: optional: true - viem@2.37.5: - resolution: {integrity: sha512-bLKvKgLcge6KWBMLk8iP9weu5tHNr0hkxPNwQd+YQrHEgek7ogTBBeE10T0V6blwBMYmeZFZHLnMhDmPjp63/A==} + viem@2.38.0: + resolution: {integrity: sha512-YU5TG8dgBNeYPrCMww0u9/JVeq2ZCk9fzk6QybrPkBooFysamHXL1zC3ua10aLPt9iWoA/gSVf1D9w7nc5B1aA==} peerDependencies: typescript: '>=5.0.4' peerDependenciesMeta: typescript: optional: true - viem@2.38.0: - resolution: {integrity: sha512-YU5TG8dgBNeYPrCMww0u9/JVeq2ZCk9fzk6QybrPkBooFysamHXL1zC3ua10aLPt9iWoA/gSVf1D9w7nc5B1aA==} + viem@2.38.3: + resolution: {integrity: sha512-By2TutLv07iNHHtWqHHzjGipevYsfGqT7KQbGEmqLco1qTJxKnvBbSviqiu6/v/9REV6Q/FpmIxf2Z7/l5AbcQ==} peerDependencies: typescript: '>=5.0.4' peerDependenciesMeta: @@ -6285,9 +6347,15 @@ packages: x402-axios@0.6.0: resolution: {integrity: sha512-UyKZnepVH3xz8+BsHIqAsvZohHa06yLdOOWo51ctEeazOdH57gRLVmtvEVbpBnrO2Fh0kbgcagzVlM/5v3M0Zw==} + x402-fetch@0.7.0: + resolution: {integrity: sha512-HS7v6wsIVrU8TvAGBwRmA3I+ZXbanPraA3OMj90y6Hn1Mej1wAELOK4VpGh6zI8d6w5E464BnGu9o0FE+8DRAA==} + x402@0.6.1: resolution: {integrity: sha512-9UmeCSsYzFGav5FdVP70VplKlR3V90P0DZ9fPSrlLVp0ifUVi1S9TztvegkmIHE9xTGZ1GWNi+bkne6N0Ea58w==} + x402@0.7.2: + resolution: {integrity: sha512-JleP1GmeOP1bEuwzFVtjusL3t5H1PGufROrBKg5pj/MfcGswkBvfB6j5Gm5UeA+kwp0ZmOkkHAqkoHF1WexbsQ==} + xmlhttprequest-ssl@2.1.2: resolution: {integrity: sha512-TEU+nJVUUnA4CYJFLvK5X9AOeH4KvDvhIfm0vV1GaQRtchnG0hgK5p8hw/xjv8cunWYCsiPCSDzObPyhEwq3KQ==} engines: {node: '>=0.4.0'} @@ -6394,14 +6462,16 @@ packages: snapshots: - '@across-protocol/app-sdk@0.2.0(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@across-protocol/app-sdk@0.2.0(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) '@adraffy/ens-normalize@1.10.1': {} '@adraffy/ens-normalize@1.11.0': {} + '@adraffy/ens-normalize@1.11.1': {} + '@ai-sdk/openai@1.3.3(zod@3.24.2)': dependencies: '@ai-sdk/provider': 1.1.0 @@ -6643,7 +6713,7 @@ snapshots: idb-keyval: 6.2.1 ox: 0.6.9(typescript@5.8.2)(zod@3.25.56) preact: 10.24.2 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) zustand: 5.0.3(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) transitivePeerDependencies: - '@types/react' @@ -6663,7 +6733,7 @@ snapshots: idb-keyval: 6.2.1 ox: 0.6.9(typescript@5.8.2)(zod@3.24.2) preact: 10.24.2 - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) zustand: 5.0.3(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) transitivePeerDependencies: - '@types/react' @@ -6846,7 +6916,7 @@ snapshots: jose: 6.0.10 md5: 2.3.0 uncrypto: 0.1.3 - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) zod: 3.25.56 transitivePeerDependencies: - bufferutil @@ -6871,7 +6941,7 @@ snapshots: ethers: 6.13.5(bufferutil@4.0.9)(utf-8-validate@5.0.10) jose: 5.10.0 secp256k1: 5.0.1 - viem: 2.24.1(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) transitivePeerDependencies: - bufferutil - debug @@ -6881,15 +6951,15 @@ snapshots: '@coinbase/wallet-sdk@3.9.3': dependencies: - bn.js: 5.2.1 + bn.js: 5.2.2 buffer: 6.0.3 clsx: 1.2.1 eth-block-tracker: 7.1.0 eth-json-rpc-filters: 6.0.1 eventemitter3: 5.0.1 keccak: 3.0.4 - preact: 10.24.2 - sha.js: 2.4.11 + preact: 10.27.2 + sha.js: 2.4.12 transitivePeerDependencies: - supports-color @@ -6901,7 +6971,7 @@ snapshots: idb-keyval: 6.2.1 ox: 0.6.9(typescript@5.8.2)(zod@3.25.56) preact: 10.24.2 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) zustand: 5.0.3(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) transitivePeerDependencies: - '@types/react' @@ -6916,7 +6986,7 @@ snapshots: '@coinbase/x402@0.6.4(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))': dependencies: '@coinbase/cdp-sdk': 1.38.1(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(utf-8-validate@5.0.10) - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) x402: 0.6.1(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) zod: 3.25.56 transitivePeerDependencies: @@ -7350,11 +7420,11 @@ snapshots: '@fastify/busboy@2.1.1': {} - '@gemini-wallet/core@0.2.0(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))': + '@gemini-wallet/core@0.2.0(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: '@metamask/rpc-errors': 7.0.2 eventemitter3: 5.0.1 - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) transitivePeerDependencies: - supports-color @@ -7608,6 +7678,9 @@ snapshots: '@jridgewell/sourcemap-codec@1.5.0': {} + '@jridgewell/sourcemap-codec@1.5.5': + optional: true + '@jridgewell/trace-mapping@0.3.25': dependencies: '@jridgewell/resolve-uri': 3.1.2 @@ -7616,7 +7689,7 @@ snapshots: '@jridgewell/trace-mapping@0.3.9': dependencies: '@jridgewell/resolve-uri': 3.1.2 - '@jridgewell/sourcemap-codec': 1.5.0 + '@jridgewell/sourcemap-codec': 1.5.5 optional: true '@jup-ag/api@6.0.40': {} @@ -7638,6 +7711,23 @@ snapshots: transitivePeerDependencies: - openai + '@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2))': + dependencies: + '@cfworker/json-schema': 4.1.1 + ansi-styles: 5.2.0 + camelcase: 6.3.0 + decamelize: 1.2.0 + js-tiktoken: 1.0.19 + langsmith: 0.2.15(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + mustache: 4.2.0 + p-queue: 6.6.2 + p-retry: 4.6.2 + uuid: 10.0.0 + zod: 3.24.2 + zod-to-json-schema: 3.24.5(zod@3.24.2) + transitivePeerDependencies: + - openai + '@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2))': dependencies: '@cfworker/json-schema': 4.1.1 @@ -7677,6 +7767,11 @@ snapshots: '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.25.56)) uuid: 10.0.0 + '@langchain/langgraph-checkpoint@0.0.16(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))': + dependencies: + '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + uuid: 10.0.0 + '@langchain/langgraph-checkpoint@0.0.16(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))': dependencies: '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) @@ -7697,6 +7792,16 @@ snapshots: '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.25.56)) react: 18.3.1 + '@langchain/langgraph-sdk@0.0.60(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)': + dependencies: + '@types/json-schema': 7.0.15 + p-queue: 6.6.2 + p-retry: 4.6.2 + uuid: 9.0.1 + optionalDependencies: + '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + react: 18.3.1 + '@langchain/langgraph-sdk@0.0.60(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)': dependencies: '@types/json-schema': 7.0.15 @@ -7729,6 +7834,18 @@ snapshots: transitivePeerDependencies: - react + '@langchain/langgraph@0.2.59(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)(zod-to-json-schema@3.24.5(zod@3.24.2))': + dependencies: + '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + '@langchain/langgraph-checkpoint': 0.0.16(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2))) + '@langchain/langgraph-sdk': 0.0.60(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1) + uuid: 10.0.0 + zod: 3.24.2 + optionalDependencies: + zod-to-json-schema: 3.24.5(zod@3.24.2) + transitivePeerDependencies: + - react + '@langchain/langgraph@0.2.59(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(react@18.3.1)(zod-to-json-schema@3.24.5(zod@3.24.2))': dependencies: '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) @@ -7764,6 +7881,17 @@ snapshots: - encoding - ws + '@langchain/openai@0.3.17(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))': + dependencies: + '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) + js-tiktoken: 1.0.19 + openai: 4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2) + zod: 3.24.2 + zod-to-json-schema: 3.24.5(zod@3.24.2) + transitivePeerDependencies: + - encoding + - ws + '@langchain/openai@0.3.17(@langchain/core@0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)))(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))': dependencies: '@langchain/core': 0.3.30(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)) @@ -7960,8 +8088,8 @@ snapshots: dependencies: '@ethereumjs/tx': 4.2.0 '@types/debug': 4.1.12 - debug: 4.4.0(supports-color@5.5.0) - semver: 7.7.1 + debug: 4.4.3 + semver: 7.7.3 superstruct: 1.0.4 transitivePeerDependencies: - supports-color @@ -8029,6 +8157,10 @@ snapshots: dependencies: '@noble/hashes': 1.7.1 + '@noble/curves@1.8.2': + dependencies: + '@noble/hashes': 1.7.2 + '@noble/curves@1.9.0': dependencies: '@noble/hashes': 1.8.0 @@ -8037,7 +8169,7 @@ snapshots: dependencies: '@noble/hashes': 1.8.0 - '@noble/curves@1.9.6': + '@noble/curves@1.9.7': dependencies: '@noble/hashes': 1.8.0 @@ -8049,6 +8181,8 @@ snapshots: '@noble/hashes@1.7.1': {} + '@noble/hashes@1.7.2': {} + '@noble/hashes@1.8.0': {} '@noble/secp256k1@2.3.0': {} @@ -8103,7 +8237,7 @@ snapshots: - bufferutil - utf-8-validate - '@privy-io/server-auth@1.18.4(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@privy-io/server-auth@1.18.4(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: '@noble/curves': 1.8.1 '@noble/hashes': 1.7.1 @@ -8117,7 +8251,7 @@ snapshots: ts-case-convert: 2.1.0 type-fest: 3.13.1 optionalDependencies: - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) transitivePeerDependencies: - bufferutil - encoding @@ -8151,7 +8285,7 @@ snapshots: dependencies: big.js: 6.2.2 dayjs: 1.11.13 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.22.4) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.22.4) transitivePeerDependencies: - bufferutil - typescript @@ -8162,7 +8296,7 @@ snapshots: dependencies: big.js: 6.2.2 dayjs: 1.11.13 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) transitivePeerDependencies: - bufferutil - typescript @@ -8175,7 +8309,7 @@ snapshots: '@reown/appkit-wallet': 1.7.8(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10) '@walletconnect/universal-provider': 2.21.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) valtio: 1.13.2(react@18.3.1) - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) transitivePeerDependencies: - '@azure/app-configuration' - '@azure/cosmos' @@ -8325,7 +8459,7 @@ snapshots: '@walletconnect/logger': 2.1.2 '@walletconnect/universal-provider': 2.21.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) valtio: 1.13.2(react@18.3.1) - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) transitivePeerDependencies: - '@azure/app-configuration' - '@azure/cosmos' @@ -8379,7 +8513,7 @@ snapshots: '@walletconnect/universal-provider': 2.21.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) bs58: 6.0.0 valtio: 1.13.2(react@18.3.1) - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) transitivePeerDependencies: - '@azure/app-configuration' - '@azure/cosmos' @@ -8423,7 +8557,7 @@ snapshots: '@safe-global/safe-apps-sdk@9.1.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56)': dependencies: '@safe-global/safe-gateway-typescript-sdk': 3.23.1 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) transitivePeerDependencies: - bufferutil - typescript @@ -8446,13 +8580,13 @@ snapshots: '@scure/bip32@1.6.2': dependencies: - '@noble/curves': 1.8.1 - '@noble/hashes': 1.7.1 - '@scure/base': 1.2.4 + '@noble/curves': 1.8.2 + '@noble/hashes': 1.7.2 + '@scure/base': 1.2.6 '@scure/bip32@1.7.0': dependencies: - '@noble/curves': 1.9.6 + '@noble/curves': 1.9.7 '@noble/hashes': 1.8.0 '@scure/base': 1.2.6 @@ -8463,7 +8597,7 @@ snapshots: '@scure/bip39@1.5.4': dependencies: - '@noble/hashes': 1.7.1 + '@noble/hashes': 1.7.2 '@scure/base': 1.2.4 '@scure/bip39@1.6.0': @@ -8992,6 +9126,11 @@ snapshots: transitivePeerDependencies: - fastestsmallesttextencoderdecoder + '@solana/wallet-standard-features@1.3.0': + dependencies: + '@wallet-standard/base': 1.1.0 + '@wallet-standard/features': 1.1.0 + '@solana/web3.js@1.98.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)': dependencies: '@babel/runtime': 7.27.0 @@ -9050,7 +9189,7 @@ snapshots: '@tanstack/query-core': 5.89.0 react: 18.3.1 - '@tsconfig/node10@1.0.11': + '@tsconfig/node10@1.0.12': optional: true '@tsconfig/node12@1.0.11': @@ -9290,18 +9429,55 @@ snapshots: '@uniswap/token-lists@1.0.0-beta.33': {} - '@wagmi/connectors@5.10.0(@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))(zod@3.25.56)': + '@vaultsfyi/sdk@2.1.9(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))': + dependencies: + x402-fetch: 0.7.0(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@deno/kv' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@solana/sysvars' + - '@tanstack/query-core' + - '@tanstack/react-query' + - '@types/react' + - '@upstash/redis' + - '@vercel/blob' + - '@vercel/functions' + - '@vercel/kv' + - aws4fetch + - bufferutil + - db0 + - encoding + - fastestsmallesttextencoderdecoder + - immer + - ioredis + - react + - supports-color + - typescript + - uploadthing + - utf-8-validate + - ws + + '@wagmi/connectors@5.10.0(@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.25.56)': dependencies: '@base-org/account': 1.1.1(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(zod@3.25.56) '@coinbase/wallet-sdk': 4.3.6(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(zod@3.25.56) - '@gemini-wallet/core': 0.2.0(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56)) + '@gemini-wallet/core': 0.2.0(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@metamask/sdk': 0.32.0(bufferutil@4.0.9)(utf-8-validate@5.0.10) '@safe-global/safe-apps-provider': 0.18.6(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) '@safe-global/safe-apps-sdk': 9.1.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) - '@wagmi/core': 2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + '@wagmi/core': 2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) '@walletconnect/ethereum-provider': 2.21.1(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) cbw-sdk: '@coinbase/wallet-sdk@3.9.3' - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) optionalDependencies: typescript: 5.8.2 transitivePeerDependencies: @@ -9334,11 +9510,11 @@ snapshots: - utf-8-validate - zod - '@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: eventemitter3: 5.0.1 mipd: 0.0.7(typescript@5.8.2) - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) zustand: 5.0.0(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) optionalDependencies: '@tanstack/query-core': 5.89.0 @@ -9349,20 +9525,15 @@ snapshots: - react - use-sync-external-store - '@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))': + '@wallet-standard/app@1.1.0': dependencies: - eventemitter3: 5.0.1 - mipd: 0.0.7(typescript@5.8.2) - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) - zustand: 5.0.0(react@18.3.1)(use-sync-external-store@1.4.0(react@18.3.1)) - optionalDependencies: - '@tanstack/query-core': 5.89.0 - typescript: 5.8.2 - transitivePeerDependencies: - - '@types/react' - - immer - - react - - use-sync-external-store + '@wallet-standard/base': 1.1.0 + + '@wallet-standard/base@1.1.0': {} + + '@wallet-standard/features@1.1.0': + dependencies: + '@wallet-standard/base': 1.1.0 '@walletconnect/core@2.21.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56)': dependencies: @@ -9909,7 +10080,7 @@ snapshots: '@xmtp/content-type-text': 2.0.2 '@xmtp/node-sdk': 4.2.2 uint8arrays: 5.1.0 - viem: 2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) transitivePeerDependencies: - bufferutil - typescript @@ -9968,47 +10139,47 @@ snapshots: rxjs: 7.8.2 undici: 5.29.0 - '@zerodev/ecdsa-validator@5.4.5(@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zerodev/ecdsa-validator@5.4.5(@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: - '@zerodev/sdk': 5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + '@zerodev/sdk': 5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) - '@zerodev/intent@0.0.24(@zerodev/webauthn-key@5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zerodev/intent@0.0.24(@zerodev/webauthn-key@5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: - '@zerodev/ecdsa-validator': 5.4.5(@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) - '@zerodev/multi-chain-ecdsa-validator': 5.4.4(@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(@zerodev/webauthn-key@5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) - '@zerodev/sdk': 5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + '@zerodev/ecdsa-validator': 5.4.5(@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + '@zerodev/multi-chain-ecdsa-validator': 5.4.4(@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(@zerodev/webauthn-key@5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + '@zerodev/sdk': 5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) transitivePeerDependencies: - '@zerodev/webauthn-key' - '@zerodev/multi-chain-ecdsa-validator@5.4.4(@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(@zerodev/webauthn-key@5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zerodev/multi-chain-ecdsa-validator@5.4.4(@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(@zerodev/webauthn-key@5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: '@simplewebauthn/browser': 9.0.1 '@simplewebauthn/typescript-types': 8.3.4 - '@zerodev/sdk': 5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) - '@zerodev/webauthn-key': 5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + '@zerodev/sdk': 5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) + '@zerodev/webauthn-key': 5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) merkletreejs: 0.3.11 - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) - '@zerodev/sdk@5.4.28(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zerodev/sdk@5.4.28(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: semver: 7.7.1 - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) - '@zerodev/webauthn-key@5.4.3(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zerodev/webauthn-key@5.4.3(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: - '@noble/curves': 1.9.6 + '@noble/curves': 1.9.7 '@simplewebauthn/browser': 8.3.7 '@simplewebauthn/types': 12.0.0 - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) - '@zoralabs/coins-sdk@0.2.8(abitype@1.0.8(typescript@5.8.2)(zod@3.24.2))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': + '@zoralabs/coins-sdk@0.2.8(abitype@1.0.8(typescript@5.8.2)(zod@3.24.2))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))': dependencies: '@hey-api/client-fetch': 0.8.4 '@zoralabs/protocol-deployments': 0.6.1 abitype: 1.0.8(typescript@5.8.2)(zod@3.24.2) - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) '@zoralabs/protocol-deployments@0.6.1': {} @@ -10064,11 +10235,14 @@ snapshots: acorn-walk@8.3.4: dependencies: - acorn: 8.14.1 + acorn: 8.15.0 optional: true acorn@8.14.1: {} + acorn@8.15.0: + optional: true + aes-js@3.0.0: {} aes-js@4.0.0-beta.5: {} @@ -10326,7 +10500,7 @@ snapshots: bip32@4.0.0: dependencies: '@noble/hashes': 1.8.0 - '@scure/base': 1.2.4 + '@scure/base': 1.2.6 typeforce: 1.18.0 wif: 2.0.6 @@ -10352,6 +10526,8 @@ snapshots: bn.js@5.2.1: {} + bn.js@5.2.2: {} + body-parser@2.1.0: dependencies: bytes: 3.1.2 @@ -10517,13 +10693,13 @@ snapshots: cjs-module-lexer@1.4.3: {} - clanker-sdk@4.1.19(@types/node@22.13.14)(typescript@5.8.2)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)): + clanker-sdk@4.1.19(@types/node@22.13.14)(typescript@5.8.2)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)): dependencies: '@openzeppelin/merkle-tree': 1.0.8 abitype: 1.0.8(typescript@5.8.2)(zod@3.25.56) dotenv: 16.4.7 inquirer: 8.2.7(@types/node@22.13.14) - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) zod: 3.25.56 transitivePeerDependencies: - '@types/node' @@ -10726,6 +10902,10 @@ snapshots: optionalDependencies: supports-color: 5.5.0 + debug@4.4.3: + dependencies: + ms: 2.1.3 + decamelize-keys@1.1.1: dependencies: decamelize: 1.2.0 @@ -10827,7 +11007,7 @@ snapshots: dependencies: '@ecies/ciphers': 0.2.4(@noble/ciphers@1.3.0) '@noble/ciphers': 1.3.0 - '@noble/curves': 1.9.6 + '@noble/curves': 1.9.7 '@noble/hashes': 1.8.0 ed2curve@0.3.0: @@ -12535,6 +12715,17 @@ snapshots: optionalDependencies: openai: 4.89.1(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.25.56) + langsmith@0.2.15(openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)): + dependencies: + '@types/uuid': 10.0.0 + commander: 10.0.1 + p-queue: 6.6.2 + p-retry: 4.6.2 + semver: 7.7.1 + uuid: 10.0.0 + optionalDependencies: + openai: 4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2) + langsmith@0.2.15(openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2)): dependencies: '@types/uuid': 10.0.0 @@ -12956,6 +13147,21 @@ snapshots: - encoding optional: true + openai@4.89.1(ws@8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2): + dependencies: + '@types/node': 18.19.83 + '@types/node-fetch': 2.6.12 + abort-controller: 3.0.0 + agentkeepalive: 4.6.0 + form-data-encoder: 1.7.2 + formdata-node: 4.4.1 + node-fetch: 2.7.0 + optionalDependencies: + ws: 8.18.1(bufferutil@4.0.9)(utf-8-validate@5.0.10) + zod: 3.24.2 + transitivePeerDependencies: + - encoding + openai@4.89.1(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10))(zod@3.24.2): dependencies: '@types/node': 18.19.83 @@ -13055,7 +13261,7 @@ snapshots: ox@0.6.7(typescript@5.8.2)(zod@3.25.56): dependencies: '@adraffy/ens-normalize': 1.11.0 - '@noble/curves': 1.9.6 + '@noble/curves': 1.9.7 '@noble/hashes': 1.8.0 '@scure/bip32': 1.7.0 '@scure/bip39': 1.6.0 @@ -13068,8 +13274,8 @@ snapshots: ox@0.6.9(typescript@5.8.2)(zod@3.24.2): dependencies: - '@adraffy/ens-normalize': 1.11.0 - '@noble/curves': 1.9.6 + '@adraffy/ens-normalize': 1.11.1 + '@noble/curves': 1.9.7 '@noble/hashes': 1.8.0 '@scure/bip32': 1.7.0 '@scure/bip39': 1.6.0 @@ -13082,38 +13288,8 @@ snapshots: ox@0.6.9(typescript@5.8.2)(zod@3.25.56): dependencies: - '@adraffy/ens-normalize': 1.11.0 - '@noble/curves': 1.9.6 - '@noble/hashes': 1.8.0 - '@scure/bip32': 1.7.0 - '@scure/bip39': 1.6.0 - abitype: 1.1.0(typescript@5.8.2)(zod@3.25.56) - eventemitter3: 5.0.1 - optionalDependencies: - typescript: 5.8.2 - transitivePeerDependencies: - - zod - - ox@0.9.3(typescript@5.8.2)(zod@3.24.2): - dependencies: - '@adraffy/ens-normalize': 1.11.0 - '@noble/ciphers': 1.3.0 - '@noble/curves': 1.9.1 - '@noble/hashes': 1.8.0 - '@scure/bip32': 1.7.0 - '@scure/bip39': 1.6.0 - abitype: 1.1.0(typescript@5.8.2)(zod@3.24.2) - eventemitter3: 5.0.1 - optionalDependencies: - typescript: 5.8.2 - transitivePeerDependencies: - - zod - - ox@0.9.3(typescript@5.8.2)(zod@3.25.56): - dependencies: - '@adraffy/ens-normalize': 1.11.0 - '@noble/ciphers': 1.3.0 - '@noble/curves': 1.9.1 + '@adraffy/ens-normalize': 1.11.1 + '@noble/curves': 1.9.7 '@noble/hashes': 1.8.0 '@scure/bip32': 1.7.0 '@scure/bip39': 1.6.0 @@ -13126,7 +13302,7 @@ snapshots: ox@0.9.6(typescript@5.8.2)(zod@3.22.4): dependencies: - '@adraffy/ens-normalize': 1.11.0 + '@adraffy/ens-normalize': 1.11.1 '@noble/ciphers': 1.3.0 '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -13141,7 +13317,7 @@ snapshots: ox@0.9.6(typescript@5.8.2)(zod@3.24.2): dependencies: - '@adraffy/ens-normalize': 1.11.0 + '@adraffy/ens-normalize': 1.11.1 '@noble/ciphers': 1.3.0 '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -13156,7 +13332,7 @@ snapshots: ox@0.9.6(typescript@5.8.2)(zod@3.25.56): dependencies: - '@adraffy/ens-normalize': 1.11.0 + '@adraffy/ens-normalize': 1.11.1 '@noble/ciphers': 1.3.0 '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -13301,6 +13477,8 @@ snapshots: preact@10.24.2: {} + preact@10.27.2: {} + prelude-ls@1.2.1: {} prettier-linter-helpers@1.0.0: @@ -13619,6 +13797,8 @@ snapshots: semver@7.7.1: {} + semver@7.7.3: {} + send@1.1.0: dependencies: debug: 4.3.6 @@ -13676,6 +13856,12 @@ snapshots: inherits: 2.0.4 safe-buffer: 5.2.1 + sha.js@2.4.12: + dependencies: + inherits: 2.0.4 + safe-buffer: 5.2.1 + to-buffer: 1.2.2 + shebang-command@2.0.0: dependencies: shebang-regex: 3.0.0 @@ -13900,7 +14086,7 @@ snapshots: supports-preserve-symlinks-flag@1.0.0: {} - sushi@6.2.1(typescript@5.8.2)(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.24.2): + sushi@6.2.1(typescript@5.8.2)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.24.2): dependencies: '@uniswap/token-lists': 1.0.0-beta.33 big.js: 6.1.1 @@ -13910,7 +14096,7 @@ snapshots: toformat: 2.0.0 optionalDependencies: typescript: 5.8.2 - viem: 2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) zod: 3.24.2 svix-fetch@3.0.0: @@ -13975,6 +14161,12 @@ snapshots: tmpl@1.0.5: {} + to-buffer@1.2.2: + dependencies: + isarray: 2.0.5 + safe-buffer: 5.2.1 + typed-array-buffer: 1.0.3 + to-regex-range@5.0.1: dependencies: is-number: 7.0.0 @@ -14040,12 +14232,12 @@ snapshots: ts-node@10.9.2(@types/node@20.17.27)(typescript@5.8.2): dependencies: '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.11 + '@tsconfig/node10': 1.0.12 '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 '@types/node': 20.17.27 - acorn: 8.14.1 + acorn: 8.15.0 acorn-walk: 8.3.4 arg: 4.1.3 create-require: 1.1.1 @@ -14059,12 +14251,12 @@ snapshots: ts-node@10.9.2(@types/node@22.13.14)(typescript@5.8.2): dependencies: '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.11 + '@tsconfig/node10': 1.0.12 '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 '@types/node': 22.13.14 - acorn: 8.14.1 + acorn: 8.15.0 acorn-walk: 8.3.4 arg: 4.1.3 create-require: 1.1.1 @@ -14405,7 +14597,7 @@ snapshots: - utf-8-validate - zod - viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2): + viem@2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2): dependencies: '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -14413,24 +14605,7 @@ snapshots: '@scure/bip39': 1.6.0 abitype: 1.1.0(typescript@5.8.2)(zod@3.24.2) isows: 1.0.7(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10)) - ox: 0.9.3(typescript@5.8.2)(zod@3.24.2) - ws: 8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10) - optionalDependencies: - typescript: 5.8.2 - transitivePeerDependencies: - - bufferutil - - utf-8-validate - - zod - - viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56): - dependencies: - '@noble/curves': 1.9.1 - '@noble/hashes': 1.8.0 - '@scure/bip32': 1.7.0 - '@scure/bip39': 1.6.0 - abitype: 1.1.0(typescript@5.8.2)(zod@3.25.56) - isows: 1.0.7(ws@8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10)) - ox: 0.9.3(typescript@5.8.2)(zod@3.25.56) + ox: 0.9.6(typescript@5.8.2)(zod@3.24.2) ws: 8.18.3(bufferutil@4.0.9)(utf-8-validate@5.0.10) optionalDependencies: typescript: 5.8.2 @@ -14439,7 +14614,7 @@ snapshots: - utf-8-validate - zod - viem@2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.22.4): + viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.22.4): dependencies: '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -14456,7 +14631,7 @@ snapshots: - utf-8-validate - zod - viem@2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2): + viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2): dependencies: '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -14473,7 +14648,7 @@ snapshots: - utf-8-validate - zod - viem@2.38.0(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56): + viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56): dependencies: '@noble/curves': 1.9.1 '@noble/hashes': 1.8.0 @@ -14490,14 +14665,14 @@ snapshots: - utf-8-validate - zod - wagmi@2.17.0(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))(zod@3.25.56): + wagmi@2.17.0(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.25.56): dependencies: '@tanstack/react-query': 5.89.0(react@18.3.1) - '@wagmi/connectors': 5.10.0(@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.23.15(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))(zod@3.25.56) - '@wagmi/core': 2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56)) + '@wagmi/connectors': 5.10.0(@wagmi/core@2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.25.56) + '@wagmi/core': 2.21.0(@tanstack/query-core@5.89.0)(react@18.3.1)(typescript@5.8.2)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2)) react: 18.3.1 use-sync-external-store: 1.4.0(react@18.3.1) - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2) optionalDependencies: typescript: 5.8.2 transitivePeerDependencies: @@ -14665,7 +14840,7 @@ snapshots: x402-axios@0.6.0(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)): dependencies: axios: 1.9.0 - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) x402: 0.6.1(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) zod: 3.25.56 transitivePeerDependencies: @@ -14703,6 +14878,45 @@ snapshots: - utf-8-validate - ws + x402-fetch@0.7.0(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)): + dependencies: + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + x402: 0.7.2(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) + zod: 3.25.56 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@deno/kv' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@solana/sysvars' + - '@tanstack/query-core' + - '@tanstack/react-query' + - '@types/react' + - '@upstash/redis' + - '@vercel/blob' + - '@vercel/functions' + - '@vercel/kv' + - aws4fetch + - bufferutil + - db0 + - encoding + - fastestsmallesttextencoderdecoder + - immer + - ioredis + - react + - supports-color + - typescript + - uploadthing + - utf-8-validate + - ws + x402@0.6.1(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)): dependencies: '@scure/base': 1.2.6 @@ -14711,8 +14925,57 @@ snapshots: '@solana-program/token-2022': 0.4.2(@solana/kit@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)))(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)) '@solana/kit': 2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) '@solana/transaction-confirmation': 2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) - viem: 2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) - wagmi: 2.17.0(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.37.5(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56))(zod@3.25.56) + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + wagmi: 2.17.0(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.25.56) + zod: 3.25.56 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@deno/kv' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@solana/sysvars' + - '@tanstack/query-core' + - '@tanstack/react-query' + - '@types/react' + - '@upstash/redis' + - '@vercel/blob' + - '@vercel/functions' + - '@vercel/kv' + - aws4fetch + - bufferutil + - db0 + - encoding + - fastestsmallesttextencoderdecoder + - immer + - ioredis + - react + - supports-color + - typescript + - uploadthing + - utf-8-validate + - ws + + x402@0.7.2(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2))(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(fastestsmallesttextencoderdecoder@1.0.22)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)): + dependencies: + '@scure/base': 1.2.6 + '@solana-program/compute-budget': 0.8.0(@solana/kit@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))) + '@solana-program/token': 0.5.1(@solana/kit@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10))) + '@solana-program/token-2022': 0.4.2(@solana/kit@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)))(@solana/sysvars@2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)) + '@solana/kit': 2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) + '@solana/transaction-confirmation': 2.3.0(fastestsmallesttextencoderdecoder@1.0.22)(typescript@5.8.2)(ws@8.18.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)) + '@solana/wallet-standard-features': 1.3.0 + '@wallet-standard/app': 1.1.0 + '@wallet-standard/base': 1.1.0 + '@wallet-standard/features': 1.1.0 + viem: 2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.25.56) + wagmi: 2.17.0(@tanstack/query-core@5.89.0)(@tanstack/react-query@5.89.0(react@18.3.1))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.2)(utf-8-validate@5.0.10)(viem@2.38.3(bufferutil@4.0.9)(typescript@5.8.2)(utf-8-validate@5.0.10)(zod@3.24.2))(zod@3.25.56) zod: 3.25.56 transitivePeerDependencies: - '@azure/app-configuration'