@boostxyz/sdk 0.0.0-alpha.2
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/LICENSE +674 -0
- package/README.md +7 -0
- package/dist/Actions/Action.cjs +1 -0
- package/dist/Actions/Action.d.ts +31 -0
- package/dist/Actions/Action.d.ts.map +1 -0
- package/dist/Actions/Action.js +27 -0
- package/dist/Actions/ContractAction.d.ts +327 -0
- package/dist/Actions/ContractAction.d.ts.map +1 -0
- package/dist/Actions/ERC721MintAction.d.ts +486 -0
- package/dist/Actions/ERC721MintAction.d.ts.map +1 -0
- package/dist/Actions/EventAction.cjs +1 -0
- package/dist/Actions/EventAction.d.ts +433 -0
- package/dist/Actions/EventAction.d.ts.map +1 -0
- package/dist/Actions/EventAction.js +211 -0
- package/dist/AllowLists/AllowList.cjs +1 -0
- package/dist/AllowLists/AllowList.d.ts +33 -0
- package/dist/AllowLists/AllowList.d.ts.map +1 -0
- package/dist/AllowLists/AllowList.js +28 -0
- package/dist/AllowLists/SimpleAllowList.cjs +1 -0
- package/dist/AllowLists/SimpleAllowList.d.ts +452 -0
- package/dist/AllowLists/SimpleAllowList.d.ts.map +1 -0
- package/dist/AllowLists/SimpleAllowList.js +138 -0
- package/dist/AllowLists/SimpleDenyList.cjs +1 -0
- package/dist/AllowLists/SimpleDenyList.d.ts +306 -0
- package/dist/AllowLists/SimpleDenyList.d.ts.map +1 -0
- package/dist/AllowLists/SimpleDenyList.js +202 -0
- package/dist/Auth/Auth.cjs +1 -0
- package/dist/Auth/Auth.d.ts +10 -0
- package/dist/Auth/Auth.d.ts.map +1 -0
- package/dist/Auth/Auth.js +4 -0
- package/dist/Auth/PassthroughAuth.cjs +1 -0
- package/dist/Auth/PassthroughAuth.d.ts +51 -0
- package/dist/Auth/PassthroughAuth.d.ts.map +1 -0
- package/dist/Auth/PassthroughAuth.js +38 -0
- package/dist/Boost.cjs +1 -0
- package/dist/Boost.d.ts +142 -0
- package/dist/Boost.d.ts.map +1 -0
- package/dist/Boost.js +15 -0
- package/dist/BoostCore.cjs +2 -0
- package/dist/BoostCore.d.ts +460 -0
- package/dist/BoostCore.d.ts.map +1 -0
- package/dist/BoostCore.js +1105 -0
- package/dist/BoostRegistry.cjs +1 -0
- package/dist/BoostRegistry.d.ts +229 -0
- package/dist/BoostRegistry.d.ts.map +1 -0
- package/dist/BoostRegistry.js +250 -0
- package/dist/Budgets/Budget.cjs +1 -0
- package/dist/Budgets/Budget.d.ts +31 -0
- package/dist/Budgets/Budget.d.ts.map +1 -0
- package/dist/Budgets/Budget.js +27 -0
- package/dist/Budgets/ManagedBudget.cjs +1 -0
- package/dist/Budgets/ManagedBudget.d.ts +1065 -0
- package/dist/Budgets/ManagedBudget.d.ts.map +1 -0
- package/dist/Budgets/ManagedBudget.js +498 -0
- package/dist/Budgets/SimpleBudget.d.ts +793 -0
- package/dist/Budgets/SimpleBudget.d.ts.map +1 -0
- package/dist/Budgets/VestingBudget.d.ts +726 -0
- package/dist/Budgets/VestingBudget.d.ts.map +1 -0
- package/dist/Deployable/Contract.cjs +1 -0
- package/dist/Deployable/Contract.d.ts +125 -0
- package/dist/Deployable/Contract.d.ts.map +1 -0
- package/dist/Deployable/Contract.js +149 -0
- package/dist/Deployable/Deployable.cjs +1 -0
- package/dist/Deployable/Deployable.d.ts +155 -0
- package/dist/Deployable/Deployable.d.ts.map +1 -0
- package/dist/Deployable/Deployable.js +124 -0
- package/dist/Deployable/DeployableTarget.cjs +1 -0
- package/dist/Deployable/DeployableTarget.d.ts +115 -0
- package/dist/Deployable/DeployableTarget.d.ts.map +1 -0
- package/dist/Deployable/DeployableTarget.js +128 -0
- package/dist/Incentives/AllowListIncentive.cjs +1 -0
- package/dist/Incentives/AllowListIncentive.d.ts +483 -0
- package/dist/Incentives/AllowListIncentive.d.ts.map +1 -0
- package/dist/Incentives/AllowListIncentive.js +188 -0
- package/dist/Incentives/CGDAIncentive.cjs +1 -0
- package/dist/Incentives/CGDAIncentive.d.ts +560 -0
- package/dist/Incentives/CGDAIncentive.d.ts.map +1 -0
- package/dist/Incentives/CGDAIncentive.js +249 -0
- package/dist/Incentives/ERC1155Incentive.d.ts +652 -0
- package/dist/Incentives/ERC1155Incentive.d.ts.map +1 -0
- package/dist/Incentives/ERC20Incentive.cjs +1 -0
- package/dist/Incentives/ERC20Incentive.d.ts +622 -0
- package/dist/Incentives/ERC20Incentive.d.ts.map +1 -0
- package/dist/Incentives/ERC20Incentive.js +292 -0
- package/dist/Incentives/ERC20VariableIncentive.d.ts +545 -0
- package/dist/Incentives/ERC20VariableIncentive.d.ts.map +1 -0
- package/dist/Incentives/Incentive.cjs +1 -0
- package/dist/Incentives/Incentive.d.ts +39 -0
- package/dist/Incentives/Incentive.d.ts.map +1 -0
- package/dist/Incentives/Incentive.js +280 -0
- package/dist/Incentives/PointsIncentive.cjs +1 -0
- package/dist/Incentives/PointsIncentive.d.ts +615 -0
- package/dist/Incentives/PointsIncentive.d.ts.map +1 -0
- package/dist/Incentives/PointsIncentive.js +197 -0
- package/dist/Validators/SignerValidator.cjs +1 -0
- package/dist/Validators/SignerValidator.d.ts +452 -0
- package/dist/Validators/SignerValidator.d.ts.map +1 -0
- package/dist/Validators/SignerValidator.js +167 -0
- package/dist/Validators/Validator.cjs +1 -0
- package/dist/Validators/Validator.d.ts +31 -0
- package/dist/Validators/Validator.d.ts.map +1 -0
- package/dist/Validators/Validator.js +25 -0
- package/dist/errors.cjs +1 -0
- package/dist/errors.d.ts +257 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +161 -0
- package/dist/generated-BaaleHW-.cjs +2 -0
- package/dist/generated-x_abr3Yv.js +6228 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1355 -0
- package/dist/utils.cjs +1 -0
- package/dist/utils.d.ts +1454 -0
- package/dist/utils.d.ts.map +1 -0
- package/dist/utils.js +643 -0
- package/package.json +197 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../generated-BaaleHW-.cjs"),a=require("@wagmi/core"),s=require("../errors.cjs"),c=require("./EventAction.cjs"),e={"0x7687b0ed":c.EventAction};async function f(n,t){const o=await a.readContract(n.config,{abi:i.X,functionName:"getComponentInterface",address:t}),r=e[o];if(!r)throw new s.InvalidComponentInterfaceError(Object.keys(e),o);return new r(n,t)}exports.EventAction=c.EventAction;exports.ActionByComponentInterface=e;exports.actionFromAddress=f;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { Address } from 'viem';
|
|
2
|
+
import type { DeployableOptions } from '../Deployable/Deployable';
|
|
3
|
+
import { EventAction } from './EventAction';
|
|
4
|
+
export { EventAction, };
|
|
5
|
+
/**
|
|
6
|
+
* A union type representing all valid protocol Action implementations
|
|
7
|
+
*
|
|
8
|
+
* @export
|
|
9
|
+
* @typedef {Action}
|
|
10
|
+
*/
|
|
11
|
+
export type Action = EventAction;
|
|
12
|
+
/**
|
|
13
|
+
* A map of Action component interfaces to their constructors.
|
|
14
|
+
*
|
|
15
|
+
* @type {{ "0x7687b0ed": EventAction; }}
|
|
16
|
+
*/
|
|
17
|
+
export declare const ActionByComponentInterface: {
|
|
18
|
+
"0x7687b0ed": typeof EventAction;
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* A function that will read a contract's component interface using `getComponentInterface` and return the correct instantiated instance.
|
|
22
|
+
*
|
|
23
|
+
* @export
|
|
24
|
+
* @async
|
|
25
|
+
* @param {DeployableOptions} options
|
|
26
|
+
* @param {Address} address
|
|
27
|
+
* @returns {Promise<EventAction>}
|
|
28
|
+
* @throws {@link InvalidComponentInterfaceError}
|
|
29
|
+
*/
|
|
30
|
+
export declare function actionFromAddress(options: DeployableOptions, address: Address): Promise<EventAction>;
|
|
31
|
+
//# sourceMappingURL=Action.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Action.d.ts","sourceRoot":"","sources":["../../src/Actions/Action.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAO,MAAM,MAAM,CAAC;AACzC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAElE,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAE5C,OAAO,EAGL,WAAW,GACZ,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,MAAM,GAAG,WAAW,CAAC;AAEjC;;;;GAIG;AACH,eAAO,MAAM,0BAA0B;;CAItC,CAAC;AAEF;;;;;;;;;GASG;AACH,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,iBAAiB,EAC1B,OAAO,EAAE,OAAO,wBAejB"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { X as c } from "../generated-x_abr3Yv.js";
|
|
2
|
+
import { readContract as i } from "@wagmi/core";
|
|
3
|
+
import { InvalidComponentInterfaceError as m } from "../errors.js";
|
|
4
|
+
import { EventAction as a } from "./EventAction.js";
|
|
5
|
+
const e = {
|
|
6
|
+
// ['0x6c3129aa']: ContractAction,
|
|
7
|
+
// ['0x97e083eb']: ERC721MintAction,
|
|
8
|
+
"0x7687b0ed": a
|
|
9
|
+
};
|
|
10
|
+
async function d(t, n) {
|
|
11
|
+
const o = await i(t.config, {
|
|
12
|
+
abi: c,
|
|
13
|
+
functionName: "getComponentInterface",
|
|
14
|
+
address: n
|
|
15
|
+
}), r = e[o];
|
|
16
|
+
if (!r)
|
|
17
|
+
throw new m(
|
|
18
|
+
Object.keys(e),
|
|
19
|
+
o
|
|
20
|
+
);
|
|
21
|
+
return new r(t, n);
|
|
22
|
+
}
|
|
23
|
+
export {
|
|
24
|
+
e as ActionByComponentInterface,
|
|
25
|
+
a as EventAction,
|
|
26
|
+
d as actionFromAddress
|
|
27
|
+
};
|
|
@@ -0,0 +1,327 @@
|
|
|
1
|
+
import { contractActionAbi } from '@boostxyz/evm';
|
|
2
|
+
import type { Abi, Address, ContractEventName, Hex } from 'viem';
|
|
3
|
+
import type { DeployableOptions, GenericDeployableParams } from '../Deployable/Deployable';
|
|
4
|
+
import { DeployableTarget } from '../Deployable/DeployableTarget';
|
|
5
|
+
import { type ContractActionPayload, type GenericLog, type ReadParams, RegistryType, type WriteParams } from '../utils';
|
|
6
|
+
export { contractActionAbi };
|
|
7
|
+
export type { ContractActionPayload };
|
|
8
|
+
/**
|
|
9
|
+
* A generic `viem.Log` event with support for `ContractAction` event types.
|
|
10
|
+
*
|
|
11
|
+
* @export
|
|
12
|
+
* @typedef {ContractActionLog}
|
|
13
|
+
* @template {ContractEventName<typeof contractActionAbi>} [event=ContractEventName<
|
|
14
|
+
* typeof contractActionAbi
|
|
15
|
+
* >]
|
|
16
|
+
*/
|
|
17
|
+
export type ContractActionLog<event extends ContractEventName<typeof contractActionAbi> = ContractEventName<typeof contractActionAbi>> = GenericLog<typeof contractActionAbi, event>;
|
|
18
|
+
/**
|
|
19
|
+
* A generic contract action
|
|
20
|
+
*
|
|
21
|
+
* @export
|
|
22
|
+
* @class ContractAction
|
|
23
|
+
* @typedef {ContractAction}
|
|
24
|
+
* @extends {DeployableTarget<ContractActionPayload>}
|
|
25
|
+
*/
|
|
26
|
+
export declare class ContractAction<ContractActionAbi extends Abi = typeof contractActionAbi> extends DeployableTarget<ContractActionPayload, ContractActionAbi> {
|
|
27
|
+
readonly abi: readonly [{
|
|
28
|
+
readonly type: "constructor";
|
|
29
|
+
readonly inputs: readonly [];
|
|
30
|
+
readonly stateMutability: "nonpayable";
|
|
31
|
+
}, {
|
|
32
|
+
readonly type: "error";
|
|
33
|
+
readonly inputs: readonly [];
|
|
34
|
+
readonly name: "CloneAlreadyInitialized";
|
|
35
|
+
}, {
|
|
36
|
+
readonly type: "error";
|
|
37
|
+
readonly inputs: readonly [];
|
|
38
|
+
readonly name: "InitializerNotImplemented";
|
|
39
|
+
}, {
|
|
40
|
+
readonly type: "error";
|
|
41
|
+
readonly inputs: readonly [];
|
|
42
|
+
readonly name: "InvalidInitialization";
|
|
43
|
+
}, {
|
|
44
|
+
readonly type: "error";
|
|
45
|
+
readonly inputs: readonly [];
|
|
46
|
+
readonly name: "InvalidInitializationData";
|
|
47
|
+
}, {
|
|
48
|
+
readonly type: "error";
|
|
49
|
+
readonly inputs: readonly [];
|
|
50
|
+
readonly name: "NotInitializing";
|
|
51
|
+
}, {
|
|
52
|
+
readonly type: "error";
|
|
53
|
+
readonly inputs: readonly [{
|
|
54
|
+
readonly name: "targetChainId";
|
|
55
|
+
readonly internalType: "uint256";
|
|
56
|
+
readonly type: "uint256";
|
|
57
|
+
}];
|
|
58
|
+
readonly name: "TargetChainUnsupported";
|
|
59
|
+
}, {
|
|
60
|
+
readonly type: "event";
|
|
61
|
+
readonly anonymous: false;
|
|
62
|
+
readonly inputs: readonly [{
|
|
63
|
+
readonly name: "executor";
|
|
64
|
+
readonly internalType: "address";
|
|
65
|
+
readonly type: "address";
|
|
66
|
+
readonly indexed: true;
|
|
67
|
+
}, {
|
|
68
|
+
readonly name: "caller";
|
|
69
|
+
readonly internalType: "address";
|
|
70
|
+
readonly type: "address";
|
|
71
|
+
readonly indexed: false;
|
|
72
|
+
}, {
|
|
73
|
+
readonly name: "success";
|
|
74
|
+
readonly internalType: "bool";
|
|
75
|
+
readonly type: "bool";
|
|
76
|
+
readonly indexed: false;
|
|
77
|
+
}, {
|
|
78
|
+
readonly name: "data";
|
|
79
|
+
readonly internalType: "bytes";
|
|
80
|
+
readonly type: "bytes";
|
|
81
|
+
readonly indexed: false;
|
|
82
|
+
}];
|
|
83
|
+
readonly name: "ActionExecuted";
|
|
84
|
+
}, {
|
|
85
|
+
readonly type: "event";
|
|
86
|
+
readonly anonymous: false;
|
|
87
|
+
readonly inputs: readonly [{
|
|
88
|
+
readonly name: "user";
|
|
89
|
+
readonly internalType: "address";
|
|
90
|
+
readonly type: "address";
|
|
91
|
+
readonly indexed: true;
|
|
92
|
+
}, {
|
|
93
|
+
readonly name: "isValidated";
|
|
94
|
+
readonly internalType: "bool";
|
|
95
|
+
readonly type: "bool";
|
|
96
|
+
readonly indexed: false;
|
|
97
|
+
}, {
|
|
98
|
+
readonly name: "data";
|
|
99
|
+
readonly internalType: "bytes";
|
|
100
|
+
readonly type: "bytes";
|
|
101
|
+
readonly indexed: false;
|
|
102
|
+
}];
|
|
103
|
+
readonly name: "ActionValidated";
|
|
104
|
+
}, {
|
|
105
|
+
readonly type: "event";
|
|
106
|
+
readonly anonymous: false;
|
|
107
|
+
readonly inputs: readonly [{
|
|
108
|
+
readonly name: "version";
|
|
109
|
+
readonly internalType: "uint64";
|
|
110
|
+
readonly type: "uint64";
|
|
111
|
+
readonly indexed: false;
|
|
112
|
+
}];
|
|
113
|
+
readonly name: "Initialized";
|
|
114
|
+
}, {
|
|
115
|
+
readonly type: "function";
|
|
116
|
+
readonly inputs: readonly [];
|
|
117
|
+
readonly name: "VALIDATOR";
|
|
118
|
+
readonly outputs: readonly [{
|
|
119
|
+
readonly name: "";
|
|
120
|
+
readonly internalType: "contract AValidator";
|
|
121
|
+
readonly type: "address";
|
|
122
|
+
}];
|
|
123
|
+
readonly stateMutability: "view";
|
|
124
|
+
}, {
|
|
125
|
+
readonly type: "function";
|
|
126
|
+
readonly inputs: readonly [];
|
|
127
|
+
readonly name: "chainId";
|
|
128
|
+
readonly outputs: readonly [{
|
|
129
|
+
readonly name: "";
|
|
130
|
+
readonly internalType: "uint256";
|
|
131
|
+
readonly type: "uint256";
|
|
132
|
+
}];
|
|
133
|
+
readonly stateMutability: "view";
|
|
134
|
+
}, {
|
|
135
|
+
readonly type: "function";
|
|
136
|
+
readonly inputs: readonly [{
|
|
137
|
+
readonly name: "data_";
|
|
138
|
+
readonly internalType: "bytes";
|
|
139
|
+
readonly type: "bytes";
|
|
140
|
+
}];
|
|
141
|
+
readonly name: "execute";
|
|
142
|
+
readonly outputs: readonly [{
|
|
143
|
+
readonly name: "";
|
|
144
|
+
readonly internalType: "bool";
|
|
145
|
+
readonly type: "bool";
|
|
146
|
+
}, {
|
|
147
|
+
readonly name: "";
|
|
148
|
+
readonly internalType: "bytes";
|
|
149
|
+
readonly type: "bytes";
|
|
150
|
+
}];
|
|
151
|
+
readonly stateMutability: "payable";
|
|
152
|
+
}, {
|
|
153
|
+
readonly type: "function";
|
|
154
|
+
readonly inputs: readonly [];
|
|
155
|
+
readonly name: "getComponentInterface";
|
|
156
|
+
readonly outputs: readonly [{
|
|
157
|
+
readonly name: "";
|
|
158
|
+
readonly internalType: "bytes4";
|
|
159
|
+
readonly type: "bytes4";
|
|
160
|
+
}];
|
|
161
|
+
readonly stateMutability: "pure";
|
|
162
|
+
}, {
|
|
163
|
+
readonly type: "function";
|
|
164
|
+
readonly inputs: readonly [{
|
|
165
|
+
readonly name: "data_";
|
|
166
|
+
readonly internalType: "bytes";
|
|
167
|
+
readonly type: "bytes";
|
|
168
|
+
}];
|
|
169
|
+
readonly name: "initialize";
|
|
170
|
+
readonly outputs: readonly [];
|
|
171
|
+
readonly stateMutability: "nonpayable";
|
|
172
|
+
}, {
|
|
173
|
+
readonly type: "function";
|
|
174
|
+
readonly inputs: readonly [{
|
|
175
|
+
readonly name: "data_";
|
|
176
|
+
readonly internalType: "bytes";
|
|
177
|
+
readonly type: "bytes";
|
|
178
|
+
}];
|
|
179
|
+
readonly name: "prepare";
|
|
180
|
+
readonly outputs: readonly [{
|
|
181
|
+
readonly name: "bytes_";
|
|
182
|
+
readonly internalType: "bytes";
|
|
183
|
+
readonly type: "bytes";
|
|
184
|
+
}];
|
|
185
|
+
readonly stateMutability: "view";
|
|
186
|
+
}, {
|
|
187
|
+
readonly type: "function";
|
|
188
|
+
readonly inputs: readonly [];
|
|
189
|
+
readonly name: "selector";
|
|
190
|
+
readonly outputs: readonly [{
|
|
191
|
+
readonly name: "";
|
|
192
|
+
readonly internalType: "bytes4";
|
|
193
|
+
readonly type: "bytes4";
|
|
194
|
+
}];
|
|
195
|
+
readonly stateMutability: "view";
|
|
196
|
+
}, {
|
|
197
|
+
readonly type: "function";
|
|
198
|
+
readonly inputs: readonly [{
|
|
199
|
+
readonly name: "interfaceId";
|
|
200
|
+
readonly internalType: "bytes4";
|
|
201
|
+
readonly type: "bytes4";
|
|
202
|
+
}];
|
|
203
|
+
readonly name: "supportsInterface";
|
|
204
|
+
readonly outputs: readonly [{
|
|
205
|
+
readonly name: "";
|
|
206
|
+
readonly internalType: "bool";
|
|
207
|
+
readonly type: "bool";
|
|
208
|
+
}];
|
|
209
|
+
readonly stateMutability: "view";
|
|
210
|
+
}, {
|
|
211
|
+
readonly type: "function";
|
|
212
|
+
readonly inputs: readonly [];
|
|
213
|
+
readonly name: "target";
|
|
214
|
+
readonly outputs: readonly [{
|
|
215
|
+
readonly name: "";
|
|
216
|
+
readonly internalType: "address";
|
|
217
|
+
readonly type: "address";
|
|
218
|
+
}];
|
|
219
|
+
readonly stateMutability: "view";
|
|
220
|
+
}, {
|
|
221
|
+
readonly type: "function";
|
|
222
|
+
readonly inputs: readonly [];
|
|
223
|
+
readonly name: "value";
|
|
224
|
+
readonly outputs: readonly [{
|
|
225
|
+
readonly name: "";
|
|
226
|
+
readonly internalType: "uint256";
|
|
227
|
+
readonly type: "uint256";
|
|
228
|
+
}];
|
|
229
|
+
readonly stateMutability: "view";
|
|
230
|
+
}];
|
|
231
|
+
/**
|
|
232
|
+
* @inheritdoc
|
|
233
|
+
*
|
|
234
|
+
* @public
|
|
235
|
+
* @static
|
|
236
|
+
* @type {Address}
|
|
237
|
+
*/
|
|
238
|
+
static base: Address;
|
|
239
|
+
/**
|
|
240
|
+
* @inheritdoc
|
|
241
|
+
*
|
|
242
|
+
* @public
|
|
243
|
+
* @static
|
|
244
|
+
* @type {RegistryType}
|
|
245
|
+
*/
|
|
246
|
+
static registryType: RegistryType;
|
|
247
|
+
/**
|
|
248
|
+
* The target chain ID
|
|
249
|
+
*
|
|
250
|
+
* @public
|
|
251
|
+
* @async
|
|
252
|
+
* @param {?ReadParams<typeof contractActionAbi, 'chainId'>} [params]
|
|
253
|
+
* @returns {Promise<bigint>}
|
|
254
|
+
*/
|
|
255
|
+
chainId(params?: ReadParams<typeof contractActionAbi, 'chainId'>): Promise<bigint>;
|
|
256
|
+
/**
|
|
257
|
+
* The target contract
|
|
258
|
+
*
|
|
259
|
+
* @public
|
|
260
|
+
* @async
|
|
261
|
+
* @param {?ReadParams<typeof contractActionAbi, 'target'>} [params]
|
|
262
|
+
* @returns {Promise<`0x${string}`>}
|
|
263
|
+
*/
|
|
264
|
+
target(params?: ReadParams<typeof contractActionAbi, 'target'>): Promise<`0x${string}`>;
|
|
265
|
+
/**
|
|
266
|
+
* The selector for the function to be called
|
|
267
|
+
*
|
|
268
|
+
* @example `function mint(address to, uint256 amount)`
|
|
269
|
+
* @public
|
|
270
|
+
* @async
|
|
271
|
+
* @param {?ReadParams<typeof contractActionAbi, 'selector'>} [params]
|
|
272
|
+
* @returns {Promise<`0x${string}`>}
|
|
273
|
+
*/
|
|
274
|
+
selector(params?: ReadParams<typeof contractActionAbi, 'selector'>): Promise<`0x${string}`>;
|
|
275
|
+
/**
|
|
276
|
+
* The native token value to send with the function call
|
|
277
|
+
*
|
|
278
|
+
* @public
|
|
279
|
+
* @async
|
|
280
|
+
* @param {?ReadParams<typeof contractActionAbi, 'value'>} [params]
|
|
281
|
+
* @returns {Promise<bigint>}
|
|
282
|
+
*/
|
|
283
|
+
value(params?: ReadParams<typeof contractActionAbi, 'value'>): Promise<bigint>;
|
|
284
|
+
/**
|
|
285
|
+
* Executes a prepared contract action
|
|
286
|
+
*
|
|
287
|
+
* @public
|
|
288
|
+
* @async
|
|
289
|
+
* @param {Hex} data
|
|
290
|
+
* @param {?WriteParams<typeof contractActionAbi, 'execute'>} [params]
|
|
291
|
+
* @returns {Promise<readonly [boolean, `0x${string}`]>}
|
|
292
|
+
*/
|
|
293
|
+
execute(data: Hex, params?: WriteParams<typeof contractActionAbi, 'execute'>): Promise<readonly [boolean, `0x${string}`]>;
|
|
294
|
+
/**
|
|
295
|
+
* Executes a prepared contract action
|
|
296
|
+
*
|
|
297
|
+
* @public
|
|
298
|
+
* @async
|
|
299
|
+
* @param {Hex} data
|
|
300
|
+
* @param {?WriteParams<typeof contractActionAbi, 'execute'>} [params]
|
|
301
|
+
* @returns {unknown}
|
|
302
|
+
*/
|
|
303
|
+
executeRaw(data: Hex, params?: WriteParams<typeof contractActionAbi, 'execute'>): Promise<{
|
|
304
|
+
hash: `0x${string}`;
|
|
305
|
+
result: readonly [boolean, `0x${string}`];
|
|
306
|
+
}>;
|
|
307
|
+
/**
|
|
308
|
+
* The encoded execution payload
|
|
309
|
+
*
|
|
310
|
+
* @public
|
|
311
|
+
* @async
|
|
312
|
+
* @param {Hex} calldata
|
|
313
|
+
* @param {?ReadParams<typeof contractActionAbi, 'prepare'>} [params]
|
|
314
|
+
* @returns {unknown}
|
|
315
|
+
*/
|
|
316
|
+
prepare(calldata: Hex, params?: ReadParams<typeof contractActionAbi, 'prepare'>): Promise<`0x${string}`>;
|
|
317
|
+
/**
|
|
318
|
+
* @inheritdoc
|
|
319
|
+
*
|
|
320
|
+
* @public
|
|
321
|
+
* @param {?ContractActionPayload} [_payload]
|
|
322
|
+
* @param {?DeployableOptions} [_options]
|
|
323
|
+
* @returns {GenericDeployableParams}
|
|
324
|
+
*/
|
|
325
|
+
buildParameters(_payload?: ContractActionPayload, _options?: DeployableOptions): GenericDeployableParams;
|
|
326
|
+
}
|
|
327
|
+
//# sourceMappingURL=ContractAction.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContractAction.d.ts","sourceRoot":"","sources":["../../src/Actions/ContractAction.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EAQlB,MAAM,eAAe,CAAC;AAEvB,OAAO,KAAK,EAAE,GAAG,EAAE,OAAO,EAAE,iBAAiB,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AACjE,OAAO,KAAK,EACV,iBAAiB,EACjB,uBAAuB,EACx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