@coinbase/agentkit 0.10.1 → 0.10.3
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 +179 -40
- package/dist/action-providers/across/schemas.d.ts +1 -1
- package/dist/action-providers/baseAccount/baseAccountActionProvider.d.ts +46 -0
- package/dist/action-providers/baseAccount/baseAccountActionProvider.js +404 -0
- package/dist/action-providers/baseAccount/baseAccountActionProvider.test.d.ts +1 -0
- package/dist/action-providers/baseAccount/baseAccountActionProvider.test.js +325 -0
- package/dist/action-providers/baseAccount/index.d.ts +2 -0
- package/dist/action-providers/baseAccount/index.js +18 -0
- package/dist/action-providers/baseAccount/schemas.d.ts +43 -0
- package/dist/action-providers/baseAccount/schemas.js +62 -0
- package/dist/action-providers/baseAccount/types.d.ts +17 -0
- package/dist/action-providers/baseAccount/types.js +2 -0
- package/dist/action-providers/baseAccount/utils.d.ts +14 -0
- package/dist/action-providers/baseAccount/utils.js +57 -0
- package/dist/action-providers/cdp/cdpApiActionProvider.js +7 -30
- package/dist/action-providers/cdp/cdpApiActionProvider.test.js +2 -8
- package/dist/action-providers/cdp/cdpEvmWalletActionProvider.js +2 -1
- package/dist/action-providers/cdp/cdpEvmWalletActionProvider.test.js +3 -1
- package/dist/action-providers/cdp/cdpSmartWalletActionProvider.js +2 -1
- package/dist/action-providers/cdp/cdpSmartWalletActionProvider.test.js +3 -1
- package/dist/action-providers/cdp/faucetUtils.d.ts +38 -0
- package/dist/action-providers/cdp/faucetUtils.js +81 -0
- package/dist/action-providers/cdp/swapUtils.d.ts +0 -9
- package/dist/action-providers/cdp/swapUtils.js +0 -36
- package/dist/action-providers/clanker/schemas.d.ts +6 -6
- package/dist/action-providers/enso/constants.d.ts +4 -0
- package/dist/action-providers/enso/constants.js +10 -0
- package/dist/action-providers/enso/ensoActionProvider.d.ts +34 -0
- package/dist/action-providers/enso/ensoActionProvider.js +125 -0
- package/dist/action-providers/enso/ensoActionProvider.test.d.ts +1 -0
- package/dist/action-providers/enso/ensoActionProvider.test.js +141 -0
- package/dist/action-providers/enso/index.d.ts +1 -0
- package/dist/action-providers/enso/index.js +17 -0
- package/dist/action-providers/enso/schemas.d.ts +23 -0
- package/dist/action-providers/enso/schemas.js +22 -0
- package/dist/action-providers/erc20/constants.d.ts +2 -0
- package/dist/action-providers/erc20/constants.js +2 -0
- package/dist/action-providers/erc20/erc20ActionProvider.d.ts +17 -1
- package/dist/action-providers/erc20/erc20ActionProvider.js +103 -1
- package/dist/action-providers/erc20/erc20ActionProvider.test.js +201 -0
- package/dist/action-providers/erc20/schemas.d.ts +29 -0
- package/dist/action-providers/erc20/schemas.js +34 -1
- package/dist/action-providers/flaunch/client_utils.d.ts +25 -0
- package/dist/action-providers/flaunch/client_utils.js +62 -0
- package/dist/action-providers/flaunch/constants.d.ts +41 -20
- package/dist/action-providers/flaunch/constants.js +111 -36
- package/dist/action-providers/flaunch/flaunchActionProvider.d.ts +4 -43
- package/dist/action-providers/flaunch/flaunchActionProvider.js +132 -200
- package/dist/action-providers/flaunch/flaunchActionProvider.test.js +108 -13
- package/dist/action-providers/flaunch/metadata_utils.d.ts +12 -0
- package/dist/action-providers/flaunch/metadata_utils.js +216 -0
- package/dist/action-providers/flaunch/schemas.d.ts +39 -3
- package/dist/action-providers/flaunch/schemas.js +62 -10
- package/dist/action-providers/flaunch/{utils.d.ts → swap_utils.d.ts} +17 -19
- package/dist/action-providers/flaunch/{utils.js → swap_utils.js} +137 -172
- package/dist/action-providers/index.d.ts +4 -1
- package/dist/action-providers/index.js +4 -1
- package/dist/action-providers/pyth/pythActionProvider.d.ts +2 -2
- package/dist/action-providers/pyth/pythActionProvider.js +83 -31
- package/dist/action-providers/pyth/pythActionProvider.test.js +178 -26
- package/dist/action-providers/pyth/schemas.d.ts +6 -0
- package/dist/action-providers/pyth/schemas.js +9 -1
- package/dist/action-providers/superfluid/superfluidSuperTokenCreatorActionProvider.js +5 -4
- package/dist/action-providers/superfluid/utils/parseLogs.d.ts +2 -1
- package/dist/action-providers/superfluid/utils/parseLogs.js +6 -3
- package/dist/action-providers/wallet/walletActionProvider.js +4 -1
- package/dist/action-providers/weth/constants.d.ts +0 -1
- package/dist/action-providers/weth/constants.js +1 -2
- package/dist/action-providers/weth/schemas.js +6 -2
- package/dist/action-providers/weth/wethActionProvider.d.ts +7 -0
- package/dist/action-providers/weth/wethActionProvider.js +57 -32
- package/dist/action-providers/weth/wethActionProvider.test.js +60 -11
- package/dist/action-providers/x402/schemas.d.ts +7 -0
- package/dist/action-providers/x402/schemas.js +11 -1
- package/dist/action-providers/x402/utils.d.ts +55 -0
- package/dist/action-providers/x402/utils.js +197 -0
- package/dist/action-providers/x402/x402ActionProvider.d.ts +14 -14
- package/dist/action-providers/x402/x402ActionProvider.js +179 -45
- package/dist/action-providers/x402/x402ActionProvider.test.js +162 -12
- package/dist/action-providers/yelay/constants.d.ts +64 -0
- package/dist/action-providers/yelay/constants.js +137 -0
- package/dist/action-providers/yelay/index.d.ts +2 -0
- package/dist/action-providers/yelay/index.js +18 -0
- package/dist/action-providers/yelay/schemas.d.ts +47 -0
- package/dist/action-providers/yelay/schemas.js +59 -0
- package/dist/action-providers/yelay/types.d.ts +24 -0
- package/dist/action-providers/yelay/types.js +2 -0
- package/dist/action-providers/yelay/yelayActionProvider.d.ts +70 -0
- package/dist/action-providers/yelay/yelayActionProvider.js +329 -0
- package/dist/action-providers/yelay/yelayActionProvider.test.d.ts +1 -0
- package/dist/action-providers/yelay/yelayActionProvider.test.js +302 -0
- package/dist/utils.d.ts +10 -0
- package/dist/utils.js +43 -13
- package/dist/wallet-providers/cdpEvmWalletProvider.d.ts +7 -0
- package/dist/wallet-providers/cdpEvmWalletProvider.js +14 -21
- package/dist/wallet-providers/cdpEvmWalletProvider.test.js +7 -0
- package/dist/wallet-providers/cdpSmartWalletProvider.d.ts +7 -0
- package/dist/wallet-providers/cdpSmartWalletProvider.js +23 -8
- package/dist/wallet-providers/cdpSmartWalletProvider.test.js +6 -10
- package/dist/wallet-providers/cdpSolanaWalletProvider.d.ts +14 -0
- package/dist/wallet-providers/cdpSolanaWalletProvider.js +39 -3
- package/dist/wallet-providers/cdpSolanaWalletProvider.test.js +16 -0
- package/dist/wallet-providers/evmWalletProvider.d.ts +9 -2
- package/dist/wallet-providers/evmWalletProvider.js +4 -0
- package/dist/wallet-providers/legacyCdpSmartWalletProvider.d.ts +9 -0
- package/dist/wallet-providers/legacyCdpSmartWalletProvider.js +11 -0
- package/dist/wallet-providers/legacyCdpWalletProvider.d.ts +7 -0
- package/dist/wallet-providers/legacyCdpWalletProvider.js +16 -0
- package/dist/wallet-providers/legacyCdpWalletProvider.test.js +6 -0
- package/dist/wallet-providers/privyEvmDelegatedEmbeddedWalletProvider.d.ts +7 -0
- package/dist/wallet-providers/privyEvmDelegatedEmbeddedWalletProvider.js +27 -0
- package/dist/wallet-providers/privyEvmWalletProvider.test.js +11 -0
- package/dist/wallet-providers/privySvmWalletProvider.d.ts +14 -0
- package/dist/wallet-providers/privySvmWalletProvider.js +17 -0
- package/dist/wallet-providers/privySvmWalletProvider.test.js +10 -0
- package/dist/wallet-providers/solanaKeypairWalletProvider.d.ts +14 -0
- package/dist/wallet-providers/solanaKeypairWalletProvider.js +17 -0
- package/dist/wallet-providers/svmWalletProvider.d.ts +34 -0
- package/dist/wallet-providers/svmWalletProvider.js +43 -0
- package/dist/wallet-providers/svmWalletProvider.test.js +10 -0
- package/dist/wallet-providers/viemWalletProvider.d.ts +8 -1
- package/dist/wallet-providers/viemWalletProvider.js +21 -1
- package/dist/wallet-providers/viemWalletProvider.test.js +21 -1
- package/dist/wallet-providers/zeroDevWalletProvider.d.ts +7 -0
- package/dist/wallet-providers/zeroDevWalletProvider.js +12 -0
- package/dist/wallet-providers/zeroDevWalletProvider.test.js +10 -0
- package/package.json +8 -4
|
@@ -1,17 +1,30 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.PERMIT_TYPES = exports.PERMIT_DETAILS = exports.PERMIT2_ABI = exports.UNIVERSAL_ROUTER_ABI = exports.URCommands = exports.V4Actions = exports.IV4RouterAbiExactOutput = exports.IV4RouterAbiExactInput = exports.QUOTER_ABI = exports.
|
|
3
|
+
exports.PERMIT_TYPES = exports.PERMIT_DETAILS = exports.PERMIT2_ABI = exports.UNIVERSAL_ROUTER_ABI = exports.URCommands = exports.V4Actions = exports.IV4RouterAbiExactOutput = exports.IV4RouterAbiExactInput = exports.QUOTER_ABI = exports.POSITION_MANAGERV1_1_ABI = exports.FLAUNCH_ZAP_ABI = exports.Permit2Address = exports.UniversalRouterAddress = exports.QuoterAddress = exports.FLETHHooksAddress = exports.FLETHAddress = exports.FlaunchPositionManagerV1_1Address = exports.AddressFeeSplitManagerAddress = exports.RevenueManagerAddress = exports.FlaunchZapAddress = exports.FastFlaunchZapAddress = exports.TOTAL_SUPPLY = exports.ERC20_ABI = void 0;
|
|
4
4
|
const viem_1 = require("viem");
|
|
5
5
|
const chains_1 = require("viem/chains");
|
|
6
6
|
const viem_2 = require("viem");
|
|
7
7
|
Object.defineProperty(exports, "ERC20_ABI", { enumerable: true, get: function () { return viem_2.erc20Abi; } });
|
|
8
|
+
exports.TOTAL_SUPPLY = 100000000000n * 10n ** 18n; // 100 Billion tokens in wei
|
|
8
9
|
exports.FastFlaunchZapAddress = {
|
|
9
10
|
[chains_1.base.id]: "0xd79e27f51ddf9df5ee76106ee192530f474b02f6",
|
|
10
11
|
[chains_1.baseSepolia.id]: "0x251e97446a7019E5DA4860d4CF47291321C693D0",
|
|
11
12
|
};
|
|
12
|
-
exports.
|
|
13
|
-
[chains_1.base.id]: "
|
|
14
|
-
[chains_1.baseSepolia.id]: "
|
|
13
|
+
exports.FlaunchZapAddress = {
|
|
14
|
+
[chains_1.base.id]: "0xfa9e8528ee95eb109bffd1a2d59cb95b300a672a",
|
|
15
|
+
[chains_1.baseSepolia.id]: "0xb2f5d987de90e026b61805e60b6002d367461474",
|
|
16
|
+
};
|
|
17
|
+
exports.RevenueManagerAddress = {
|
|
18
|
+
[chains_1.base.id]: "0x712fa8ddc7347b4b6b029aa21710f365cd02d898",
|
|
19
|
+
[chains_1.baseSepolia.id]: "0x17E02501dE3e420347e7C5fCAe3AD787C5aea690",
|
|
20
|
+
};
|
|
21
|
+
exports.AddressFeeSplitManagerAddress = {
|
|
22
|
+
[chains_1.base.id]: "0x6baa4ec493a9698dc7388c0f290e29ea3d149f99",
|
|
23
|
+
[chains_1.baseSepolia.id]: "0xf72dcdee692c188de6b14c6213e849982e04069b",
|
|
24
|
+
};
|
|
25
|
+
exports.FlaunchPositionManagerV1_1Address = {
|
|
26
|
+
[chains_1.base.id]: "0xf785bb58059fab6fb19bdda2cb9078d9e546efdc",
|
|
27
|
+
[chains_1.baseSepolia.id]: "0x24347e0dd16357059abfc1b321df354873552fdc",
|
|
15
28
|
};
|
|
16
29
|
exports.FLETHAddress = {
|
|
17
30
|
[chains_1.base.id]: "0x000000000D564D5be76f7f0d28fE52605afC7Cf8",
|
|
@@ -33,52 +46,114 @@ exports.Permit2Address = {
|
|
|
33
46
|
[chains_1.base.id]: "0x000000000022D473030F116dDEE9F6B43aC78BA3",
|
|
34
47
|
[chains_1.baseSepolia.id]: "0x000000000022D473030F116dDEE9F6B43aC78BA3",
|
|
35
48
|
};
|
|
36
|
-
exports.
|
|
49
|
+
exports.FLAUNCH_ZAP_ABI = [
|
|
37
50
|
{
|
|
51
|
+
inputs: [
|
|
52
|
+
{ internalType: "uint256", name: "_premineAmount", type: "uint256" },
|
|
53
|
+
{ internalType: "uint256", name: "_slippage", type: "uint256" },
|
|
54
|
+
{ internalType: "bytes", name: "_initialPriceParams", type: "bytes" },
|
|
55
|
+
],
|
|
56
|
+
name: "calculateFee",
|
|
57
|
+
outputs: [{ internalType: "uint256", name: "ethRequired_", type: "uint256" }],
|
|
58
|
+
stateMutability: "view",
|
|
38
59
|
type: "function",
|
|
39
|
-
|
|
60
|
+
},
|
|
61
|
+
{
|
|
40
62
|
inputs: [
|
|
41
63
|
{
|
|
42
|
-
name: "_params",
|
|
43
|
-
type: "tuple",
|
|
44
|
-
internalType: "struct FastFlaunchZap.FastFlaunchParams",
|
|
45
64
|
components: [
|
|
46
|
-
{
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
},
|
|
51
|
-
{
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
name: "tokenUri",
|
|
58
|
-
type: "string",
|
|
59
|
-
internalType: "string",
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
name: "creator",
|
|
63
|
-
type: "address",
|
|
64
|
-
internalType: "address",
|
|
65
|
-
},
|
|
65
|
+
{ internalType: "string", name: "name", type: "string" },
|
|
66
|
+
{ internalType: "string", name: "symbol", type: "string" },
|
|
67
|
+
{ internalType: "string", name: "tokenUri", type: "string" },
|
|
68
|
+
{ internalType: "uint256", name: "initialTokenFairLaunch", type: "uint256" },
|
|
69
|
+
{ internalType: "uint256", name: "fairLaunchDuration", type: "uint256" },
|
|
70
|
+
{ internalType: "uint256", name: "premineAmount", type: "uint256" },
|
|
71
|
+
{ internalType: "address", name: "creator", type: "address" },
|
|
72
|
+
{ internalType: "uint24", name: "creatorFeeAllocation", type: "uint24" },
|
|
73
|
+
{ internalType: "uint256", name: "flaunchAt", type: "uint256" },
|
|
74
|
+
{ internalType: "bytes", name: "initialPriceParams", type: "bytes" },
|
|
75
|
+
{ internalType: "bytes", name: "feeCalculatorParams", type: "bytes" },
|
|
66
76
|
],
|
|
77
|
+
internalType: "struct PositionManager.FlaunchParams",
|
|
78
|
+
name: "_flaunchParams",
|
|
79
|
+
type: "tuple",
|
|
67
80
|
},
|
|
68
81
|
],
|
|
82
|
+
name: "flaunch",
|
|
69
83
|
outputs: [
|
|
84
|
+
{ internalType: "address", name: "memecoin_", type: "address" },
|
|
85
|
+
{ internalType: "uint256", name: "ethSpent_", type: "uint256" },
|
|
86
|
+
{ internalType: "address", name: "", type: "address" },
|
|
87
|
+
],
|
|
88
|
+
stateMutability: "payable",
|
|
89
|
+
type: "function",
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
inputs: [
|
|
70
93
|
{
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
94
|
+
components: [
|
|
95
|
+
{ internalType: "string", name: "name", type: "string" },
|
|
96
|
+
{ internalType: "string", name: "symbol", type: "string" },
|
|
97
|
+
{ internalType: "string", name: "tokenUri", type: "string" },
|
|
98
|
+
{ internalType: "uint256", name: "initialTokenFairLaunch", type: "uint256" },
|
|
99
|
+
{ internalType: "uint256", name: "fairLaunchDuration", type: "uint256" },
|
|
100
|
+
{ internalType: "uint256", name: "premineAmount", type: "uint256" },
|
|
101
|
+
{ internalType: "address", name: "creator", type: "address" },
|
|
102
|
+
{ internalType: "uint24", name: "creatorFeeAllocation", type: "uint24" },
|
|
103
|
+
{ internalType: "uint256", name: "flaunchAt", type: "uint256" },
|
|
104
|
+
{ internalType: "bytes", name: "initialPriceParams", type: "bytes" },
|
|
105
|
+
{ internalType: "bytes", name: "feeCalculatorParams", type: "bytes" },
|
|
106
|
+
],
|
|
107
|
+
internalType: "struct PositionManager.FlaunchParams",
|
|
108
|
+
name: "_flaunchParams",
|
|
109
|
+
type: "tuple",
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
components: [
|
|
113
|
+
{ internalType: "bytes32", name: "merkleRoot", type: "bytes32" },
|
|
114
|
+
{ internalType: "string", name: "merkleIPFSHash", type: "string" },
|
|
115
|
+
{ internalType: "uint256", name: "maxTokens", type: "uint256" },
|
|
116
|
+
],
|
|
117
|
+
internalType: "struct FlaunchZap.WhitelistParams",
|
|
118
|
+
name: "_whitelistParams",
|
|
119
|
+
type: "tuple",
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
components: [
|
|
123
|
+
{ internalType: "uint256", name: "airdropIndex", type: "uint256" },
|
|
124
|
+
{ internalType: "uint256", name: "airdropAmount", type: "uint256" },
|
|
125
|
+
{ internalType: "uint256", name: "airdropEndTime", type: "uint256" },
|
|
126
|
+
{ internalType: "bytes32", name: "merkleRoot", type: "bytes32" },
|
|
127
|
+
{ internalType: "string", name: "merkleIPFSHash", type: "string" },
|
|
128
|
+
],
|
|
129
|
+
internalType: "struct FlaunchZap.AirdropParams",
|
|
130
|
+
name: "_airdropParams",
|
|
131
|
+
type: "tuple",
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
components: [
|
|
135
|
+
{ internalType: "address", name: "manager", type: "address" },
|
|
136
|
+
{ internalType: "bytes", name: "initializeData", type: "bytes" },
|
|
137
|
+
{ internalType: "bytes", name: "depositData", type: "bytes" },
|
|
138
|
+
],
|
|
139
|
+
internalType: "struct FlaunchZap.TreasuryManagerParams",
|
|
140
|
+
name: "_treasuryManagerParams",
|
|
141
|
+
type: "tuple",
|
|
74
142
|
},
|
|
75
143
|
],
|
|
76
|
-
|
|
144
|
+
name: "flaunch",
|
|
145
|
+
outputs: [
|
|
146
|
+
{ internalType: "address", name: "memecoin_", type: "address" },
|
|
147
|
+
{ internalType: "uint256", name: "ethSpent_", type: "uint256" },
|
|
148
|
+
{ internalType: "address", name: "deployedManager_", type: "address" },
|
|
149
|
+
],
|
|
150
|
+
stateMutability: "payable",
|
|
151
|
+
type: "function",
|
|
77
152
|
},
|
|
78
153
|
];
|
|
79
|
-
exports.
|
|
80
|
-
"event PoolCreated(bytes32 indexed _poolId, address _memecoin, address _memecoinTreasury, uint256 _tokenId, bool _currencyFlipped, uint256 _flaunchFee, (string name, string symbol, string tokenUri, uint256 initialTokenFairLaunch, uint256 premineAmount, address creator, uint24 creatorFeeAllocation, uint256 flaunchAt, bytes initialPriceParams, bytes feeCalculatorParams) _params)",
|
|
81
|
-
"event PoolSwap(bytes32 indexed poolId,
|
|
154
|
+
exports.POSITION_MANAGERV1_1_ABI = (0, viem_1.parseAbi)([
|
|
155
|
+
"event PoolCreated(bytes32 indexed _poolId, address _memecoin, address _memecoinTreasury, uint256 _tokenId, bool _currencyFlipped, uint256 _flaunchFee, (string name, string symbol, string tokenUri, uint256 initialTokenFairLaunch, uint256 fairLaunchDuration, uint256 premineAmount, address creator, uint24 creatorFeeAllocation, uint256 flaunchAt, bytes initialPriceParams, bytes feeCalculatorParams) _params)",
|
|
156
|
+
"event PoolSwap(bytes32 indexed poolId, int256 flAmount0, int256 flAmount1, int256 flFee0, int256 flFee1, int256 ispAmount0, int256 ispAmount1, int256 ispFee0, int256 ispFee1, int256 uniAmount0, int256 uniAmount1, int256 uniFee0, int256 uniFee1)",
|
|
82
157
|
]);
|
|
83
158
|
exports.QUOTER_ABI = [
|
|
84
159
|
{
|
|
@@ -1,51 +1,26 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Flaunch Action Provider
|
|
3
|
-
*
|
|
4
|
-
* This file contains the implementation of the FlaunchActionProvider,
|
|
5
|
-
* which provides actions for flaunch operations.
|
|
6
|
-
*
|
|
7
|
-
* @module flaunch
|
|
8
|
-
*/
|
|
9
1
|
import { z } from "zod";
|
|
10
2
|
import { ActionProvider } from "../actionProvider";
|
|
11
3
|
import { Network } from "../../network";
|
|
12
4
|
import { EvmWalletProvider } from "../../wallet-providers";
|
|
13
5
|
import { FlaunchSchema, BuyCoinWithETHInputSchema, BuyCoinWithCoinInputSchema, SellCoinSchema } from "./schemas";
|
|
14
|
-
/**
|
|
15
|
-
* Configuration options for the FarcasterActionProvider.
|
|
16
|
-
*/
|
|
17
|
-
export interface FlaunchActionProviderConfig {
|
|
18
|
-
/**
|
|
19
|
-
* Pinata JWT.
|
|
20
|
-
*/
|
|
21
|
-
pinataJwt?: string;
|
|
22
|
-
}
|
|
23
6
|
/**
|
|
24
7
|
* FlaunchActionProvider provides actions for flaunch operations.
|
|
25
8
|
*
|
|
26
9
|
* @description
|
|
27
10
|
* This provider is designed to work with EvmWalletProvider for blockchain interactions.
|
|
28
|
-
* It supports all evm networks.
|
|
29
11
|
*/
|
|
30
12
|
export declare class FlaunchActionProvider extends ActionProvider<EvmWalletProvider> {
|
|
31
|
-
private readonly pinataJwt;
|
|
32
13
|
/**
|
|
33
14
|
* Constructor for the FlaunchActionProvider.
|
|
34
15
|
*
|
|
35
|
-
* @param config - The configuration options for the FlaunchActionProvider.
|
|
36
16
|
*/
|
|
37
|
-
constructor(
|
|
17
|
+
constructor();
|
|
38
18
|
/**
|
|
39
|
-
*
|
|
40
|
-
* Replace or modify this with your actual action.
|
|
41
|
-
*
|
|
42
|
-
* @description
|
|
43
|
-
* This is a template action that demonstrates the basic structure.
|
|
44
|
-
* Replace it with your actual implementation.
|
|
19
|
+
* Launches a new memecoin using the flaunch protocol.
|
|
45
20
|
*
|
|
46
21
|
* @param walletProvider - The wallet provider instance for blockchain interactions
|
|
47
22
|
* @param args - Arguments defined by FlaunchSchema
|
|
48
|
-
* @returns A promise that resolves to a string describing the
|
|
23
|
+
* @returns A promise that resolves to a string describing the transaction result
|
|
49
24
|
*/
|
|
50
25
|
flaunch(walletProvider: EvmWalletProvider, args: z.infer<typeof FlaunchSchema>): Promise<string>;
|
|
51
26
|
/**
|
|
@@ -79,24 +54,10 @@ export declare class FlaunchActionProvider extends ActionProvider<EvmWalletProvi
|
|
|
79
54
|
* @returns True if the network is supported
|
|
80
55
|
*/
|
|
81
56
|
supportsNetwork(network: Network): boolean;
|
|
82
|
-
/**
|
|
83
|
-
* Handles the process of buying a flaunch coin with ETH.
|
|
84
|
-
*
|
|
85
|
-
* @param walletProvider - The wallet provider instance
|
|
86
|
-
* @param coinAddress - The address of the flaunch coin
|
|
87
|
-
* @param swapType - The type of swap (EXACT_IN or EXACT_OUT)
|
|
88
|
-
* @param swapParams - Parameters specific to the swap type
|
|
89
|
-
* @param swapParams.amountIn - The amount of ETH to spend (for EXACT_IN)
|
|
90
|
-
* @param swapParams.amountOut - The amount of coins to buy (for EXACT_OUT)
|
|
91
|
-
* @param slippagePercent - The slippage percentage
|
|
92
|
-
* @returns A promise that resolves to a string describing the transaction result
|
|
93
|
-
*/
|
|
94
|
-
private _buyFlaunchCoin;
|
|
95
57
|
}
|
|
96
58
|
/**
|
|
97
59
|
* Factory function to create a new FlaunchActionProvider instance.
|
|
98
60
|
*
|
|
99
|
-
* @param config - Configuration options for the FlaunchActionProvider
|
|
100
61
|
* @returns A new FlaunchActionProvider instance
|
|
101
62
|
*/
|
|
102
|
-
export declare const flaunchActionProvider: (
|
|
63
|
+
export declare const flaunchActionProvider: () => FlaunchActionProvider;
|