@compass-labs/api-sdk 0.0.7 → 0.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -8
- package/bin/mcp-server.js +2389 -1146
- package/bin/mcp-server.js.map +48 -24
- package/dist/commonjs/funcs/transactionBatchingAuthorization.d.ts +22 -0
- package/dist/commonjs/funcs/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/commonjs/funcs/{universalTransferErc20.js → transactionBatchingAuthorization.js} +14 -9
- package/dist/commonjs/funcs/transactionBatchingAuthorization.js.map +1 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.d.ts +22 -0
- package/dist/commonjs/funcs/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/commonjs/funcs/{universalTransferNativeToken.js → transactionBatchingExecute.js} +14 -9
- package/dist/commonjs/funcs/transactionBatchingExecute.js.map +1 -0
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/server.js +5 -9
- package/dist/commonjs/mcp-server/server.js.map +1 -1
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.d.ts +8 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/tools/{universalTransferErc20.js → transactionBatchingAuthorization.js} +14 -9
- package/dist/commonjs/mcp-server/tools/transactionBatchingAuthorization.js.map +1 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.d.ts +8 -0
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/tools/{universalTransferNativeToken.js → transactionBatchingExecute.js} +14 -9
- package/dist/commonjs/mcp-server/tools/transactionBatchingExecute.js.map +1 -0
- package/dist/commonjs/models/components/aaveborrowparams.d.ts +82 -0
- package/dist/commonjs/models/components/aaveborrowparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aaveborrowparams.js +111 -0
- package/dist/commonjs/models/components/aaveborrowparams.js.map +1 -0
- package/dist/commonjs/models/components/aaverepayparams.d.ts +82 -0
- package/dist/commonjs/models/components/aaverepayparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aaverepayparams.js +111 -0
- package/dist/commonjs/models/components/aaverepayparams.js.map +1 -0
- package/dist/commonjs/models/components/aavesupplyparams.d.ts +72 -0
- package/dist/commonjs/models/components/aavesupplyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aavesupplyparams.js +106 -0
- package/dist/commonjs/models/components/aavesupplyparams.js.map +1 -0
- package/dist/commonjs/models/components/aavewithdrawparams.d.ts +72 -0
- package/dist/commonjs/models/components/aavewithdrawparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aavewithdrawparams.js +97 -0
- package/dist/commonjs/models/components/aavewithdrawparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityethparams.d.ts +177 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityethparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityethparams.js +191 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityethparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityparams.d.ts +186 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityparams.js +197 -0
- package/dist/commonjs/models/components/aerodromeaddliquidityparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityethrequest.d.ts +151 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityethrequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityethrequest.js +167 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityethrequest.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityrequest.d.ts +161 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityrequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityrequest.js +173 -0
- package/dist/commonjs/models/components/aerodromeremoveliquidityrequest.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreambuyexactlyparams.d.ts +114 -0
- package/dist/commonjs/models/components/aerodromeslipstreambuyexactlyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreambuyexactlyparams.js +141 -0
- package/dist/commonjs/models/components/aerodromeslipstreambuyexactlyparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.d.ts +156 -0
- package/dist/commonjs/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.js +194 -0
- package/dist/commonjs/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreammintliquidityprovisionparams.d.ts +187 -0
- package/dist/commonjs/models/components/aerodromeslipstreammintliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreammintliquidityprovisionparams.js +209 -0
- package/dist/commonjs/models/components/aerodromeslipstreammintliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamsellexactlyparams.d.ts +114 -0
- package/dist/commonjs/models/components/aerodromeslipstreamsellexactlyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamsellexactlyparams.js +141 -0
- package/dist/commonjs/models/components/aerodromeslipstreamsellexactlyparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.d.ts +69 -0
- package/dist/commonjs/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.js +107 -0
- package/dist/commonjs/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeswapethfortokenparams.d.ts +109 -0
- package/dist/commonjs/models/components/aerodromeswapethfortokenparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeswapethfortokenparams.js +137 -0
- package/dist/commonjs/models/components/aerodromeswapethfortokenparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeswaptokenforethparams.d.ts +109 -0
- package/dist/commonjs/models/components/aerodromeswaptokenforethparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeswaptokenforethparams.js +137 -0
- package/dist/commonjs/models/components/aerodromeswaptokenforethparams.js.map +1 -0
- package/dist/commonjs/models/components/aerodromeswaptokensparams.d.ts +128 -0
- package/dist/commonjs/models/components/aerodromeswaptokensparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/aerodromeswaptokensparams.js +141 -0
- package/dist/commonjs/models/components/aerodromeswaptokensparams.js.map +1 -0
- package/dist/commonjs/models/components/contractname.d.ts +96 -0
- package/dist/commonjs/models/components/contractname.d.ts.map +1 -0
- package/dist/commonjs/models/components/contractname.js +85 -0
- package/dist/commonjs/models/components/contractname.js.map +1 -0
- package/dist/commonjs/models/components/increaseallowanceanyparams.d.ts +83 -0
- package/dist/commonjs/models/components/increaseallowanceanyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/increaseallowanceanyparams.js +107 -0
- package/dist/commonjs/models/components/increaseallowanceanyparams.js.map +1 -0
- package/dist/commonjs/models/components/increaseallowanceparams.d.ts +122 -0
- package/dist/commonjs/models/components/increaseallowanceparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/increaseallowanceparams.js +133 -0
- package/dist/commonjs/models/components/increaseallowanceparams.js.map +1 -0
- package/dist/commonjs/models/components/increaseallowancerequest.d.ts +8 -8
- package/dist/commonjs/models/components/increaseallowancerequest.d.ts.map +1 -1
- package/dist/commonjs/models/components/increaseallowancerequest.js +13 -13
- package/dist/commonjs/models/components/increaseallowancerequest.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +34 -4
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +34 -4
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/multicallaction.d.ts +79 -0
- package/dist/commonjs/models/components/multicallaction.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallaction.js +239 -0
- package/dist/commonjs/models/components/multicallaction.js.map +1 -0
- package/dist/commonjs/models/components/multicallactiontype.d.ts +100 -0
- package/dist/commonjs/models/components/multicallactiontype.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallactiontype.js +84 -0
- package/dist/commonjs/models/components/multicallactiontype.js.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationrequest.d.ts +47 -0
- package/dist/commonjs/models/components/multicallauthorizationrequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/{priceresponse.js → multicallauthorizationrequest.js} +22 -28
- package/dist/commonjs/models/components/multicallauthorizationrequest.js.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.d.ts +45 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.d.ts.map +1 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.js +73 -0
- package/dist/commonjs/models/components/multicallauthorizationresponse.js.map +1 -0
- package/dist/commonjs/models/components/multicallexecuterequest.d.ts +50 -0
- package/dist/commonjs/models/components/multicallexecuterequest.d.ts.map +1 -0
- package/dist/commonjs/models/components/{balanceinforesponse.js → multicallexecuterequest.js} +30 -30
- package/dist/commonjs/models/components/multicallexecuterequest.js.map +1 -0
- package/dist/commonjs/models/components/signedauthorization.d.ts +81 -0
- package/dist/commonjs/models/components/signedauthorization.d.ts.map +1 -0
- package/dist/commonjs/models/components/signedauthorization.js +131 -0
- package/dist/commonjs/models/components/signedauthorization.js.map +1 -0
- package/dist/commonjs/models/components/tokentransfererc20params.d.ts +75 -0
- package/dist/commonjs/models/components/tokentransfererc20params.d.ts.map +1 -0
- package/dist/commonjs/models/components/tokentransfererc20params.js +97 -0
- package/dist/commonjs/models/components/tokentransfererc20params.js.map +1 -0
- package/dist/commonjs/models/components/uniswapbuyexactlyparams.d.ts +121 -0
- package/dist/commonjs/models/components/uniswapbuyexactlyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/uniswapbuyexactlyparams.js +144 -0
- package/dist/commonjs/models/components/uniswapbuyexactlyparams.js.map +1 -0
- package/dist/commonjs/models/components/uniswapincreaseliquidityprovisionparams.d.ts +148 -0
- package/dist/commonjs/models/components/uniswapincreaseliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/uniswapincreaseliquidityprovisionparams.js +186 -0
- package/dist/commonjs/models/components/uniswapincreaseliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/uniswapmintliquidityprovisionparams.d.ts +189 -0
- package/dist/commonjs/models/components/uniswapmintliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/uniswapmintliquidityprovisionparams.js +200 -0
- package/dist/commonjs/models/components/uniswapmintliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/uniswapsellexactlyparams.d.ts +124 -0
- package/dist/commonjs/models/components/uniswapsellexactlyparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/uniswapsellexactlyparams.js +144 -0
- package/dist/commonjs/models/components/uniswapsellexactlyparams.js.map +1 -0
- package/dist/commonjs/models/components/uniswapwithdrawliquidityprovisionparams.d.ts +69 -0
- package/dist/commonjs/models/components/uniswapwithdrawliquidityprovisionparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/uniswapwithdrawliquidityprovisionparams.js +107 -0
- package/dist/commonjs/models/components/uniswapwithdrawliquidityprovisionparams.js.map +1 -0
- package/dist/commonjs/models/components/unsignedmulticalltransaction.d.ts +78 -0
- package/dist/commonjs/models/components/unsignedmulticalltransaction.d.ts.map +1 -0
- package/dist/commonjs/models/components/unsignedmulticalltransaction.js +88 -0
- package/dist/commonjs/models/components/unsignedmulticalltransaction.js.map +1 -0
- package/dist/commonjs/models/components/unwrapwethparams.d.ts +59 -0
- package/dist/commonjs/models/components/unwrapwethparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/unwrapwethparams.js +92 -0
- package/dist/commonjs/models/components/unwrapwethparams.js.map +1 -0
- package/dist/commonjs/models/components/wrapethparams.d.ts +59 -0
- package/dist/commonjs/models/components/wrapethparams.d.ts.map +1 -0
- package/dist/commonjs/models/components/wrapethparams.js +92 -0
- package/dist/commonjs/models/components/wrapethparams.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +0 -2
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +0 -2
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/sdk/sdk.d.ts +3 -0
- package/dist/commonjs/sdk/sdk.d.ts.map +1 -1
- package/dist/commonjs/sdk/sdk.js +4 -0
- package/dist/commonjs/sdk/sdk.js.map +1 -1
- package/dist/commonjs/sdk/transactionbatching.d.ts +29 -0
- package/dist/commonjs/sdk/transactionbatching.d.ts.map +1 -0
- package/dist/commonjs/sdk/transactionbatching.js +42 -0
- package/dist/commonjs/sdk/transactionbatching.js.map +1 -0
- package/dist/commonjs/sdk/universal.d.ts +0 -33
- package/dist/commonjs/sdk/universal.d.ts.map +1 -1
- package/dist/commonjs/sdk/universal.js +0 -45
- package/dist/commonjs/sdk/universal.js.map +1 -1
- package/dist/esm/funcs/transactionBatchingAuthorization.d.ts +22 -0
- package/dist/esm/funcs/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/esm/funcs/{universalTransferNativeToken.js → transactionBatchingAuthorization.js} +13 -8
- package/dist/esm/funcs/transactionBatchingAuthorization.js.map +1 -0
- package/dist/esm/funcs/transactionBatchingExecute.d.ts +22 -0
- package/dist/esm/funcs/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/esm/funcs/{universalTransferErc20.js → transactionBatchingExecute.js} +13 -8
- package/dist/esm/funcs/transactionBatchingExecute.js.map +1 -0
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.d.ts.map +1 -1
- package/dist/esm/mcp-server/server.js +5 -9
- package/dist/esm/mcp-server/server.js.map +1 -1
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.d.ts +8 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.d.ts.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.js +33 -0
- package/dist/esm/mcp-server/tools/transactionBatchingAuthorization.js.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.d.ts +8 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.d.ts.map +1 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.js +33 -0
- package/dist/esm/mcp-server/tools/transactionBatchingExecute.js.map +1 -0
- package/dist/esm/models/components/aaveborrowparams.d.ts +82 -0
- package/dist/esm/models/components/aaveborrowparams.d.ts.map +1 -0
- package/dist/esm/models/components/aaveborrowparams.js +71 -0
- package/dist/esm/models/components/aaveborrowparams.js.map +1 -0
- package/dist/esm/models/components/aaverepayparams.d.ts +82 -0
- package/dist/esm/models/components/aaverepayparams.d.ts.map +1 -0
- package/dist/esm/models/components/aaverepayparams.js +71 -0
- package/dist/esm/models/components/aaverepayparams.js.map +1 -0
- package/dist/esm/models/components/aavesupplyparams.d.ts +72 -0
- package/dist/esm/models/components/aavesupplyparams.d.ts.map +1 -0
- package/dist/esm/models/components/aavesupplyparams.js +66 -0
- package/dist/esm/models/components/aavesupplyparams.js.map +1 -0
- package/dist/esm/models/components/aavewithdrawparams.d.ts +72 -0
- package/dist/esm/models/components/aavewithdrawparams.d.ts.map +1 -0
- package/dist/esm/models/components/aavewithdrawparams.js +57 -0
- package/dist/esm/models/components/aavewithdrawparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeaddliquidityethparams.d.ts +177 -0
- package/dist/esm/models/components/aerodromeaddliquidityethparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeaddliquidityethparams.js +145 -0
- package/dist/esm/models/components/aerodromeaddliquidityethparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeaddliquidityparams.d.ts +186 -0
- package/dist/esm/models/components/aerodromeaddliquidityparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeaddliquidityparams.js +151 -0
- package/dist/esm/models/components/aerodromeaddliquidityparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeremoveliquidityethrequest.d.ts +151 -0
- package/dist/esm/models/components/aerodromeremoveliquidityethrequest.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeremoveliquidityethrequest.js +123 -0
- package/dist/esm/models/components/aerodromeremoveliquidityethrequest.js.map +1 -0
- package/dist/esm/models/components/aerodromeremoveliquidityrequest.d.ts +161 -0
- package/dist/esm/models/components/aerodromeremoveliquidityrequest.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeremoveliquidityrequest.js +129 -0
- package/dist/esm/models/components/aerodromeremoveliquidityrequest.js.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreambuyexactlyparams.d.ts +114 -0
- package/dist/esm/models/components/aerodromeslipstreambuyexactlyparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreambuyexactlyparams.js +99 -0
- package/dist/esm/models/components/aerodromeslipstreambuyexactlyparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.d.ts +156 -0
- package/dist/esm/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.js +148 -0
- package/dist/esm/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreammintliquidityprovisionparams.d.ts +187 -0
- package/dist/esm/models/components/aerodromeslipstreammintliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreammintliquidityprovisionparams.js +163 -0
- package/dist/esm/models/components/aerodromeslipstreammintliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamsellexactlyparams.d.ts +114 -0
- package/dist/esm/models/components/aerodromeslipstreamsellexactlyparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamsellexactlyparams.js +99 -0
- package/dist/esm/models/components/aerodromeslipstreamsellexactlyparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.d.ts +69 -0
- package/dist/esm/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.js +67 -0
- package/dist/esm/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeswapethfortokenparams.d.ts +109 -0
- package/dist/esm/models/components/aerodromeswapethfortokenparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeswapethfortokenparams.js +95 -0
- package/dist/esm/models/components/aerodromeswapethfortokenparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeswaptokenforethparams.d.ts +109 -0
- package/dist/esm/models/components/aerodromeswaptokenforethparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeswaptokenforethparams.js +95 -0
- package/dist/esm/models/components/aerodromeswaptokenforethparams.js.map +1 -0
- package/dist/esm/models/components/aerodromeswaptokensparams.d.ts +128 -0
- package/dist/esm/models/components/aerodromeswaptokensparams.d.ts.map +1 -0
- package/dist/esm/models/components/aerodromeswaptokensparams.js +99 -0
- package/dist/esm/models/components/aerodromeswaptokensparams.js.map +1 -0
- package/dist/esm/models/components/contractname.d.ts +96 -0
- package/dist/esm/models/components/contractname.d.ts.map +1 -0
- package/dist/esm/models/components/contractname.js +49 -0
- package/dist/esm/models/components/contractname.js.map +1 -0
- package/dist/esm/models/components/increaseallowanceanyparams.d.ts +83 -0
- package/dist/esm/models/components/increaseallowanceanyparams.d.ts.map +1 -0
- package/dist/esm/models/components/increaseallowanceanyparams.js +67 -0
- package/dist/esm/models/components/increaseallowanceanyparams.js.map +1 -0
- package/dist/esm/models/components/increaseallowanceparams.d.ts +122 -0
- package/dist/esm/models/components/increaseallowanceparams.d.ts.map +1 -0
- package/dist/esm/models/components/increaseallowanceparams.js +93 -0
- package/dist/esm/models/components/increaseallowanceparams.js.map +1 -0
- package/dist/esm/models/components/increaseallowancerequest.d.ts +8 -8
- package/dist/esm/models/components/increaseallowancerequest.d.ts.map +1 -1
- package/dist/esm/models/components/increaseallowancerequest.js +12 -12
- package/dist/esm/models/components/increaseallowancerequest.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +34 -4
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +34 -4
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/multicallaction.d.ts +79 -0
- package/dist/esm/models/components/multicallaction.d.ts.map +1 -0
- package/dist/esm/models/components/multicallaction.js +199 -0
- package/dist/esm/models/components/multicallaction.js.map +1 -0
- package/dist/esm/models/components/multicallactiontype.d.ts +100 -0
- package/dist/esm/models/components/multicallactiontype.d.ts.map +1 -0
- package/dist/esm/models/components/multicallactiontype.js +48 -0
- package/dist/esm/models/components/multicallactiontype.js.map +1 -0
- package/dist/esm/models/components/multicallauthorizationrequest.d.ts +47 -0
- package/dist/esm/models/components/multicallauthorizationrequest.d.ts.map +1 -0
- package/dist/esm/models/components/multicallauthorizationrequest.js +34 -0
- package/dist/esm/models/components/multicallauthorizationrequest.js.map +1 -0
- package/dist/esm/models/components/multicallauthorizationresponse.d.ts +45 -0
- package/dist/esm/models/components/multicallauthorizationresponse.d.ts.map +1 -0
- package/dist/esm/models/components/multicallauthorizationresponse.js +35 -0
- package/dist/esm/models/components/multicallauthorizationresponse.js.map +1 -0
- package/dist/esm/models/components/multicallexecuterequest.d.ts +50 -0
- package/dist/esm/models/components/multicallexecuterequest.d.ts.map +1 -0
- package/dist/esm/models/components/multicallexecuterequest.js +49 -0
- package/dist/esm/models/components/multicallexecuterequest.js.map +1 -0
- package/dist/esm/models/components/signedauthorization.d.ts +81 -0
- package/dist/esm/models/components/signedauthorization.d.ts.map +1 -0
- package/dist/esm/models/components/signedauthorization.js +89 -0
- package/dist/esm/models/components/signedauthorization.js.map +1 -0
- package/dist/esm/models/components/tokentransfererc20params.d.ts +75 -0
- package/dist/esm/models/components/tokentransfererc20params.d.ts.map +1 -0
- package/dist/esm/models/components/tokentransfererc20params.js +57 -0
- package/dist/esm/models/components/tokentransfererc20params.js.map +1 -0
- package/dist/esm/models/components/uniswapbuyexactlyparams.d.ts +121 -0
- package/dist/esm/models/components/uniswapbuyexactlyparams.d.ts.map +1 -0
- package/dist/esm/models/components/uniswapbuyexactlyparams.js +102 -0
- package/dist/esm/models/components/uniswapbuyexactlyparams.js.map +1 -0
- package/dist/esm/models/components/uniswapincreaseliquidityprovisionparams.d.ts +148 -0
- package/dist/esm/models/components/uniswapincreaseliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/uniswapincreaseliquidityprovisionparams.js +140 -0
- package/dist/esm/models/components/uniswapincreaseliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/uniswapmintliquidityprovisionparams.d.ts +189 -0
- package/dist/esm/models/components/uniswapmintliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/uniswapmintliquidityprovisionparams.js +154 -0
- package/dist/esm/models/components/uniswapmintliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/uniswapsellexactlyparams.d.ts +124 -0
- package/dist/esm/models/components/uniswapsellexactlyparams.d.ts.map +1 -0
- package/dist/esm/models/components/uniswapsellexactlyparams.js +102 -0
- package/dist/esm/models/components/uniswapsellexactlyparams.js.map +1 -0
- package/dist/esm/models/components/uniswapwithdrawliquidityprovisionparams.d.ts +69 -0
- package/dist/esm/models/components/uniswapwithdrawliquidityprovisionparams.d.ts.map +1 -0
- package/dist/esm/models/components/uniswapwithdrawliquidityprovisionparams.js +67 -0
- package/dist/esm/models/components/uniswapwithdrawliquidityprovisionparams.js.map +1 -0
- package/dist/esm/models/components/unsignedmulticalltransaction.d.ts +78 -0
- package/dist/esm/models/components/unsignedmulticalltransaction.d.ts.map +1 -0
- package/dist/esm/models/components/unsignedmulticalltransaction.js +50 -0
- package/dist/esm/models/components/unsignedmulticalltransaction.js.map +1 -0
- package/dist/esm/models/components/unwrapwethparams.d.ts +59 -0
- package/dist/esm/models/components/unwrapwethparams.d.ts.map +1 -0
- package/dist/esm/models/components/unwrapwethparams.js +52 -0
- package/dist/esm/models/components/unwrapwethparams.js.map +1 -0
- package/dist/esm/models/components/wrapethparams.d.ts +59 -0
- package/dist/esm/models/components/wrapethparams.d.ts.map +1 -0
- package/dist/esm/models/components/wrapethparams.js +52 -0
- package/dist/esm/models/components/wrapethparams.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +0 -2
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +0 -2
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/sdk/sdk.d.ts +3 -0
- package/dist/esm/sdk/sdk.d.ts.map +1 -1
- package/dist/esm/sdk/sdk.js +4 -0
- package/dist/esm/sdk/sdk.js.map +1 -1
- package/dist/esm/sdk/transactionbatching.d.ts +29 -0
- package/dist/esm/sdk/transactionbatching.d.ts.map +1 -0
- package/dist/esm/sdk/transactionbatching.js +38 -0
- package/dist/esm/sdk/transactionbatching.js.map +1 -0
- package/dist/esm/sdk/universal.d.ts +0 -33
- package/dist/esm/sdk/universal.d.ts.map +1 -1
- package/dist/esm/sdk/universal.js +0 -45
- package/dist/esm/sdk/universal.js.map +1 -1
- package/docs/sdks/aavev3/README.md +4 -0
- package/docs/sdks/transactionbatching/README.md +217 -0
- package/docs/sdks/universal/README.md +0 -335
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/{universalTransferNativeToken.ts → transactionBatchingAuthorization.ts} +18 -12
- package/src/funcs/{universalTransferErc20.ts → transactionBatchingExecute.ts} +17 -12
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +5 -9
- package/src/mcp-server/tools/transactionBatchingAuthorization.ts +44 -0
- package/src/mcp-server/tools/transactionBatchingExecute.ts +42 -0
- package/src/models/components/aaveborrowparams.ts +173 -0
- package/src/models/components/aaverepayparams.ts +171 -0
- package/src/models/components/aavesupplyparams.ts +155 -0
- package/src/models/components/aavewithdrawparams.ts +146 -0
- package/src/models/components/aerodromeaddliquidityethparams.ts +392 -0
- package/src/models/components/aerodromeaddliquidityparams.ts +382 -0
- package/src/models/components/aerodromeremoveliquidityethrequest.ts +357 -0
- package/src/models/components/aerodromeremoveliquidityrequest.ts +363 -0
- package/src/models/components/aerodromeslipstreambuyexactlyparams.ts +276 -0
- package/src/models/components/aerodromeslipstreamincreaseliquidityprovisionparams.ts +412 -0
- package/src/models/components/aerodromeslipstreammintliquidityprovisionparams.ts +461 -0
- package/src/models/components/aerodromeslipstreamsellexactlyparams.ts +276 -0
- package/src/models/components/aerodromeslipstreamwithdrawliquidityprovisionparams.ts +180 -0
- package/src/models/components/aerodromeswapethfortokenparams.ts +249 -0
- package/src/models/components/aerodromeswaptokenforethparams.ts +249 -0
- package/src/models/components/aerodromeswaptokensparams.ts +260 -0
- package/src/models/components/contractname.ts +64 -0
- package/src/models/components/increaseallowanceanyparams.ts +172 -0
- package/src/models/components/increaseallowanceparams.ts +204 -0
- package/src/models/components/increaseallowancerequest.ts +21 -14
- package/src/models/components/index.ts +34 -4
- package/src/models/components/multicallaction.ts +490 -0
- package/src/models/components/multicallactiontype.ts +59 -0
- package/src/models/components/multicallauthorizationrequest.ts +88 -0
- package/src/models/components/multicallauthorizationresponse.ts +88 -0
- package/src/models/components/multicallexecuterequest.ts +112 -0
- package/src/models/components/signedauthorization.ts +172 -0
- package/src/models/components/tokentransfererc20params.ts +151 -0
- package/src/models/components/uniswapbuyexactlyparams.ts +259 -0
- package/src/models/components/uniswapincreaseliquidityprovisionparams.ts +405 -0
- package/src/models/components/uniswapmintliquidityprovisionparams.ts +454 -0
- package/src/models/components/uniswapsellexactlyparams.ts +267 -0
- package/src/models/components/uniswapwithdrawliquidityprovisionparams.ts +175 -0
- package/src/models/components/unsignedmulticalltransaction.ts +140 -0
- package/src/models/components/unwrapwethparams.ts +125 -0
- package/src/models/components/wrapethparams.ts +121 -0
- package/src/models/operations/index.ts +0 -2
- package/src/sdk/sdk.ts +8 -0
- package/src/sdk/transactionbatching.ts +55 -0
- package/src/sdk/universal.ts +0 -77
- package/dist/commonjs/funcs/universalBalance.d.ts +0 -18
- package/dist/commonjs/funcs/universalBalance.d.ts.map +0 -1
- package/dist/commonjs/funcs/universalBalance.js +0 -122
- package/dist/commonjs/funcs/universalBalance.js.map +0 -1
- package/dist/commonjs/funcs/universalPriceUsd.d.ts +0 -23
- package/dist/commonjs/funcs/universalPriceUsd.d.ts.map +0 -1
- package/dist/commonjs/funcs/universalPriceUsd.js +0 -126
- package/dist/commonjs/funcs/universalPriceUsd.js.map +0 -1
- package/dist/commonjs/funcs/universalTransferErc20.d.ts +0 -17
- package/dist/commonjs/funcs/universalTransferErc20.d.ts.map +0 -1
- package/dist/commonjs/funcs/universalTransferErc20.js.map +0 -1
- package/dist/commonjs/funcs/universalTransferNativeToken.d.ts +0 -17
- package/dist/commonjs/funcs/universalTransferNativeToken.d.ts.map +0 -1
- package/dist/commonjs/funcs/universalTransferNativeToken.js.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalBalance.d.ts +0 -8
- package/dist/commonjs/mcp-server/tools/universalBalance.d.ts.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalBalance.js +0 -64
- package/dist/commonjs/mcp-server/tools/universalBalance.js.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalPriceUsd.d.ts +0 -8
- package/dist/commonjs/mcp-server/tools/universalPriceUsd.d.ts.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalPriceUsd.js +0 -69
- package/dist/commonjs/mcp-server/tools/universalPriceUsd.js.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalTransferErc20.d.ts +0 -8
- package/dist/commonjs/mcp-server/tools/universalTransferErc20.d.ts.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalTransferErc20.js.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalTransferNativeToken.d.ts +0 -8
- package/dist/commonjs/mcp-server/tools/universalTransferNativeToken.d.ts.map +0 -1
- package/dist/commonjs/mcp-server/tools/universalTransferNativeToken.js.map +0 -1
- package/dist/commonjs/models/components/balanceinforesponse.d.ts +0 -56
- package/dist/commonjs/models/components/balanceinforesponse.d.ts.map +0 -1
- package/dist/commonjs/models/components/balanceinforesponse.js.map +0 -1
- package/dist/commonjs/models/components/priceresponse.d.ts +0 -32
- package/dist/commonjs/models/components/priceresponse.d.ts.map +0 -1
- package/dist/commonjs/models/components/priceresponse.js.map +0 -1
- package/dist/commonjs/models/components/transfererc20request.d.ts +0 -86
- package/dist/commonjs/models/components/transfererc20request.d.ts.map +0 -1
- package/dist/commonjs/models/components/transfererc20request.js +0 -102
- package/dist/commonjs/models/components/transfererc20request.js.map +0 -1
- package/dist/commonjs/models/components/transferethrequest.d.ts +0 -75
- package/dist/commonjs/models/components/transferethrequest.d.ts.map +0 -1
- package/dist/commonjs/models/components/transferethrequest.js +0 -99
- package/dist/commonjs/models/components/transferethrequest.js.map +0 -1
- package/dist/commonjs/models/operations/genericbalance.d.ts +0 -246
- package/dist/commonjs/models/operations/genericbalance.d.ts.map +0 -1
- package/dist/commonjs/models/operations/genericbalance.js +0 -165
- package/dist/commonjs/models/operations/genericbalance.js.map +0 -1
- package/dist/commonjs/models/operations/genericpriceusd.d.ts +0 -244
- package/dist/commonjs/models/operations/genericpriceusd.d.ts.map +0 -1
- package/dist/commonjs/models/operations/genericpriceusd.js +0 -163
- package/dist/commonjs/models/operations/genericpriceusd.js.map +0 -1
- package/dist/esm/funcs/universalBalance.d.ts +0 -18
- package/dist/esm/funcs/universalBalance.d.ts.map +0 -1
- package/dist/esm/funcs/universalBalance.js +0 -86
- package/dist/esm/funcs/universalBalance.js.map +0 -1
- package/dist/esm/funcs/universalPriceUsd.d.ts +0 -23
- package/dist/esm/funcs/universalPriceUsd.d.ts.map +0 -1
- package/dist/esm/funcs/universalPriceUsd.js +0 -90
- package/dist/esm/funcs/universalPriceUsd.js.map +0 -1
- package/dist/esm/funcs/universalTransferErc20.d.ts +0 -17
- package/dist/esm/funcs/universalTransferErc20.d.ts.map +0 -1
- package/dist/esm/funcs/universalTransferErc20.js.map +0 -1
- package/dist/esm/funcs/universalTransferNativeToken.d.ts +0 -17
- package/dist/esm/funcs/universalTransferNativeToken.d.ts.map +0 -1
- package/dist/esm/funcs/universalTransferNativeToken.js.map +0 -1
- package/dist/esm/mcp-server/tools/universalBalance.d.ts +0 -8
- package/dist/esm/mcp-server/tools/universalBalance.d.ts.map +0 -1
- package/dist/esm/mcp-server/tools/universalBalance.js +0 -28
- package/dist/esm/mcp-server/tools/universalBalance.js.map +0 -1
- package/dist/esm/mcp-server/tools/universalPriceUsd.d.ts +0 -8
- package/dist/esm/mcp-server/tools/universalPriceUsd.d.ts.map +0 -1
- package/dist/esm/mcp-server/tools/universalPriceUsd.js +0 -33
- package/dist/esm/mcp-server/tools/universalPriceUsd.js.map +0 -1
- package/dist/esm/mcp-server/tools/universalTransferErc20.d.ts +0 -8
- package/dist/esm/mcp-server/tools/universalTransferErc20.d.ts.map +0 -1
- package/dist/esm/mcp-server/tools/universalTransferErc20.js +0 -28
- package/dist/esm/mcp-server/tools/universalTransferErc20.js.map +0 -1
- package/dist/esm/mcp-server/tools/universalTransferNativeToken.d.ts +0 -8
- package/dist/esm/mcp-server/tools/universalTransferNativeToken.d.ts.map +0 -1
- package/dist/esm/mcp-server/tools/universalTransferNativeToken.js +0 -28
- package/dist/esm/mcp-server/tools/universalTransferNativeToken.js.map +0 -1
- package/dist/esm/models/components/balanceinforesponse.d.ts +0 -56
- package/dist/esm/models/components/balanceinforesponse.d.ts.map +0 -1
- package/dist/esm/models/components/balanceinforesponse.js +0 -49
- package/dist/esm/models/components/balanceinforesponse.js.map +0 -1
- package/dist/esm/models/components/priceresponse.d.ts +0 -32
- package/dist/esm/models/components/priceresponse.d.ts.map +0 -1
- package/dist/esm/models/components/priceresponse.js +0 -40
- package/dist/esm/models/components/priceresponse.js.map +0 -1
- package/dist/esm/models/components/transfererc20request.d.ts +0 -86
- package/dist/esm/models/components/transfererc20request.d.ts.map +0 -1
- package/dist/esm/models/components/transfererc20request.js +0 -62
- package/dist/esm/models/components/transfererc20request.js.map +0 -1
- package/dist/esm/models/components/transferethrequest.d.ts +0 -75
- package/dist/esm/models/components/transferethrequest.d.ts.map +0 -1
- package/dist/esm/models/components/transferethrequest.js +0 -59
- package/dist/esm/models/components/transferethrequest.js.map +0 -1
- package/dist/esm/models/operations/genericbalance.d.ts +0 -246
- package/dist/esm/models/operations/genericbalance.d.ts.map +0 -1
- package/dist/esm/models/operations/genericbalance.js +0 -127
- package/dist/esm/models/operations/genericbalance.js.map +0 -1
- package/dist/esm/models/operations/genericpriceusd.d.ts +0 -244
- package/dist/esm/models/operations/genericpriceusd.d.ts.map +0 -1
- package/dist/esm/models/operations/genericpriceusd.js +0 -125
- package/dist/esm/models/operations/genericpriceusd.js.map +0 -1
- package/src/funcs/universalBalance.ts +0 -170
- package/src/funcs/universalPriceUsd.ts +0 -174
- package/src/mcp-server/tools/universalBalance.ts +0 -37
- package/src/mcp-server/tools/universalPriceUsd.ts +0 -42
- package/src/mcp-server/tools/universalTransferErc20.ts +0 -37
- package/src/mcp-server/tools/universalTransferNativeToken.ts +0 -37
- package/src/models/components/balanceinforesponse.ts +0 -114
- package/src/models/components/priceresponse.ts +0 -74
- package/src/models/components/transfererc20request.ts +0 -164
- package/src/models/components/transferethrequest.ts +0 -147
- package/src/models/operations/genericbalance.ts +0 -205
- package/src/models/operations/genericpriceusd.ts +0 -201
|
@@ -1,174 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { CompassApiSDKCore } from "../core.js";
|
|
6
|
-
import { encodeFormQuery } from "../lib/encodings.js";
|
|
7
|
-
import * as M from "../lib/matchers.js";
|
|
8
|
-
import { compactMap } from "../lib/primitives.js";
|
|
9
|
-
import { safeParse } from "../lib/schemas.js";
|
|
10
|
-
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
-
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
-
import { pathToFunc } from "../lib/url.js";
|
|
13
|
-
import * as components from "../models/components/index.js";
|
|
14
|
-
import { APIError } from "../models/errors/apierror.js";
|
|
15
|
-
import {
|
|
16
|
-
ConnectionError,
|
|
17
|
-
InvalidRequestError,
|
|
18
|
-
RequestAbortedError,
|
|
19
|
-
RequestTimeoutError,
|
|
20
|
-
UnexpectedClientError,
|
|
21
|
-
} from "../models/errors/httpclienterrors.js";
|
|
22
|
-
import * as errors from "../models/errors/index.js";
|
|
23
|
-
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
-
import * as operations from "../models/operations/index.js";
|
|
25
|
-
import { APICall, APIPromise } from "../types/async.js";
|
|
26
|
-
import { Result } from "../types/fp.js";
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* Token price
|
|
30
|
-
*
|
|
31
|
-
* @remarks
|
|
32
|
-
* Retrieves the price of the specified token relative to USD using Chainlink's on-
|
|
33
|
-
* chain price feeds.
|
|
34
|
-
*
|
|
35
|
-
* Chainlink is a decentralized oracle that aggregates price data from off-chain
|
|
36
|
-
* sources. This ensures the price is tamper-resistant but the price might be stale
|
|
37
|
-
* with the update frequency of the oracle.
|
|
38
|
-
*/
|
|
39
|
-
export function universalPriceUsd(
|
|
40
|
-
client: CompassApiSDKCore,
|
|
41
|
-
request: operations.GenericPriceUsdRequest,
|
|
42
|
-
options?: RequestOptions,
|
|
43
|
-
): APIPromise<
|
|
44
|
-
Result<
|
|
45
|
-
components.PriceResponse,
|
|
46
|
-
| errors.HTTPValidationError
|
|
47
|
-
| APIError
|
|
48
|
-
| SDKValidationError
|
|
49
|
-
| UnexpectedClientError
|
|
50
|
-
| InvalidRequestError
|
|
51
|
-
| RequestAbortedError
|
|
52
|
-
| RequestTimeoutError
|
|
53
|
-
| ConnectionError
|
|
54
|
-
>
|
|
55
|
-
> {
|
|
56
|
-
return new APIPromise($do(
|
|
57
|
-
client,
|
|
58
|
-
request,
|
|
59
|
-
options,
|
|
60
|
-
));
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
async function $do(
|
|
64
|
-
client: CompassApiSDKCore,
|
|
65
|
-
request: operations.GenericPriceUsdRequest,
|
|
66
|
-
options?: RequestOptions,
|
|
67
|
-
): Promise<
|
|
68
|
-
[
|
|
69
|
-
Result<
|
|
70
|
-
components.PriceResponse,
|
|
71
|
-
| errors.HTTPValidationError
|
|
72
|
-
| APIError
|
|
73
|
-
| SDKValidationError
|
|
74
|
-
| UnexpectedClientError
|
|
75
|
-
| InvalidRequestError
|
|
76
|
-
| RequestAbortedError
|
|
77
|
-
| RequestTimeoutError
|
|
78
|
-
| ConnectionError
|
|
79
|
-
>,
|
|
80
|
-
APICall,
|
|
81
|
-
]
|
|
82
|
-
> {
|
|
83
|
-
const parsed = safeParse(
|
|
84
|
-
request,
|
|
85
|
-
(value) => operations.GenericPriceUsdRequest$outboundSchema.parse(value),
|
|
86
|
-
"Input validation failed",
|
|
87
|
-
);
|
|
88
|
-
if (!parsed.ok) {
|
|
89
|
-
return [parsed, { status: "invalid" }];
|
|
90
|
-
}
|
|
91
|
-
const payload = parsed.value;
|
|
92
|
-
const body = null;
|
|
93
|
-
|
|
94
|
-
const path = pathToFunc("/v0/generic/price/usd/get")();
|
|
95
|
-
|
|
96
|
-
const query = encodeFormQuery({
|
|
97
|
-
"chain": payload.chain,
|
|
98
|
-
"token": payload.token,
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
const headers = new Headers(compactMap({
|
|
102
|
-
Accept: "application/json",
|
|
103
|
-
}));
|
|
104
|
-
|
|
105
|
-
const secConfig = await extractSecurity(client._options.apiKeyAuth);
|
|
106
|
-
const securityInput = secConfig == null ? {} : { apiKeyAuth: secConfig };
|
|
107
|
-
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
108
|
-
|
|
109
|
-
const context = {
|
|
110
|
-
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
111
|
-
operationID: "generic_price_usd",
|
|
112
|
-
oAuth2Scopes: [],
|
|
113
|
-
|
|
114
|
-
resolvedSecurity: requestSecurity,
|
|
115
|
-
|
|
116
|
-
securitySource: client._options.apiKeyAuth,
|
|
117
|
-
retryConfig: options?.retries
|
|
118
|
-
|| client._options.retryConfig
|
|
119
|
-
|| { strategy: "none" },
|
|
120
|
-
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
121
|
-
};
|
|
122
|
-
|
|
123
|
-
const requestRes = client._createRequest(context, {
|
|
124
|
-
security: requestSecurity,
|
|
125
|
-
method: "GET",
|
|
126
|
-
baseURL: options?.serverURL,
|
|
127
|
-
path: path,
|
|
128
|
-
headers: headers,
|
|
129
|
-
query: query,
|
|
130
|
-
body: body,
|
|
131
|
-
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
132
|
-
}, options);
|
|
133
|
-
if (!requestRes.ok) {
|
|
134
|
-
return [requestRes, { status: "invalid" }];
|
|
135
|
-
}
|
|
136
|
-
const req = requestRes.value;
|
|
137
|
-
|
|
138
|
-
const doResult = await client._do(req, {
|
|
139
|
-
context,
|
|
140
|
-
errorCodes: ["422", "4XX", "5XX"],
|
|
141
|
-
retryConfig: context.retryConfig,
|
|
142
|
-
retryCodes: context.retryCodes,
|
|
143
|
-
});
|
|
144
|
-
if (!doResult.ok) {
|
|
145
|
-
return [doResult, { status: "request-error", request: req }];
|
|
146
|
-
}
|
|
147
|
-
const response = doResult.value;
|
|
148
|
-
|
|
149
|
-
const responseFields = {
|
|
150
|
-
HttpMeta: { Response: response, Request: req },
|
|
151
|
-
};
|
|
152
|
-
|
|
153
|
-
const [result] = await M.match<
|
|
154
|
-
components.PriceResponse,
|
|
155
|
-
| errors.HTTPValidationError
|
|
156
|
-
| APIError
|
|
157
|
-
| SDKValidationError
|
|
158
|
-
| UnexpectedClientError
|
|
159
|
-
| InvalidRequestError
|
|
160
|
-
| RequestAbortedError
|
|
161
|
-
| RequestTimeoutError
|
|
162
|
-
| ConnectionError
|
|
163
|
-
>(
|
|
164
|
-
M.json(200, components.PriceResponse$inboundSchema),
|
|
165
|
-
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
166
|
-
M.fail("4XX"),
|
|
167
|
-
M.fail("5XX"),
|
|
168
|
-
)(response, { extraFields: responseFields });
|
|
169
|
-
if (!result.ok) {
|
|
170
|
-
return [result, { status: "complete", request: req, response }];
|
|
171
|
-
}
|
|
172
|
-
|
|
173
|
-
return [result, { status: "complete", request: req, response }];
|
|
174
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { universalBalance } from "../../funcs/universalBalance.js";
|
|
6
|
-
import * as operations from "../../models/operations/index.js";
|
|
7
|
-
import { formatResult, ToolDefinition } from "../tools.js";
|
|
8
|
-
|
|
9
|
-
const args = {
|
|
10
|
-
request: operations.GenericBalanceRequest$inboundSchema,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export const tool$universalBalance: ToolDefinition<typeof args> = {
|
|
14
|
-
name: "universal-balance",
|
|
15
|
-
description: `User Token Balance
|
|
16
|
-
|
|
17
|
-
Returns the balance of a specific ERC20 token for a given user address.`,
|
|
18
|
-
args,
|
|
19
|
-
tool: async (client, args, ctx) => {
|
|
20
|
-
const [result, apiCall] = await universalBalance(
|
|
21
|
-
client,
|
|
22
|
-
args.request,
|
|
23
|
-
{ fetchOptions: { signal: ctx.signal } },
|
|
24
|
-
).$inspect();
|
|
25
|
-
|
|
26
|
-
if (!result.ok) {
|
|
27
|
-
return {
|
|
28
|
-
content: [{ type: "text", text: result.error.message }],
|
|
29
|
-
isError: true,
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
const value = result.value;
|
|
34
|
-
|
|
35
|
-
return formatResult(value, apiCall);
|
|
36
|
-
},
|
|
37
|
-
};
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { universalPriceUsd } from "../../funcs/universalPriceUsd.js";
|
|
6
|
-
import * as operations from "../../models/operations/index.js";
|
|
7
|
-
import { formatResult, ToolDefinition } from "../tools.js";
|
|
8
|
-
|
|
9
|
-
const args = {
|
|
10
|
-
request: operations.GenericPriceUsdRequest$inboundSchema,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export const tool$universalPriceUsd: ToolDefinition<typeof args> = {
|
|
14
|
-
name: "universal-price-usd",
|
|
15
|
-
description: `Token price
|
|
16
|
-
|
|
17
|
-
Retrieves the price of the specified token relative to USD using Chainlink's on-
|
|
18
|
-
chain price feeds.
|
|
19
|
-
|
|
20
|
-
Chainlink is a decentralized oracle that aggregates price data from off-chain
|
|
21
|
-
sources. This ensures the price is tamper-resistant but the price might be stale
|
|
22
|
-
with the update frequency of the oracle.`,
|
|
23
|
-
args,
|
|
24
|
-
tool: async (client, args, ctx) => {
|
|
25
|
-
const [result, apiCall] = await universalPriceUsd(
|
|
26
|
-
client,
|
|
27
|
-
args.request,
|
|
28
|
-
{ fetchOptions: { signal: ctx.signal } },
|
|
29
|
-
).$inspect();
|
|
30
|
-
|
|
31
|
-
if (!result.ok) {
|
|
32
|
-
return {
|
|
33
|
-
content: [{ type: "text", text: result.error.message }],
|
|
34
|
-
isError: true,
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
const value = result.value;
|
|
39
|
-
|
|
40
|
-
return formatResult(value, apiCall);
|
|
41
|
-
},
|
|
42
|
-
};
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { universalTransferErc20 } from "../../funcs/universalTransferErc20.js";
|
|
6
|
-
import * as components from "../../models/components/index.js";
|
|
7
|
-
import { formatResult, ToolDefinition } from "../tools.js";
|
|
8
|
-
|
|
9
|
-
const args = {
|
|
10
|
-
request: components.TransferErc20Request$inboundSchema,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export const tool$universalTransferErc20: ToolDefinition<typeof args> = {
|
|
14
|
-
name: "universal-transfer-erc20",
|
|
15
|
-
description: `Transfer Token
|
|
16
|
-
|
|
17
|
-
Sends ERC20 tokens from the sender's address to the specified recipient.`,
|
|
18
|
-
args,
|
|
19
|
-
tool: async (client, args, ctx) => {
|
|
20
|
-
const [result, apiCall] = await universalTransferErc20(
|
|
21
|
-
client,
|
|
22
|
-
args.request,
|
|
23
|
-
{ fetchOptions: { signal: ctx.signal } },
|
|
24
|
-
).$inspect();
|
|
25
|
-
|
|
26
|
-
if (!result.ok) {
|
|
27
|
-
return {
|
|
28
|
-
content: [{ type: "text", text: result.error.message }],
|
|
29
|
-
isError: true,
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
const value = result.value;
|
|
34
|
-
|
|
35
|
-
return formatResult(value, apiCall);
|
|
36
|
-
},
|
|
37
|
-
};
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import { universalTransferNativeToken } from "../../funcs/universalTransferNativeToken.js";
|
|
6
|
-
import * as components from "../../models/components/index.js";
|
|
7
|
-
import { formatResult, ToolDefinition } from "../tools.js";
|
|
8
|
-
|
|
9
|
-
const args = {
|
|
10
|
-
request: components.TransferEthRequest$inboundSchema,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export const tool$universalTransferNativeToken: ToolDefinition<typeof args> = {
|
|
14
|
-
name: "universal-transfer-native-token",
|
|
15
|
-
description: `Transfer ETH
|
|
16
|
-
|
|
17
|
-
Sends native ETH from the sender's address to the specified recipient.`,
|
|
18
|
-
args,
|
|
19
|
-
tool: async (client, args, ctx) => {
|
|
20
|
-
const [result, apiCall] = await universalTransferNativeToken(
|
|
21
|
-
client,
|
|
22
|
-
args.request,
|
|
23
|
-
{ fetchOptions: { signal: ctx.signal } },
|
|
24
|
-
).$inspect();
|
|
25
|
-
|
|
26
|
-
if (!result.ok) {
|
|
27
|
-
return {
|
|
28
|
-
content: [{ type: "text", text: result.error.message }],
|
|
29
|
-
isError: true,
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
const value = result.value;
|
|
34
|
-
|
|
35
|
-
return formatResult(value, apiCall);
|
|
36
|
-
},
|
|
37
|
-
};
|
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod";
|
|
6
|
-
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
-
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
-
import {
|
|
11
|
-
TokenEnum,
|
|
12
|
-
TokenEnum$inboundSchema,
|
|
13
|
-
TokenEnum$outboundSchema,
|
|
14
|
-
} from "./tokenenum.js";
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Response model for token balance information.
|
|
18
|
-
*/
|
|
19
|
-
export type BalanceInfoResponse = {
|
|
20
|
-
/**
|
|
21
|
-
* Amount of tokens a particular address holds
|
|
22
|
-
*/
|
|
23
|
-
amount: string;
|
|
24
|
-
/**
|
|
25
|
-
* Number of decimals of the token
|
|
26
|
-
*/
|
|
27
|
-
decimals: number;
|
|
28
|
-
/**
|
|
29
|
-
* A class representing the token.
|
|
30
|
-
*
|
|
31
|
-
* @remarks
|
|
32
|
-
*
|
|
33
|
-
* This class is used to represent the token in the system. Notice individual
|
|
34
|
-
* endpoints' documentation where per chain tokens are presented.
|
|
35
|
-
*/
|
|
36
|
-
tokenSymbol: TokenEnum;
|
|
37
|
-
/**
|
|
38
|
-
* Address of the token
|
|
39
|
-
*/
|
|
40
|
-
tokenAddress: string;
|
|
41
|
-
};
|
|
42
|
-
|
|
43
|
-
/** @internal */
|
|
44
|
-
export const BalanceInfoResponse$inboundSchema: z.ZodType<
|
|
45
|
-
BalanceInfoResponse,
|
|
46
|
-
z.ZodTypeDef,
|
|
47
|
-
unknown
|
|
48
|
-
> = z.object({
|
|
49
|
-
amount: z.string(),
|
|
50
|
-
decimals: z.number().int(),
|
|
51
|
-
token_symbol: TokenEnum$inboundSchema,
|
|
52
|
-
token_address: z.string(),
|
|
53
|
-
}).transform((v) => {
|
|
54
|
-
return remap$(v, {
|
|
55
|
-
"token_symbol": "tokenSymbol",
|
|
56
|
-
"token_address": "tokenAddress",
|
|
57
|
-
});
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
/** @internal */
|
|
61
|
-
export type BalanceInfoResponse$Outbound = {
|
|
62
|
-
amount: string;
|
|
63
|
-
decimals: number;
|
|
64
|
-
token_symbol: string;
|
|
65
|
-
token_address: string;
|
|
66
|
-
};
|
|
67
|
-
|
|
68
|
-
/** @internal */
|
|
69
|
-
export const BalanceInfoResponse$outboundSchema: z.ZodType<
|
|
70
|
-
BalanceInfoResponse$Outbound,
|
|
71
|
-
z.ZodTypeDef,
|
|
72
|
-
BalanceInfoResponse
|
|
73
|
-
> = z.object({
|
|
74
|
-
amount: z.string(),
|
|
75
|
-
decimals: z.number().int(),
|
|
76
|
-
tokenSymbol: TokenEnum$outboundSchema,
|
|
77
|
-
tokenAddress: z.string(),
|
|
78
|
-
}).transform((v) => {
|
|
79
|
-
return remap$(v, {
|
|
80
|
-
tokenSymbol: "token_symbol",
|
|
81
|
-
tokenAddress: "token_address",
|
|
82
|
-
});
|
|
83
|
-
});
|
|
84
|
-
|
|
85
|
-
/**
|
|
86
|
-
* @internal
|
|
87
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
88
|
-
*/
|
|
89
|
-
export namespace BalanceInfoResponse$ {
|
|
90
|
-
/** @deprecated use `BalanceInfoResponse$inboundSchema` instead. */
|
|
91
|
-
export const inboundSchema = BalanceInfoResponse$inboundSchema;
|
|
92
|
-
/** @deprecated use `BalanceInfoResponse$outboundSchema` instead. */
|
|
93
|
-
export const outboundSchema = BalanceInfoResponse$outboundSchema;
|
|
94
|
-
/** @deprecated use `BalanceInfoResponse$Outbound` instead. */
|
|
95
|
-
export type Outbound = BalanceInfoResponse$Outbound;
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
export function balanceInfoResponseToJSON(
|
|
99
|
-
balanceInfoResponse: BalanceInfoResponse,
|
|
100
|
-
): string {
|
|
101
|
-
return JSON.stringify(
|
|
102
|
-
BalanceInfoResponse$outboundSchema.parse(balanceInfoResponse),
|
|
103
|
-
);
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
export function balanceInfoResponseFromJSON(
|
|
107
|
-
jsonString: string,
|
|
108
|
-
): SafeParseResult<BalanceInfoResponse, SDKValidationError> {
|
|
109
|
-
return safeParse(
|
|
110
|
-
jsonString,
|
|
111
|
-
(x) => BalanceInfoResponse$inboundSchema.parse(JSON.parse(x)),
|
|
112
|
-
`Failed to parse 'BalanceInfoResponse' from JSON`,
|
|
113
|
-
);
|
|
114
|
-
}
|
|
@@ -1,74 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod";
|
|
6
|
-
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
-
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
-
|
|
11
|
-
export type PriceResponse = {
|
|
12
|
-
/**
|
|
13
|
-
* Price of the token in USD
|
|
14
|
-
*/
|
|
15
|
-
tokenPriceInUsd: string;
|
|
16
|
-
};
|
|
17
|
-
|
|
18
|
-
/** @internal */
|
|
19
|
-
export const PriceResponse$inboundSchema: z.ZodType<
|
|
20
|
-
PriceResponse,
|
|
21
|
-
z.ZodTypeDef,
|
|
22
|
-
unknown
|
|
23
|
-
> = z.object({
|
|
24
|
-
token_price_in_usd: z.string(),
|
|
25
|
-
}).transform((v) => {
|
|
26
|
-
return remap$(v, {
|
|
27
|
-
"token_price_in_usd": "tokenPriceInUsd",
|
|
28
|
-
});
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
/** @internal */
|
|
32
|
-
export type PriceResponse$Outbound = {
|
|
33
|
-
token_price_in_usd: string;
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
/** @internal */
|
|
37
|
-
export const PriceResponse$outboundSchema: z.ZodType<
|
|
38
|
-
PriceResponse$Outbound,
|
|
39
|
-
z.ZodTypeDef,
|
|
40
|
-
PriceResponse
|
|
41
|
-
> = z.object({
|
|
42
|
-
tokenPriceInUsd: z.string(),
|
|
43
|
-
}).transform((v) => {
|
|
44
|
-
return remap$(v, {
|
|
45
|
-
tokenPriceInUsd: "token_price_in_usd",
|
|
46
|
-
});
|
|
47
|
-
});
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* @internal
|
|
51
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
52
|
-
*/
|
|
53
|
-
export namespace PriceResponse$ {
|
|
54
|
-
/** @deprecated use `PriceResponse$inboundSchema` instead. */
|
|
55
|
-
export const inboundSchema = PriceResponse$inboundSchema;
|
|
56
|
-
/** @deprecated use `PriceResponse$outboundSchema` instead. */
|
|
57
|
-
export const outboundSchema = PriceResponse$outboundSchema;
|
|
58
|
-
/** @deprecated use `PriceResponse$Outbound` instead. */
|
|
59
|
-
export type Outbound = PriceResponse$Outbound;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
export function priceResponseToJSON(priceResponse: PriceResponse): string {
|
|
63
|
-
return JSON.stringify(PriceResponse$outboundSchema.parse(priceResponse));
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
export function priceResponseFromJSON(
|
|
67
|
-
jsonString: string,
|
|
68
|
-
): SafeParseResult<PriceResponse, SDKValidationError> {
|
|
69
|
-
return safeParse(
|
|
70
|
-
jsonString,
|
|
71
|
-
(x) => PriceResponse$inboundSchema.parse(JSON.parse(x)),
|
|
72
|
-
`Failed to parse 'PriceResponse' from JSON`,
|
|
73
|
-
);
|
|
74
|
-
}
|
|
@@ -1,164 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod";
|
|
6
|
-
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
-
import { Chain, Chain$inboundSchema, Chain$outboundSchema } from "./chain.js";
|
|
10
|
-
import {
|
|
11
|
-
TokenEnum,
|
|
12
|
-
TokenEnum$inboundSchema,
|
|
13
|
-
TokenEnum$outboundSchema,
|
|
14
|
-
} from "./tokenenum.js";
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Amount of token to transfer
|
|
18
|
-
*/
|
|
19
|
-
export type TransferErc20RequestAmount = number | string;
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Request model for transferring ERC20 tokens.
|
|
23
|
-
*/
|
|
24
|
-
export type TransferErc20Request = {
|
|
25
|
-
/**
|
|
26
|
-
* Amount of token to transfer
|
|
27
|
-
*/
|
|
28
|
-
amount: number | string;
|
|
29
|
-
/**
|
|
30
|
-
* A class representing the token.
|
|
31
|
-
*
|
|
32
|
-
* @remarks
|
|
33
|
-
*
|
|
34
|
-
* This class is used to represent the token in the system. Notice individual
|
|
35
|
-
* endpoints' documentation where per chain tokens are presented.
|
|
36
|
-
*/
|
|
37
|
-
token: TokenEnum;
|
|
38
|
-
/**
|
|
39
|
-
* The recipient of the tokens.
|
|
40
|
-
*/
|
|
41
|
-
to: string;
|
|
42
|
-
/**
|
|
43
|
-
* The chain to use.
|
|
44
|
-
*/
|
|
45
|
-
chain: Chain;
|
|
46
|
-
/**
|
|
47
|
-
* The address of the transaction sender.
|
|
48
|
-
*/
|
|
49
|
-
sender: string;
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
/** @internal */
|
|
53
|
-
export const TransferErc20RequestAmount$inboundSchema: z.ZodType<
|
|
54
|
-
TransferErc20RequestAmount,
|
|
55
|
-
z.ZodTypeDef,
|
|
56
|
-
unknown
|
|
57
|
-
> = z.union([z.number(), z.string()]);
|
|
58
|
-
|
|
59
|
-
/** @internal */
|
|
60
|
-
export type TransferErc20RequestAmount$Outbound = number | string;
|
|
61
|
-
|
|
62
|
-
/** @internal */
|
|
63
|
-
export const TransferErc20RequestAmount$outboundSchema: z.ZodType<
|
|
64
|
-
TransferErc20RequestAmount$Outbound,
|
|
65
|
-
z.ZodTypeDef,
|
|
66
|
-
TransferErc20RequestAmount
|
|
67
|
-
> = z.union([z.number(), z.string()]);
|
|
68
|
-
|
|
69
|
-
/**
|
|
70
|
-
* @internal
|
|
71
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
72
|
-
*/
|
|
73
|
-
export namespace TransferErc20RequestAmount$ {
|
|
74
|
-
/** @deprecated use `TransferErc20RequestAmount$inboundSchema` instead. */
|
|
75
|
-
export const inboundSchema = TransferErc20RequestAmount$inboundSchema;
|
|
76
|
-
/** @deprecated use `TransferErc20RequestAmount$outboundSchema` instead. */
|
|
77
|
-
export const outboundSchema = TransferErc20RequestAmount$outboundSchema;
|
|
78
|
-
/** @deprecated use `TransferErc20RequestAmount$Outbound` instead. */
|
|
79
|
-
export type Outbound = TransferErc20RequestAmount$Outbound;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
export function transferErc20RequestAmountToJSON(
|
|
83
|
-
transferErc20RequestAmount: TransferErc20RequestAmount,
|
|
84
|
-
): string {
|
|
85
|
-
return JSON.stringify(
|
|
86
|
-
TransferErc20RequestAmount$outboundSchema.parse(transferErc20RequestAmount),
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
export function transferErc20RequestAmountFromJSON(
|
|
91
|
-
jsonString: string,
|
|
92
|
-
): SafeParseResult<TransferErc20RequestAmount, SDKValidationError> {
|
|
93
|
-
return safeParse(
|
|
94
|
-
jsonString,
|
|
95
|
-
(x) => TransferErc20RequestAmount$inboundSchema.parse(JSON.parse(x)),
|
|
96
|
-
`Failed to parse 'TransferErc20RequestAmount' from JSON`,
|
|
97
|
-
);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
/** @internal */
|
|
101
|
-
export const TransferErc20Request$inboundSchema: z.ZodType<
|
|
102
|
-
TransferErc20Request,
|
|
103
|
-
z.ZodTypeDef,
|
|
104
|
-
unknown
|
|
105
|
-
> = z.object({
|
|
106
|
-
amount: z.union([z.number(), z.string()]),
|
|
107
|
-
token: TokenEnum$inboundSchema,
|
|
108
|
-
to: z.string(),
|
|
109
|
-
chain: Chain$inboundSchema,
|
|
110
|
-
sender: z.string(),
|
|
111
|
-
});
|
|
112
|
-
|
|
113
|
-
/** @internal */
|
|
114
|
-
export type TransferErc20Request$Outbound = {
|
|
115
|
-
amount: number | string;
|
|
116
|
-
token: string;
|
|
117
|
-
to: string;
|
|
118
|
-
chain: string;
|
|
119
|
-
sender: string;
|
|
120
|
-
};
|
|
121
|
-
|
|
122
|
-
/** @internal */
|
|
123
|
-
export const TransferErc20Request$outboundSchema: z.ZodType<
|
|
124
|
-
TransferErc20Request$Outbound,
|
|
125
|
-
z.ZodTypeDef,
|
|
126
|
-
TransferErc20Request
|
|
127
|
-
> = z.object({
|
|
128
|
-
amount: z.union([z.number(), z.string()]),
|
|
129
|
-
token: TokenEnum$outboundSchema,
|
|
130
|
-
to: z.string(),
|
|
131
|
-
chain: Chain$outboundSchema,
|
|
132
|
-
sender: z.string(),
|
|
133
|
-
});
|
|
134
|
-
|
|
135
|
-
/**
|
|
136
|
-
* @internal
|
|
137
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
138
|
-
*/
|
|
139
|
-
export namespace TransferErc20Request$ {
|
|
140
|
-
/** @deprecated use `TransferErc20Request$inboundSchema` instead. */
|
|
141
|
-
export const inboundSchema = TransferErc20Request$inboundSchema;
|
|
142
|
-
/** @deprecated use `TransferErc20Request$outboundSchema` instead. */
|
|
143
|
-
export const outboundSchema = TransferErc20Request$outboundSchema;
|
|
144
|
-
/** @deprecated use `TransferErc20Request$Outbound` instead. */
|
|
145
|
-
export type Outbound = TransferErc20Request$Outbound;
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
export function transferErc20RequestToJSON(
|
|
149
|
-
transferErc20Request: TransferErc20Request,
|
|
150
|
-
): string {
|
|
151
|
-
return JSON.stringify(
|
|
152
|
-
TransferErc20Request$outboundSchema.parse(transferErc20Request),
|
|
153
|
-
);
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
export function transferErc20RequestFromJSON(
|
|
157
|
-
jsonString: string,
|
|
158
|
-
): SafeParseResult<TransferErc20Request, SDKValidationError> {
|
|
159
|
-
return safeParse(
|
|
160
|
-
jsonString,
|
|
161
|
-
(x) => TransferErc20Request$inboundSchema.parse(JSON.parse(x)),
|
|
162
|
-
`Failed to parse 'TransferErc20Request' from JSON`,
|
|
163
|
-
);
|
|
164
|
-
}
|