@boostxyz/sdk 0.0.0-alpha.20 → 0.0.0-alpha.21
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/dist/Actions/Action.cjs +1 -1
- package/dist/Actions/Action.js +3 -3
- package/dist/Actions/EventAction.cjs +1 -1
- package/dist/Actions/EventAction.d.ts.map +1 -1
- package/dist/Actions/EventAction.js +3 -3
- package/dist/AllowLists/AllowList.cjs +1 -1
- package/dist/AllowLists/AllowList.js +3 -3
- package/dist/AllowLists/SimpleAllowList.cjs +1 -1
- package/dist/AllowLists/SimpleAllowList.js +13 -13
- package/dist/AllowLists/SimpleDenyList.cjs +1 -1
- package/dist/AllowLists/SimpleDenyList.js +3 -3
- package/dist/Auth/PassthroughAuth.cjs +1 -1
- package/dist/Auth/PassthroughAuth.js +1 -1
- package/dist/Boost.cjs +1 -1
- package/dist/Boost.cjs.map +1 -1
- package/dist/Boost.d.ts +5 -24
- package/dist/Boost.d.ts.map +1 -1
- package/dist/Boost.js +42 -44
- package/dist/Boost.js.map +1 -1
- package/dist/BoostCore-DolmDuXW.cjs +3 -0
- package/dist/BoostCore-DolmDuXW.cjs.map +1 -0
- package/dist/BoostCore-Z97KVu4V.js +1448 -0
- package/dist/BoostCore-Z97KVu4V.js.map +1 -0
- package/dist/BoostCore.cjs +1 -1
- package/dist/BoostCore.d.ts +633 -47
- package/dist/BoostCore.d.ts.map +1 -1
- package/dist/BoostCore.js +6 -6
- package/dist/BoostRegistry.cjs +1 -1
- package/dist/BoostRegistry.cjs.map +1 -1
- package/dist/BoostRegistry.d.ts +31 -3
- package/dist/BoostRegistry.d.ts.map +1 -1
- package/dist/BoostRegistry.js +68 -48
- package/dist/BoostRegistry.js.map +1 -1
- package/dist/Budgets/Budget.cjs +1 -1
- package/dist/Budgets/Budget.js +2 -2
- package/dist/Budgets/ManagedBudget.cjs +1 -1
- package/dist/Budgets/ManagedBudget.cjs.map +1 -1
- package/dist/Budgets/ManagedBudget.d.ts +34 -4
- package/dist/Budgets/ManagedBudget.d.ts.map +1 -1
- package/dist/Budgets/ManagedBudget.js +45 -45
- package/dist/Budgets/VestingBudget.d.ts +34 -4
- package/dist/Budgets/VestingBudget.d.ts.map +1 -1
- package/dist/Deployable/DeployableTarget.cjs +1 -1
- package/dist/Deployable/DeployableTarget.js +1 -1
- package/dist/Deployable/DeployableTargetWithRBAC.cjs +1 -1
- package/dist/Deployable/DeployableTargetWithRBAC.js +17 -17
- package/dist/EventAction-CBKzuNoN.cjs +2 -0
- package/dist/EventAction-CBKzuNoN.cjs.map +1 -0
- package/dist/{EventAction-CIPqmAoP.js → EventAction-DWuuc_Qy.js} +295 -217
- package/dist/EventAction-DWuuc_Qy.js.map +1 -0
- package/dist/Incentive-BxzEtN26.js +298 -0
- package/dist/Incentive-BxzEtN26.js.map +1 -0
- package/dist/Incentive-CrF3-ayL.cjs +2 -0
- package/dist/Incentive-CrF3-ayL.cjs.map +1 -0
- package/dist/Incentives/AllowListIncentive.cjs +1 -1
- package/dist/Incentives/AllowListIncentive.cjs.map +1 -1
- package/dist/Incentives/AllowListIncentive.d.ts +16 -2
- package/dist/Incentives/AllowListIncentive.d.ts.map +1 -1
- package/dist/Incentives/AllowListIncentive.js +13 -13
- package/dist/Incentives/AllowListIncentive.js.map +1 -1
- package/dist/Incentives/CGDAIncentive.cjs +1 -1
- package/dist/Incentives/CGDAIncentive.cjs.map +1 -1
- package/dist/Incentives/CGDAIncentive.d.ts +197 -4
- package/dist/Incentives/CGDAIncentive.d.ts.map +1 -1
- package/dist/Incentives/CGDAIncentive.js +31 -31
- package/dist/Incentives/CGDAIncentive.js.map +1 -1
- package/dist/Incentives/ERC1155Incentive.d.ts +192 -5
- package/dist/Incentives/ERC1155Incentive.d.ts.map +1 -1
- package/dist/Incentives/ERC20Incentive.cjs +1 -1
- package/dist/Incentives/ERC20Incentive.cjs.map +1 -1
- package/dist/Incentives/ERC20Incentive.d.ts +197 -4
- package/dist/Incentives/ERC20Incentive.d.ts.map +1 -1
- package/dist/Incentives/ERC20Incentive.js +17 -17
- package/dist/Incentives/ERC20Incentive.js.map +1 -1
- package/dist/Incentives/ERC20VariableCriteriaIncentive.d.ts +189 -2
- package/dist/Incentives/ERC20VariableCriteriaIncentive.d.ts.map +1 -1
- package/dist/Incentives/ERC20VariableIncentive.d.ts +197 -4
- package/dist/Incentives/ERC20VariableIncentive.d.ts.map +1 -1
- package/dist/Incentives/Incentive.cjs +1 -1
- package/dist/Incentives/Incentive.d.ts +1 -1
- package/dist/Incentives/Incentive.js +3 -3
- package/dist/Incentives/PointsIncentive.cjs +1 -1
- package/dist/Incentives/PointsIncentive.cjs.map +1 -1
- package/dist/Incentives/PointsIncentive.d.ts +16 -2
- package/dist/Incentives/PointsIncentive.d.ts.map +1 -1
- package/dist/Incentives/PointsIncentive.js +8 -8
- package/dist/Incentives/PointsIncentive.js.map +1 -1
- package/dist/{SimpleDenyList-BwfNjRsg.cjs → SimpleDenyList-BUR17Tt1.cjs} +2 -2
- package/dist/{SimpleDenyList-BwfNjRsg.cjs.map → SimpleDenyList-BUR17Tt1.cjs.map} +1 -1
- package/dist/{SimpleDenyList-Cn5WpNn0.js → SimpleDenyList-CGaWjuld.js} +15 -15
- package/dist/{SimpleDenyList-Cn5WpNn0.js.map → SimpleDenyList-CGaWjuld.js.map} +1 -1
- package/dist/Validators/SignerValidator.cjs +1 -1
- package/dist/Validators/SignerValidator.js +3 -3
- package/dist/Validators/Validator.cjs +1 -1
- package/dist/Validators/Validator.js +6 -6
- package/dist/componentInterfaces-BBCFkrZv.js +14 -0
- package/dist/componentInterfaces-BBCFkrZv.js.map +1 -0
- package/dist/componentInterfaces-DRI_dQ-P.cjs +2 -0
- package/dist/componentInterfaces-DRI_dQ-P.cjs.map +1 -0
- package/dist/deployments-DVXioW2i.cjs +2 -0
- package/dist/deployments-DVXioW2i.cjs.map +1 -0
- package/dist/deployments-oykLv3_Z.js +43 -0
- package/dist/deployments-oykLv3_Z.js.map +1 -0
- package/dist/deployments.json +16 -13
- package/dist/errors.cjs +1 -1
- package/dist/errors.cjs.map +1 -1
- package/dist/errors.d.ts +18 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +16 -4
- package/dist/errors.js.map +1 -1
- package/dist/{generated-B7VaSah4.js → generated-CKt2yCQd.js} +1071 -447
- package/dist/generated-CKt2yCQd.js.map +1 -0
- package/dist/generated-CyTNlOwM.cjs +3 -0
- package/dist/generated-CyTNlOwM.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +79 -78
- package/package.json +4 -4
- package/src/Actions/EventAction.ts +24 -20
- package/src/Boost.ts +5 -27
- package/src/BoostCore.test.ts +113 -46
- package/src/BoostCore.ts +162 -171
- package/src/BoostRegistry.test.ts +53 -0
- package/src/BoostRegistry.ts +48 -3
- package/src/Budgets/ManagedBudget.test.ts +7 -7
- package/src/Incentives/CGDAIncentive.test.ts +4 -1
- package/src/Incentives/CGDAIncentive.ts +6 -0
- package/src/Incentives/ERC20Incentive.test.ts +3 -0
- package/src/Incentives/ERC20Incentive.ts +6 -0
- package/src/Incentives/ERC20VariableIncentive.test.ts +3 -0
- package/src/Incentives/ERC20VariableIncentive.ts +6 -0
- package/src/Incentives/Incentive.test.ts +3 -0
- package/src/Incentives/Incentive.ts +1 -1
- package/src/Incentives/PointsIncentive.test.ts +1 -2
- package/src/errors.ts +22 -0
- package/dist/BoostCore-3-U1xTQN.cjs +0 -3
- package/dist/BoostCore-3-U1xTQN.cjs.map +0 -1
- package/dist/BoostCore-DVGBUr2y.js +0 -1477
- package/dist/BoostCore-DVGBUr2y.js.map +0 -1
- package/dist/EventAction-CIPqmAoP.js.map +0 -1
- package/dist/EventAction-d-oeqZQs.cjs +0 -2
- package/dist/EventAction-d-oeqZQs.cjs.map +0 -1
- package/dist/Incentive-Bp8Sez7M.js +0 -298
- package/dist/Incentive-Bp8Sez7M.js.map +0 -1
- package/dist/Incentive-Djnzseoj.cjs +0 -2
- package/dist/Incentive-Djnzseoj.cjs.map +0 -1
- package/dist/componentInterfaces-D09mhzxO.cjs +0 -2
- package/dist/componentInterfaces-D09mhzxO.cjs.map +0 -1
- package/dist/componentInterfaces-RXBMI5yH.js +0 -14
- package/dist/componentInterfaces-RXBMI5yH.js.map +0 -1
- package/dist/deployments-BM42vImE.js +0 -43
- package/dist/deployments-BM42vImE.js.map +0 -1
- package/dist/deployments-CMdF5uEC.cjs +0 -2
- package/dist/deployments-CMdF5uEC.cjs.map +0 -1
- package/dist/generated-B0tk-c9b.cjs +0 -3
- package/dist/generated-B0tk-c9b.cjs.map +0 -1
- package/dist/generated-B7VaSah4.js.map +0 -1
package/dist/BoostCore.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ import { OpenAllowList } from './AllowLists/OpenAllowList';
|
|
|
8
8
|
import { SimpleAllowList, type SimpleAllowListPayload } from './AllowLists/SimpleAllowList';
|
|
9
9
|
import { SimpleDenyList, type SimpleDenyListPayload } from './AllowLists/SimpleDenyList';
|
|
10
10
|
import { type Auth, PassthroughAuth } from './Auth/Auth';
|
|
11
|
-
import { Boost } from './Boost';
|
|
11
|
+
import { Boost, type RawBoost } from './Boost';
|
|
12
12
|
import { type Budget } from './Budgets/Budget';
|
|
13
13
|
import { ManagedBudget, type ManagedBudgetPayload } from './Budgets/ManagedBudget';
|
|
14
14
|
import { Deployable, type DeployableOptions, type DeployablePayloadOrAddress, type GenericDeployableParams } from './Deployable/Deployable';
|
|
@@ -115,7 +115,6 @@ export type CreateBoostPayload = {
|
|
|
115
115
|
allowList: AllowList;
|
|
116
116
|
incentives: Array<Incentive>;
|
|
117
117
|
protocolFee?: bigint;
|
|
118
|
-
referralFee?: bigint;
|
|
119
118
|
maxParticipants?: bigint;
|
|
120
119
|
owner?: Address;
|
|
121
120
|
};
|
|
@@ -163,10 +162,637 @@ export declare class BoostCore extends Deployable<[
|
|
|
163
162
|
* @public
|
|
164
163
|
* @async
|
|
165
164
|
* @param {CreateBoostPayload} _boostPayload
|
|
166
|
-
* @param {?DeployableOptions} [
|
|
165
|
+
* @param {?DeployableOptions} [_params]
|
|
167
166
|
* @returns {Promise<Boost>}
|
|
168
167
|
*/
|
|
169
168
|
createBoost(_boostPayload: CreateBoostPayload, _params?: DeployableOptions & WriteParams<typeof boostCoreAbi, 'createBoost'>): Promise<Boost>;
|
|
169
|
+
/**
|
|
170
|
+
* Returns a simulated Boost creation.
|
|
171
|
+
*
|
|
172
|
+
* @public
|
|
173
|
+
* @async
|
|
174
|
+
* @param {CreateBoostPayload} _boostPayload
|
|
175
|
+
* @param {?DeployableOptions} [_params]
|
|
176
|
+
* @returns {Promise<SimulateContractReturnType>}
|
|
177
|
+
*/
|
|
178
|
+
simulateCreateBoost(_boostPayload: CreateBoostPayload, _params?: DeployableOptions & WriteParams<typeof boostCoreAbi, 'createBoost'>): Promise<import("viem").SimulateContractReturnType<readonly [{
|
|
179
|
+
readonly type: "constructor";
|
|
180
|
+
readonly inputs: readonly [{
|
|
181
|
+
readonly name: "registry_";
|
|
182
|
+
readonly internalType: "contract BoostRegistry";
|
|
183
|
+
readonly type: "address";
|
|
184
|
+
}, {
|
|
185
|
+
readonly name: "protocolFeeReceiver_";
|
|
186
|
+
readonly internalType: "address";
|
|
187
|
+
readonly type: "address";
|
|
188
|
+
}];
|
|
189
|
+
readonly stateMutability: "nonpayable";
|
|
190
|
+
}, {
|
|
191
|
+
readonly type: "error";
|
|
192
|
+
readonly inputs: readonly [];
|
|
193
|
+
readonly name: "AlreadyInitialized";
|
|
194
|
+
}, {
|
|
195
|
+
readonly type: "error";
|
|
196
|
+
readonly inputs: readonly [{
|
|
197
|
+
readonly name: "caller";
|
|
198
|
+
readonly internalType: "address";
|
|
199
|
+
readonly type: "address";
|
|
200
|
+
}, {
|
|
201
|
+
readonly name: "data";
|
|
202
|
+
readonly internalType: "bytes";
|
|
203
|
+
readonly type: "bytes";
|
|
204
|
+
}];
|
|
205
|
+
readonly name: "ClaimFailed";
|
|
206
|
+
}, {
|
|
207
|
+
readonly type: "error";
|
|
208
|
+
readonly inputs: readonly [{
|
|
209
|
+
readonly name: "caller";
|
|
210
|
+
readonly internalType: "address";
|
|
211
|
+
readonly type: "address";
|
|
212
|
+
}, {
|
|
213
|
+
readonly name: "data";
|
|
214
|
+
readonly internalType: "bytes";
|
|
215
|
+
readonly type: "bytes";
|
|
216
|
+
}];
|
|
217
|
+
readonly name: "ClawbackFailed";
|
|
218
|
+
}, {
|
|
219
|
+
readonly type: "error";
|
|
220
|
+
readonly inputs: readonly [];
|
|
221
|
+
readonly name: "InvalidInitialization";
|
|
222
|
+
}, {
|
|
223
|
+
readonly type: "error";
|
|
224
|
+
readonly inputs: readonly [{
|
|
225
|
+
readonly name: "expectedInterface";
|
|
226
|
+
readonly internalType: "bytes4";
|
|
227
|
+
readonly type: "bytes4";
|
|
228
|
+
}, {
|
|
229
|
+
readonly name: "instance";
|
|
230
|
+
readonly internalType: "address";
|
|
231
|
+
readonly type: "address";
|
|
232
|
+
}];
|
|
233
|
+
readonly name: "InvalidInstance";
|
|
234
|
+
}, {
|
|
235
|
+
readonly type: "error";
|
|
236
|
+
readonly inputs: readonly [];
|
|
237
|
+
readonly name: "NewOwnerIsZeroAddress";
|
|
238
|
+
}, {
|
|
239
|
+
readonly type: "error";
|
|
240
|
+
readonly inputs: readonly [];
|
|
241
|
+
readonly name: "NoHandoverRequest";
|
|
242
|
+
}, {
|
|
243
|
+
readonly type: "error";
|
|
244
|
+
readonly inputs: readonly [];
|
|
245
|
+
readonly name: "NotImplemented";
|
|
246
|
+
}, {
|
|
247
|
+
readonly type: "error";
|
|
248
|
+
readonly inputs: readonly [];
|
|
249
|
+
readonly name: "Reentrancy";
|
|
250
|
+
}, {
|
|
251
|
+
readonly type: "error";
|
|
252
|
+
readonly inputs: readonly [];
|
|
253
|
+
readonly name: "Unauthorized";
|
|
254
|
+
}, {
|
|
255
|
+
readonly type: "error";
|
|
256
|
+
readonly inputs: readonly [];
|
|
257
|
+
readonly name: "Unauthorized";
|
|
258
|
+
}, {
|
|
259
|
+
readonly type: "event";
|
|
260
|
+
readonly anonymous: false;
|
|
261
|
+
readonly inputs: readonly [{
|
|
262
|
+
readonly name: "boostId";
|
|
263
|
+
readonly internalType: "uint256";
|
|
264
|
+
readonly type: "uint256";
|
|
265
|
+
readonly indexed: true;
|
|
266
|
+
}, {
|
|
267
|
+
readonly name: "incentiveId";
|
|
268
|
+
readonly internalType: "uint256";
|
|
269
|
+
readonly type: "uint256";
|
|
270
|
+
readonly indexed: true;
|
|
271
|
+
}, {
|
|
272
|
+
readonly name: "claimant";
|
|
273
|
+
readonly internalType: "address";
|
|
274
|
+
readonly type: "address";
|
|
275
|
+
readonly indexed: true;
|
|
276
|
+
}, {
|
|
277
|
+
readonly name: "referrer";
|
|
278
|
+
readonly internalType: "address";
|
|
279
|
+
readonly type: "address";
|
|
280
|
+
readonly indexed: false;
|
|
281
|
+
}, {
|
|
282
|
+
readonly name: "data";
|
|
283
|
+
readonly internalType: "bytes";
|
|
284
|
+
readonly type: "bytes";
|
|
285
|
+
readonly indexed: false;
|
|
286
|
+
}];
|
|
287
|
+
readonly name: "BoostClaimed";
|
|
288
|
+
}, {
|
|
289
|
+
readonly type: "event";
|
|
290
|
+
readonly anonymous: false;
|
|
291
|
+
readonly inputs: readonly [{
|
|
292
|
+
readonly name: "boostId";
|
|
293
|
+
readonly internalType: "uint256";
|
|
294
|
+
readonly type: "uint256";
|
|
295
|
+
readonly indexed: true;
|
|
296
|
+
}, {
|
|
297
|
+
readonly name: "owner";
|
|
298
|
+
readonly internalType: "address";
|
|
299
|
+
readonly type: "address";
|
|
300
|
+
readonly indexed: true;
|
|
301
|
+
}, {
|
|
302
|
+
readonly name: "action";
|
|
303
|
+
readonly internalType: "address";
|
|
304
|
+
readonly type: "address";
|
|
305
|
+
readonly indexed: true;
|
|
306
|
+
}, {
|
|
307
|
+
readonly name: "incentiveCount";
|
|
308
|
+
readonly internalType: "uint256";
|
|
309
|
+
readonly type: "uint256";
|
|
310
|
+
readonly indexed: false;
|
|
311
|
+
}, {
|
|
312
|
+
readonly name: "validator";
|
|
313
|
+
readonly internalType: "address";
|
|
314
|
+
readonly type: "address";
|
|
315
|
+
readonly indexed: false;
|
|
316
|
+
}, {
|
|
317
|
+
readonly name: "allowList";
|
|
318
|
+
readonly internalType: "address";
|
|
319
|
+
readonly type: "address";
|
|
320
|
+
readonly indexed: false;
|
|
321
|
+
}, {
|
|
322
|
+
readonly name: "budget";
|
|
323
|
+
readonly internalType: "address";
|
|
324
|
+
readonly type: "address";
|
|
325
|
+
readonly indexed: false;
|
|
326
|
+
}];
|
|
327
|
+
readonly name: "BoostCreated";
|
|
328
|
+
}, {
|
|
329
|
+
readonly type: "event";
|
|
330
|
+
readonly anonymous: false;
|
|
331
|
+
readonly inputs: readonly [{
|
|
332
|
+
readonly name: "pendingOwner";
|
|
333
|
+
readonly internalType: "address";
|
|
334
|
+
readonly type: "address";
|
|
335
|
+
readonly indexed: true;
|
|
336
|
+
}];
|
|
337
|
+
readonly name: "OwnershipHandoverCanceled";
|
|
338
|
+
}, {
|
|
339
|
+
readonly type: "event";
|
|
340
|
+
readonly anonymous: false;
|
|
341
|
+
readonly inputs: readonly [{
|
|
342
|
+
readonly name: "pendingOwner";
|
|
343
|
+
readonly internalType: "address";
|
|
344
|
+
readonly type: "address";
|
|
345
|
+
readonly indexed: true;
|
|
346
|
+
}];
|
|
347
|
+
readonly name: "OwnershipHandoverRequested";
|
|
348
|
+
}, {
|
|
349
|
+
readonly type: "event";
|
|
350
|
+
readonly anonymous: false;
|
|
351
|
+
readonly inputs: readonly [{
|
|
352
|
+
readonly name: "oldOwner";
|
|
353
|
+
readonly internalType: "address";
|
|
354
|
+
readonly type: "address";
|
|
355
|
+
readonly indexed: true;
|
|
356
|
+
}, {
|
|
357
|
+
readonly name: "newOwner";
|
|
358
|
+
readonly internalType: "address";
|
|
359
|
+
readonly type: "address";
|
|
360
|
+
readonly indexed: true;
|
|
361
|
+
}];
|
|
362
|
+
readonly name: "OwnershipTransferred";
|
|
363
|
+
}, {
|
|
364
|
+
readonly type: "event";
|
|
365
|
+
readonly anonymous: false;
|
|
366
|
+
readonly inputs: readonly [{
|
|
367
|
+
readonly name: "boostId";
|
|
368
|
+
readonly internalType: "uint256";
|
|
369
|
+
readonly type: "uint256";
|
|
370
|
+
readonly indexed: true;
|
|
371
|
+
}, {
|
|
372
|
+
readonly name: "incentiveId";
|
|
373
|
+
readonly internalType: "uint256";
|
|
374
|
+
readonly type: "uint256";
|
|
375
|
+
readonly indexed: true;
|
|
376
|
+
}, {
|
|
377
|
+
readonly name: "amount";
|
|
378
|
+
readonly internalType: "uint256";
|
|
379
|
+
readonly type: "uint256";
|
|
380
|
+
readonly indexed: false;
|
|
381
|
+
}, {
|
|
382
|
+
readonly name: "recipient";
|
|
383
|
+
readonly internalType: "address";
|
|
384
|
+
readonly type: "address";
|
|
385
|
+
readonly indexed: true;
|
|
386
|
+
}];
|
|
387
|
+
readonly name: "ProtocolFeesCollected";
|
|
388
|
+
}, {
|
|
389
|
+
readonly type: "function";
|
|
390
|
+
readonly inputs: readonly [];
|
|
391
|
+
readonly name: "FEE_DENOMINATOR";
|
|
392
|
+
readonly outputs: readonly [{
|
|
393
|
+
readonly name: "";
|
|
394
|
+
readonly internalType: "uint64";
|
|
395
|
+
readonly type: "uint64";
|
|
396
|
+
}];
|
|
397
|
+
readonly stateMutability: "view";
|
|
398
|
+
}, {
|
|
399
|
+
readonly type: "function";
|
|
400
|
+
readonly inputs: readonly [];
|
|
401
|
+
readonly name: "cancelOwnershipHandover";
|
|
402
|
+
readonly outputs: readonly [];
|
|
403
|
+
readonly stateMutability: "payable";
|
|
404
|
+
}, {
|
|
405
|
+
readonly type: "function";
|
|
406
|
+
readonly inputs: readonly [{
|
|
407
|
+
readonly name: "boostId_";
|
|
408
|
+
readonly internalType: "uint256";
|
|
409
|
+
readonly type: "uint256";
|
|
410
|
+
}, {
|
|
411
|
+
readonly name: "incentiveId_";
|
|
412
|
+
readonly internalType: "uint256";
|
|
413
|
+
readonly type: "uint256";
|
|
414
|
+
}, {
|
|
415
|
+
readonly name: "referrer_";
|
|
416
|
+
readonly internalType: "address";
|
|
417
|
+
readonly type: "address";
|
|
418
|
+
}, {
|
|
419
|
+
readonly name: "data_";
|
|
420
|
+
readonly internalType: "bytes";
|
|
421
|
+
readonly type: "bytes";
|
|
422
|
+
}];
|
|
423
|
+
readonly name: "claimIncentive";
|
|
424
|
+
readonly outputs: readonly [];
|
|
425
|
+
readonly stateMutability: "payable";
|
|
426
|
+
}, {
|
|
427
|
+
readonly type: "function";
|
|
428
|
+
readonly inputs: readonly [{
|
|
429
|
+
readonly name: "boostId_";
|
|
430
|
+
readonly internalType: "uint256";
|
|
431
|
+
readonly type: "uint256";
|
|
432
|
+
}, {
|
|
433
|
+
readonly name: "incentiveId_";
|
|
434
|
+
readonly internalType: "uint256";
|
|
435
|
+
readonly type: "uint256";
|
|
436
|
+
}, {
|
|
437
|
+
readonly name: "referrer_";
|
|
438
|
+
readonly internalType: "address";
|
|
439
|
+
readonly type: "address";
|
|
440
|
+
}, {
|
|
441
|
+
readonly name: "data_";
|
|
442
|
+
readonly internalType: "bytes";
|
|
443
|
+
readonly type: "bytes";
|
|
444
|
+
}, {
|
|
445
|
+
readonly name: "claimant";
|
|
446
|
+
readonly internalType: "address";
|
|
447
|
+
readonly type: "address";
|
|
448
|
+
}];
|
|
449
|
+
readonly name: "claimIncentiveFor";
|
|
450
|
+
readonly outputs: readonly [];
|
|
451
|
+
readonly stateMutability: "payable";
|
|
452
|
+
}, {
|
|
453
|
+
readonly type: "function";
|
|
454
|
+
readonly inputs: readonly [{
|
|
455
|
+
readonly name: "data_";
|
|
456
|
+
readonly internalType: "bytes";
|
|
457
|
+
readonly type: "bytes";
|
|
458
|
+
}, {
|
|
459
|
+
readonly name: "boostId";
|
|
460
|
+
readonly internalType: "uint256";
|
|
461
|
+
readonly type: "uint256";
|
|
462
|
+
}, {
|
|
463
|
+
readonly name: "incentiveId";
|
|
464
|
+
readonly internalType: "uint256";
|
|
465
|
+
readonly type: "uint256";
|
|
466
|
+
}];
|
|
467
|
+
readonly name: "clawback";
|
|
468
|
+
readonly outputs: readonly [{
|
|
469
|
+
readonly name: "";
|
|
470
|
+
readonly internalType: "uint256";
|
|
471
|
+
readonly type: "uint256";
|
|
472
|
+
}, {
|
|
473
|
+
readonly name: "";
|
|
474
|
+
readonly internalType: "address";
|
|
475
|
+
readonly type: "address";
|
|
476
|
+
}];
|
|
477
|
+
readonly stateMutability: "nonpayable";
|
|
478
|
+
}, {
|
|
479
|
+
readonly type: "function";
|
|
480
|
+
readonly inputs: readonly [{
|
|
481
|
+
readonly name: "pendingOwner";
|
|
482
|
+
readonly internalType: "address";
|
|
483
|
+
readonly type: "address";
|
|
484
|
+
}];
|
|
485
|
+
readonly name: "completeOwnershipHandover";
|
|
486
|
+
readonly outputs: readonly [];
|
|
487
|
+
readonly stateMutability: "payable";
|
|
488
|
+
}, {
|
|
489
|
+
readonly type: "function";
|
|
490
|
+
readonly inputs: readonly [{
|
|
491
|
+
readonly name: "data_";
|
|
492
|
+
readonly internalType: "bytes";
|
|
493
|
+
readonly type: "bytes";
|
|
494
|
+
}];
|
|
495
|
+
readonly name: "createBoost";
|
|
496
|
+
readonly outputs: readonly [{
|
|
497
|
+
readonly name: "";
|
|
498
|
+
readonly internalType: "struct BoostLib.Boost";
|
|
499
|
+
readonly type: "tuple";
|
|
500
|
+
readonly components: readonly [{
|
|
501
|
+
readonly name: "action";
|
|
502
|
+
readonly internalType: "contract AAction";
|
|
503
|
+
readonly type: "address";
|
|
504
|
+
}, {
|
|
505
|
+
readonly name: "validator";
|
|
506
|
+
readonly internalType: "contract AValidator";
|
|
507
|
+
readonly type: "address";
|
|
508
|
+
}, {
|
|
509
|
+
readonly name: "allowList";
|
|
510
|
+
readonly internalType: "contract AAllowList";
|
|
511
|
+
readonly type: "address";
|
|
512
|
+
}, {
|
|
513
|
+
readonly name: "budget";
|
|
514
|
+
readonly internalType: "contract ABudget";
|
|
515
|
+
readonly type: "address";
|
|
516
|
+
}, {
|
|
517
|
+
readonly name: "incentives";
|
|
518
|
+
readonly internalType: "contract AIncentive[]";
|
|
519
|
+
readonly type: "address[]";
|
|
520
|
+
}, {
|
|
521
|
+
readonly name: "protocolFee";
|
|
522
|
+
readonly internalType: "uint64";
|
|
523
|
+
readonly type: "uint64";
|
|
524
|
+
}, {
|
|
525
|
+
readonly name: "maxParticipants";
|
|
526
|
+
readonly internalType: "uint256";
|
|
527
|
+
readonly type: "uint256";
|
|
528
|
+
}, {
|
|
529
|
+
readonly name: "owner";
|
|
530
|
+
readonly internalType: "address";
|
|
531
|
+
readonly type: "address";
|
|
532
|
+
}];
|
|
533
|
+
}];
|
|
534
|
+
readonly stateMutability: "nonpayable";
|
|
535
|
+
}, {
|
|
536
|
+
readonly type: "function";
|
|
537
|
+
readonly inputs: readonly [];
|
|
538
|
+
readonly name: "createBoostAuth";
|
|
539
|
+
readonly outputs: readonly [{
|
|
540
|
+
readonly name: "";
|
|
541
|
+
readonly internalType: "contract IAuth";
|
|
542
|
+
readonly type: "address";
|
|
543
|
+
}];
|
|
544
|
+
readonly stateMutability: "view";
|
|
545
|
+
}, {
|
|
546
|
+
readonly type: "function";
|
|
547
|
+
readonly inputs: readonly [{
|
|
548
|
+
readonly name: "index";
|
|
549
|
+
readonly internalType: "uint256";
|
|
550
|
+
readonly type: "uint256";
|
|
551
|
+
}];
|
|
552
|
+
readonly name: "getBoost";
|
|
553
|
+
readonly outputs: readonly [{
|
|
554
|
+
readonly name: "";
|
|
555
|
+
readonly internalType: "struct BoostLib.Boost";
|
|
556
|
+
readonly type: "tuple";
|
|
557
|
+
readonly components: readonly [{
|
|
558
|
+
readonly name: "action";
|
|
559
|
+
readonly internalType: "contract AAction";
|
|
560
|
+
readonly type: "address";
|
|
561
|
+
}, {
|
|
562
|
+
readonly name: "validator";
|
|
563
|
+
readonly internalType: "contract AValidator";
|
|
564
|
+
readonly type: "address";
|
|
565
|
+
}, {
|
|
566
|
+
readonly name: "allowList";
|
|
567
|
+
readonly internalType: "contract AAllowList";
|
|
568
|
+
readonly type: "address";
|
|
569
|
+
}, {
|
|
570
|
+
readonly name: "budget";
|
|
571
|
+
readonly internalType: "contract ABudget";
|
|
572
|
+
readonly type: "address";
|
|
573
|
+
}, {
|
|
574
|
+
readonly name: "incentives";
|
|
575
|
+
readonly internalType: "contract AIncentive[]";
|
|
576
|
+
readonly type: "address[]";
|
|
577
|
+
}, {
|
|
578
|
+
readonly name: "protocolFee";
|
|
579
|
+
readonly internalType: "uint64";
|
|
580
|
+
readonly type: "uint64";
|
|
581
|
+
}, {
|
|
582
|
+
readonly name: "maxParticipants";
|
|
583
|
+
readonly internalType: "uint256";
|
|
584
|
+
readonly type: "uint256";
|
|
585
|
+
}, {
|
|
586
|
+
readonly name: "owner";
|
|
587
|
+
readonly internalType: "address";
|
|
588
|
+
readonly type: "address";
|
|
589
|
+
}];
|
|
590
|
+
}];
|
|
591
|
+
readonly stateMutability: "view";
|
|
592
|
+
}, {
|
|
593
|
+
readonly type: "function";
|
|
594
|
+
readonly inputs: readonly [];
|
|
595
|
+
readonly name: "getBoostCount";
|
|
596
|
+
readonly outputs: readonly [{
|
|
597
|
+
readonly name: "";
|
|
598
|
+
readonly internalType: "uint256";
|
|
599
|
+
readonly type: "uint256";
|
|
600
|
+
}];
|
|
601
|
+
readonly stateMutability: "view";
|
|
602
|
+
}, {
|
|
603
|
+
readonly type: "function";
|
|
604
|
+
readonly inputs: readonly [{
|
|
605
|
+
readonly name: "key";
|
|
606
|
+
readonly internalType: "bytes32";
|
|
607
|
+
readonly type: "bytes32";
|
|
608
|
+
}];
|
|
609
|
+
readonly name: "getIncentive";
|
|
610
|
+
readonly outputs: readonly [{
|
|
611
|
+
readonly name: "";
|
|
612
|
+
readonly internalType: "struct BoostCore.IncentiveDisbursalInfo";
|
|
613
|
+
readonly type: "tuple";
|
|
614
|
+
readonly components: readonly [{
|
|
615
|
+
readonly name: "assetType";
|
|
616
|
+
readonly internalType: "enum ABudget.AssetType";
|
|
617
|
+
readonly type: "uint8";
|
|
618
|
+
}, {
|
|
619
|
+
readonly name: "asset";
|
|
620
|
+
readonly internalType: "address";
|
|
621
|
+
readonly type: "address";
|
|
622
|
+
}, {
|
|
623
|
+
readonly name: "protocolFeesRemaining";
|
|
624
|
+
readonly internalType: "uint256";
|
|
625
|
+
readonly type: "uint256";
|
|
626
|
+
}, {
|
|
627
|
+
readonly name: "protocolFee";
|
|
628
|
+
readonly internalType: "uint256";
|
|
629
|
+
readonly type: "uint256";
|
|
630
|
+
}, {
|
|
631
|
+
readonly name: "tokenId";
|
|
632
|
+
readonly internalType: "uint256";
|
|
633
|
+
readonly type: "uint256";
|
|
634
|
+
}];
|
|
635
|
+
}];
|
|
636
|
+
readonly stateMutability: "view";
|
|
637
|
+
}, {
|
|
638
|
+
readonly type: "function";
|
|
639
|
+
readonly inputs: readonly [{
|
|
640
|
+
readonly name: "";
|
|
641
|
+
readonly internalType: "bytes32";
|
|
642
|
+
readonly type: "bytes32";
|
|
643
|
+
}];
|
|
644
|
+
readonly name: "incentives";
|
|
645
|
+
readonly outputs: readonly [{
|
|
646
|
+
readonly name: "assetType";
|
|
647
|
+
readonly internalType: "enum ABudget.AssetType";
|
|
648
|
+
readonly type: "uint8";
|
|
649
|
+
}, {
|
|
650
|
+
readonly name: "asset";
|
|
651
|
+
readonly internalType: "address";
|
|
652
|
+
readonly type: "address";
|
|
653
|
+
}, {
|
|
654
|
+
readonly name: "protocolFeesRemaining";
|
|
655
|
+
readonly internalType: "uint256";
|
|
656
|
+
readonly type: "uint256";
|
|
657
|
+
}, {
|
|
658
|
+
readonly name: "protocolFee";
|
|
659
|
+
readonly internalType: "uint256";
|
|
660
|
+
readonly type: "uint256";
|
|
661
|
+
}, {
|
|
662
|
+
readonly name: "tokenId";
|
|
663
|
+
readonly internalType: "uint256";
|
|
664
|
+
readonly type: "uint256";
|
|
665
|
+
}];
|
|
666
|
+
readonly stateMutability: "view";
|
|
667
|
+
}, {
|
|
668
|
+
readonly type: "function";
|
|
669
|
+
readonly inputs: readonly [];
|
|
670
|
+
readonly name: "owner";
|
|
671
|
+
readonly outputs: readonly [{
|
|
672
|
+
readonly name: "result";
|
|
673
|
+
readonly internalType: "address";
|
|
674
|
+
readonly type: "address";
|
|
675
|
+
}];
|
|
676
|
+
readonly stateMutability: "view";
|
|
677
|
+
}, {
|
|
678
|
+
readonly type: "function";
|
|
679
|
+
readonly inputs: readonly [{
|
|
680
|
+
readonly name: "pendingOwner";
|
|
681
|
+
readonly internalType: "address";
|
|
682
|
+
readonly type: "address";
|
|
683
|
+
}];
|
|
684
|
+
readonly name: "ownershipHandoverExpiresAt";
|
|
685
|
+
readonly outputs: readonly [{
|
|
686
|
+
readonly name: "result";
|
|
687
|
+
readonly internalType: "uint256";
|
|
688
|
+
readonly type: "uint256";
|
|
689
|
+
}];
|
|
690
|
+
readonly stateMutability: "view";
|
|
691
|
+
}, {
|
|
692
|
+
readonly type: "function";
|
|
693
|
+
readonly inputs: readonly [];
|
|
694
|
+
readonly name: "protocolFee";
|
|
695
|
+
readonly outputs: readonly [{
|
|
696
|
+
readonly name: "";
|
|
697
|
+
readonly internalType: "uint64";
|
|
698
|
+
readonly type: "uint64";
|
|
699
|
+
}];
|
|
700
|
+
readonly stateMutability: "view";
|
|
701
|
+
}, {
|
|
702
|
+
readonly type: "function";
|
|
703
|
+
readonly inputs: readonly [];
|
|
704
|
+
readonly name: "protocolFeeReceiver";
|
|
705
|
+
readonly outputs: readonly [{
|
|
706
|
+
readonly name: "";
|
|
707
|
+
readonly internalType: "address";
|
|
708
|
+
readonly type: "address";
|
|
709
|
+
}];
|
|
710
|
+
readonly stateMutability: "view";
|
|
711
|
+
}, {
|
|
712
|
+
readonly type: "function";
|
|
713
|
+
readonly inputs: readonly [];
|
|
714
|
+
readonly name: "registry";
|
|
715
|
+
readonly outputs: readonly [{
|
|
716
|
+
readonly name: "";
|
|
717
|
+
readonly internalType: "contract BoostRegistry";
|
|
718
|
+
readonly type: "address";
|
|
719
|
+
}];
|
|
720
|
+
readonly stateMutability: "view";
|
|
721
|
+
}, {
|
|
722
|
+
readonly type: "function";
|
|
723
|
+
readonly inputs: readonly [];
|
|
724
|
+
readonly name: "renounceOwnership";
|
|
725
|
+
readonly outputs: readonly [];
|
|
726
|
+
readonly stateMutability: "payable";
|
|
727
|
+
}, {
|
|
728
|
+
readonly type: "function";
|
|
729
|
+
readonly inputs: readonly [];
|
|
730
|
+
readonly name: "requestOwnershipHandover";
|
|
731
|
+
readonly outputs: readonly [];
|
|
732
|
+
readonly stateMutability: "payable";
|
|
733
|
+
}, {
|
|
734
|
+
readonly type: "function";
|
|
735
|
+
readonly inputs: readonly [{
|
|
736
|
+
readonly name: "auth_";
|
|
737
|
+
readonly internalType: "address";
|
|
738
|
+
readonly type: "address";
|
|
739
|
+
}];
|
|
740
|
+
readonly name: "setCreateBoostAuth";
|
|
741
|
+
readonly outputs: readonly [];
|
|
742
|
+
readonly stateMutability: "nonpayable";
|
|
743
|
+
}, {
|
|
744
|
+
readonly type: "function";
|
|
745
|
+
readonly inputs: readonly [{
|
|
746
|
+
readonly name: "protocolFee_";
|
|
747
|
+
readonly internalType: "uint64";
|
|
748
|
+
readonly type: "uint64";
|
|
749
|
+
}];
|
|
750
|
+
readonly name: "setProtocolFee";
|
|
751
|
+
readonly outputs: readonly [];
|
|
752
|
+
readonly stateMutability: "nonpayable";
|
|
753
|
+
}, {
|
|
754
|
+
readonly type: "function";
|
|
755
|
+
readonly inputs: readonly [{
|
|
756
|
+
readonly name: "protocolFeeReceiver_";
|
|
757
|
+
readonly internalType: "address";
|
|
758
|
+
readonly type: "address";
|
|
759
|
+
}];
|
|
760
|
+
readonly name: "setProtocolFeeReceiver";
|
|
761
|
+
readonly outputs: readonly [];
|
|
762
|
+
readonly stateMutability: "nonpayable";
|
|
763
|
+
}, {
|
|
764
|
+
readonly type: "function";
|
|
765
|
+
readonly inputs: readonly [{
|
|
766
|
+
readonly name: "boostId";
|
|
767
|
+
readonly internalType: "uint256";
|
|
768
|
+
readonly type: "uint256";
|
|
769
|
+
}, {
|
|
770
|
+
readonly name: "incentiveId";
|
|
771
|
+
readonly internalType: "uint256";
|
|
772
|
+
readonly type: "uint256";
|
|
773
|
+
}];
|
|
774
|
+
readonly name: "settleProtocolFees";
|
|
775
|
+
readonly outputs: readonly [];
|
|
776
|
+
readonly stateMutability: "nonpayable";
|
|
777
|
+
}, {
|
|
778
|
+
readonly type: "function";
|
|
779
|
+
readonly inputs: readonly [{
|
|
780
|
+
readonly name: "newOwner";
|
|
781
|
+
readonly internalType: "address";
|
|
782
|
+
readonly type: "address";
|
|
783
|
+
}];
|
|
784
|
+
readonly name: "transferOwnership";
|
|
785
|
+
readonly outputs: readonly [];
|
|
786
|
+
readonly stateMutability: "payable";
|
|
787
|
+
}], "createBoost", readonly [`0x${string}`], import("viem").Chain, import("viem").Account, import("viem").Chain> & {
|
|
788
|
+
chainId: number;
|
|
789
|
+
request: {
|
|
790
|
+
chainId?: undefined;
|
|
791
|
+
__mode: "prepared";
|
|
792
|
+
chain: import("viem").Chain;
|
|
793
|
+
};
|
|
794
|
+
}>;
|
|
795
|
+
private prepareCreateBoostPayload;
|
|
170
796
|
/**
|
|
171
797
|
* Claims one incentive from a given `Boost` by `boostId` and `incentiveId`
|
|
172
798
|
*
|
|
@@ -232,21 +858,12 @@ export declare class BoostCore extends Deployable<[
|
|
|
232
858
|
*
|
|
233
859
|
* @public
|
|
234
860
|
* @async
|
|
235
|
-
* @param {bigint} id
|
|
861
|
+
* @param {bigint | string} id
|
|
236
862
|
* @param {?ReadParams} [params]
|
|
237
863
|
* @returns {Promise<RawBoost>}
|
|
864
|
+
* @throws {@link BoostNotFoundError}
|
|
238
865
|
*/
|
|
239
|
-
readBoost(
|
|
240
|
-
action: `0x${string}`;
|
|
241
|
-
validator: `0x${string}`;
|
|
242
|
-
allowList: `0x${string}`;
|
|
243
|
-
budget: `0x${string}`;
|
|
244
|
-
incentives: readonly `0x${string}`[];
|
|
245
|
-
protocolFee: bigint;
|
|
246
|
-
referralFee: bigint;
|
|
247
|
-
maxParticipants: bigint;
|
|
248
|
-
owner: `0x${string}`;
|
|
249
|
-
}>;
|
|
866
|
+
readBoost(_id: string | bigint, params?: ReadParams<typeof boostCoreAbi, 'getBoost'>): Promise<RawBoost>;
|
|
250
867
|
/**
|
|
251
868
|
* Get a Boost by index, will return a new {@link Boost} with correct target implementations instantiated, ie `(await core.getBoost(0n)).allowList instanceof SimpleAllowList` vs `SimpleDenyList`
|
|
252
869
|
*
|
|
@@ -255,6 +872,7 @@ export declare class BoostCore extends Deployable<[
|
|
|
255
872
|
* @param {(string | bigint)} _id
|
|
256
873
|
* @param {?ReadParams} [params]
|
|
257
874
|
* @returns {Promise<Boost>}
|
|
875
|
+
* @throws {@link BoostNotFoundError}
|
|
258
876
|
*/
|
|
259
877
|
getBoost(_id: string | bigint, params?: ReadParams<typeof boostCoreAbi, 'getBoost'>): Promise<Boost>;
|
|
260
878
|
/**
|
|
@@ -350,38 +968,6 @@ export declare class BoostCore extends Deployable<[
|
|
|
350
968
|
hash: `0x${string}`;
|
|
351
969
|
result: void;
|
|
352
970
|
}>;
|
|
353
|
-
/**
|
|
354
|
-
* Get the claim fee.
|
|
355
|
-
*
|
|
356
|
-
* @public
|
|
357
|
-
* @async
|
|
358
|
-
* @param {?ReadParams} [params]
|
|
359
|
-
* @returns {Promise<bigint>}
|
|
360
|
-
*/
|
|
361
|
-
claimFee(params?: ReadParams<typeof boostCoreAbi, 'claimFee'>): Promise<bigint>;
|
|
362
|
-
/**
|
|
363
|
-
* Sets the claim fee.
|
|
364
|
-
*
|
|
365
|
-
* @public
|
|
366
|
-
* @async
|
|
367
|
-
* @param {bigint} claimFee
|
|
368
|
-
* @param {?WriteParams} [params]
|
|
369
|
-
* @returns {Promise<void>}
|
|
370
|
-
*/
|
|
371
|
-
setClaimFee(claimFee: bigint, params?: WriteParams<typeof boostCoreAbi, 'setClaimFee'>): Promise<void>;
|
|
372
|
-
/**
|
|
373
|
-
* Sets the claim fee.
|
|
374
|
-
*
|
|
375
|
-
* @public
|
|
376
|
-
* @async
|
|
377
|
-
* @param {bigint} claimFee
|
|
378
|
-
* @param {?WriteParams} [params]
|
|
379
|
-
* @returns {Promise<{ hash: `0x${string}`; result: void; }>}
|
|
380
|
-
*/
|
|
381
|
-
setClaimFeeRaw(claimFee: bigint, params?: WriteParams<typeof boostCoreAbi, 'setClaimFee'>): Promise<{
|
|
382
|
-
hash: `0x${string}`;
|
|
383
|
-
result: void;
|
|
384
|
-
}>;
|
|
385
971
|
/**
|
|
386
972
|
* Retrieves the claim information from a transaction receipt.
|
|
387
973
|
*
|