@boostxyz/sdk 7.0.0 → 7.2.0

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.
Files changed (28) hide show
  1. package/dist/Actions/EventAction.cjs +1 -1
  2. package/dist/Actions/EventAction.cjs.map +1 -1
  3. package/dist/Actions/EventAction.d.ts +46 -0
  4. package/dist/Actions/EventAction.d.ts.map +1 -1
  5. package/dist/Actions/EventAction.js +395 -345
  6. package/dist/Actions/EventAction.js.map +1 -1
  7. package/dist/BoostCore.cjs.map +1 -1
  8. package/dist/BoostCore.d.ts +2 -2
  9. package/dist/BoostCore.d.ts.map +1 -1
  10. package/dist/BoostCore.js.map +1 -1
  11. package/dist/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.cjs +1 -1
  12. package/dist/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.cjs.map +1 -1
  13. package/dist/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.d.ts.map +1 -1
  14. package/dist/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.js +79 -68
  15. package/dist/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.js.map +1 -1
  16. package/dist/Incentives/ERC20VariableCriteriaIncentiveV2.cjs +1 -1
  17. package/dist/Incentives/ERC20VariableCriteriaIncentiveV2.cjs.map +1 -1
  18. package/dist/Incentives/ERC20VariableCriteriaIncentiveV2.d.ts.map +1 -1
  19. package/dist/Incentives/ERC20VariableCriteriaIncentiveV2.js +84 -73
  20. package/dist/Incentives/ERC20VariableCriteriaIncentiveV2.js.map +1 -1
  21. package/dist/index.cjs +1 -1
  22. package/dist/index.js +179 -175
  23. package/package.json +1 -1
  24. package/src/Actions/EventAction.test.ts +90 -0
  25. package/src/Actions/EventAction.ts +119 -2
  26. package/src/BoostCore.ts +1 -1
  27. package/src/Incentives/ERC20PeggedVariableCriteriaIncentiveV2.ts +24 -5
  28. package/src/Incentives/ERC20VariableCriteriaIncentiveV2.ts +25 -5
@@ -1 +1 @@
1
- {"version":3,"file":"ERC20VariableCriteriaIncentiveV2.js","sources":["../../src/Incentives/ERC20VariableCriteriaIncentiveV2.ts"],"sourcesContent":["import {\n erc20VariableCriteriaIncentiveV2Abi,\n readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria,\n readErc20VariableCriteriaIncentiveV2GetMaxReward,\n} from '@boostxyz/evm';\nimport { bytecode } from '@boostxyz/evm/artifacts/contracts/incentives/ERC20VariableCriteriaIncentiveV2.sol/ERC20VariableCriteriaIncentiveV2.json';\nimport { getTransaction, getTransactionReceipt } from '@wagmi/core';\nimport {\n type AbiEvent,\n type AbiFunction,\n type Address,\n type Hex,\n decodeAbiParameters,\n decodeFunctionData,\n encodeAbiParameters,\n parseEther,\n parseEventLogs,\n zeroAddress,\n zeroHash,\n} from 'viem';\nimport { ERC20VariableCriteriaIncentiveV2 as ERC20VariableCriteriaIncentiveV2Bases } from '../../dist/deployments.json';\nimport { SignatureType, ValueType } from '../Actions/EventAction';\nimport type {\n DeployableOptions,\n GenericDeployableParams,\n} from '../Deployable/Deployable';\nimport {\n DecodedArgsError,\n IncentiveCriteriaNotFoundError,\n InvalidCriteriaTypeError,\n NoMatchingLogsError,\n} from '../errors';\nimport { CheatCodes, type ReadParams } from '../utils';\nimport { ERC20VariableIncentive } from './ERC20VariableIncentive';\n\nexport { erc20VariableCriteriaIncentiveV2Abi };\n\nexport interface ERC20VariableCriteriaIncentiveV2Payload {\n /**\n * The address of the incentivized asset.\n *\n * @type {Address}\n */\n asset: Address;\n /**\n * The amount of the asset to distribute as reward.\n *\n * @type {bigint}\n */\n reward: bigint;\n /**\n * The total spending limit of the asset that will be distributed.\n *\n * @type {bigint}\n */\n limit: bigint;\n /**\n * The total amount claimable in a single claim or maximum per-action reward.\n *\n * @type {bigint}\n * @optional\n */\n maxReward?: bigint;\n /**\n * The criteria for the incentive that determines how the reward is distributed.\n *\n * @type {IncentiveCriteria}\n */\n criteria: IncentiveCriteriaV2;\n}\n\nexport interface IncentiveCriteriaV2 {\n /**\n * The type of criteria used, either function signature or event signature.\n *\n * @type {SignatureType}\n */\n criteriaType: SignatureType;\n /**\n * The function or event signature used for criteria matching.\n *\n * @type {Hex}\n */\n signature: Hex;\n /**\n * The index of the field from where the scalar value is extracted.\n *\n * @type {number}\n */\n fieldIndex: number;\n /**\n * The address of the contract where the event/function is called/emitted.\n *\n * @type {Address}\n */\n targetContract: Address;\n /**\n * The type of value used for the scalar value (RAW or WAD).\n * - RAW: Raw integer value (e.g., NFT quantity)\n * - WAD: Value with 18 decimals (e.g., token amount)\n *\n * @type {ValueType}\n */\n valueType: ValueType;\n}\n\nexport interface ReadIncentiveCriteriaV2Params extends ReadParams {}\n\nexport interface GetIncentiveScalarV2Params {\n chainId: number;\n hash: Hex;\n knownSignatures: Record<Hex, AbiFunction | AbiEvent>;\n}\n\n/**\n * Extended ERC20 Variable Criteria Incentive class that fetches incentive criteria and scalar\n *\n * @export\n * @class ERC20VariableCriteriaIncentive\n * @typedef {ERC20VariableCriteriaIncentiveV2}\n * @extends {ERC20VariableIncentive<ERC20VariableCriteriaIncentiveV2Payload, typeof erc20VariableCriteriaIncentiveV2Abi>}\n */\nexport class ERC20VariableCriteriaIncentiveV2 extends ERC20VariableIncentive<\n ERC20VariableCriteriaIncentiveV2Payload,\n typeof erc20VariableCriteriaIncentiveV2Abi,\n Promise<bigint>\n> {\n //@ts-expect-error instantiated correctly\n public override readonly abi = erc20VariableCriteriaIncentiveV2Abi;\n /**\n * @inheritdoc\n *\n * @public\n * @static\n * @type {Record<number, Address>}\n */\n public static override bases: Record<number, Address> = {\n 31337: import.meta.env.VITE_ERC20_VARIABLE_CRITERIA_INCENTIVE_V2_BASE,\n ...(ERC20VariableCriteriaIncentiveV2Bases as Record<number, Address>),\n };\n\n /**\n *Functions from the ERC20VariableIncentive contract\n */\n\n /**\n * Fetches the IncentiveCriteria struct from the contract\n *\n * @param {?ReadParams} [params]\n * @returns {Promise<IncentiveCriteria>} Incentive criteria structure\n * @throws {IncentiveCriteriaNotFoundError}\n */\n public async getIncentiveCriteria(\n params?: ReadParams,\n ): Promise<IncentiveCriteriaV2> {\n try {\n const criteria =\n await readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria(\n this._config,\n {\n ...params,\n address: this.assertValidAddress(),\n },\n );\n\n return criteria;\n } catch (e) {\n throw new IncentiveCriteriaNotFoundError(e as Error);\n }\n }\n\n /**\n * Decodes claim data for the ERC20VariableCriteriaIncentiveV2, returning the claim amount.\n * Useful when deriving amount claimed from logs.\n *\n * @public\n * @param {Hex} claimData\n * @returns {Promise<bigint>} Returns the reward amount from a claim data payload\n */\n public override async decodeClaimData(claimData: Hex) {\n const boostClaimData = decodeAbiParameters(\n [\n {\n type: 'tuple',\n name: 'BoostClaimData',\n components: [\n { type: 'bytes', name: 'validatorData' },\n { type: 'bytes', name: 'incentiveData' },\n ],\n },\n ],\n claimData,\n );\n const signedAmount = decodeAbiParameters(\n [{ type: 'uint256' }],\n boostClaimData[0].incentiveData,\n )[0];\n let claimAmount = signedAmount;\n const [reward, maxReward] = await Promise.all([\n this.reward(),\n this.getMaxReward(),\n ]);\n\n if (reward === 0n) {\n return claimAmount;\n } else {\n claimAmount = (reward * signedAmount) / parseEther('1');\n }\n\n if (maxReward !== 0n && claimAmount > maxReward) {\n claimAmount = maxReward;\n }\n\n return claimAmount;\n }\n\n /**\n * Fetches the IncentiveCriteria struct from the contract\n *\n * @param {?ReadParams} [params]\n * @returns {Promise<IncentiveCriteria>} Incentive criteria structure\n * @throws {IncentiveCriteriaNotFoundError}\n */\n public async getMaxReward(params?: ReadParams): Promise<bigint> {\n const maxReward = await readErc20VariableCriteriaIncentiveV2GetMaxReward(\n this._config,\n {\n ...params,\n address: this.assertValidAddress(),\n },\n );\n\n return maxReward;\n }\n\n /**\n * Fetches the incentive scalar from a transaction hash\n *\n * @param {GetIncentiveScalarParams} params\n * @param {?ReadParams} [params]\n * @returns {Promise<bigint>}\n * @throws {InvalidCriteriaTypeError | NoMatchingLogsError | DecodedArgsError}\n */\n public async getIncentiveScalar(\n { chainId, hash, knownSignatures }: GetIncentiveScalarV2Params,\n params?: ReadParams,\n ): Promise<bigint> {\n const criteria = await this.getIncentiveCriteria(params);\n if (criteria.criteriaType === SignatureType.EVENT) {\n const transactionReceipt = await getTransactionReceipt(this._config, {\n chainId,\n hash,\n });\n if (criteria.fieldIndex === CheatCodes.GAS_REBATE_INCENTIVE) {\n const totalCost =\n transactionReceipt.gasUsed * transactionReceipt.effectiveGasPrice + // Normal gas cost\n (transactionReceipt.blobGasUsed ?? 0n) *\n (transactionReceipt.blobGasPrice ?? 0n); // Blob gas cost - account for potential undefined values\n return totalCost;\n }\n const logs = transactionReceipt.logs;\n\n if (logs.length === 0) {\n throw new NoMatchingLogsError(\n `No logs found for event signature ${criteria.signature}`,\n );\n }\n\n // Decode the event log\n try {\n // Decode function data\n const eventAbi = knownSignatures[criteria.signature] as AbiEvent;\n const decodedEvents = parseEventLogs({\n abi: [eventAbi],\n logs,\n });\n if (decodedEvents == undefined || decodedEvents.length === 0) {\n throw new NoMatchingLogsError(\n `No logs found for event signature ${criteria.signature}`,\n );\n }\n const scalarValue = (decodedEvents[0]?.args as string[])[\n criteria.fieldIndex\n ];\n\n if (scalarValue === undefined) {\n throw new DecodedArgsError(\n `Decoded argument at index ${criteria.fieldIndex} is undefined`,\n );\n }\n return BigInt(scalarValue);\n } catch (e) {\n throw new DecodedArgsError(\n `Failed to decode event log for signature ${criteria.signature}: ${(e as Error).message}`,\n );\n }\n } else if (criteria.criteriaType === SignatureType.FUNC) {\n // Fetch the transaction data\n const transaction = await getTransaction(this._config, {\n chainId,\n hash,\n });\n try {\n // Decode function data\n const func = knownSignatures[criteria.signature] as AbiFunction;\n const decodedFunction = decodeFunctionData({\n abi: [func],\n data: transaction.input,\n });\n const scalarValue = decodedFunction.args[criteria.fieldIndex] as string;\n if (scalarValue === undefined || scalarValue === null) {\n throw new DecodedArgsError(\n `Decoded argument at index ${criteria.fieldIndex} is undefined`,\n );\n }\n return BigInt(scalarValue);\n } catch (e) {\n throw new DecodedArgsError(\n `Failed to decode function data for signature ${criteria.signature}: ${(e as Error).message}`,\n );\n }\n } else {\n throw new InvalidCriteriaTypeError(\n `Invalid criteria type ${criteria.criteriaType}`,\n );\n }\n }\n\n /**\n * @inheritdoc\n *\n * @public\n * @param {?ERC20VariableCriteriaIncentiveV2Payload} [_payload]\n * @param {?DeployableOptions} [_options]\n * @returns {GenericDeployableParams}\n */\n public override buildParameters(\n _payload?: ERC20VariableCriteriaIncentiveV2Payload,\n _options?: DeployableOptions,\n ): GenericDeployableParams {\n const [payload, options] = this.validateDeploymentConfig(\n _payload,\n _options,\n );\n return {\n abi: erc20VariableCriteriaIncentiveV2Abi,\n bytecode: bytecode as Hex,\n args: [prepareERC20VariableCriteriaIncentiveV2Payload(payload)],\n ...this.optionallyAttachAccount(options.account),\n };\n }\n}\n\n/**\n * Creates an IncentiveCriteria object representing a gas rebate incentive.\n * This object defines a variable incentive criteria where the criteria will be the gas spent.\n *\n * The criteria uses a signatureType of EVENT, with a special `fieldIndex` of 255 (using CheatCodes enum), which indicates\n * that the entire gas cost of the transaction will be used as the scalar value. If you don't want to\n * rebate the entire gas cost, you can use a reward value on the incentive..\n *\n * - `criteriaType`: EVENT, indicating it's based on event logs.\n * - `signature`: A zeroed signature (0x0000...0000), matching any event.\n * - `fieldIndex`: 255, indicating the use of transaction gas cost using CheatCodes enum.\n * - `targetContract`: A zeroed address (0x0000...0000), applicable to any contract.\n *\n * @returns {IncentiveCriteria} Returns an IncentiveCriteria object for a gas rebate.\n *\n * @example\n * const incentive = gasRebateIncentiveCriteria();\n * const actionPayload = {\n * criteria: incentive,\n * asset: \"0xAssetAddress\",\n * reward: 0, // Set to zero to rebate the entire gas cost\n * limit: BigInt(1000) // This is the total spend limit for the incentive\n * };\n * deployIncentive(actionPayload);\n */\nexport function gasRebateIncentiveCriteriaV2(): IncentiveCriteriaV2 {\n return {\n criteriaType: SignatureType.EVENT,\n signature: zeroHash,\n fieldIndex: CheatCodes.GAS_REBATE_INCENTIVE,\n targetContract: zeroAddress,\n valueType: ValueType.WAD,\n };\n}\n\n/**\n *\n *\n * @param {InitPayloadExtended} param0\n * @param {Address} param0.asset - The address of the ERC20 asset to incentivize.\n * @param {bigint} param0.reward - The reward amount to distribute per action.\n * @param {bigint} param0.limit - The total limit of the asset distribution.\n * @param {bigint} param0.maxReward - The maximum value claimable from a single completion.\n * @param {IncentiveCriteria} param0.criteria - The incentive criteria for reward distribution.\n * @returns {Hex}\n */\nexport function prepareERC20VariableCriteriaIncentiveV2Payload({\n asset,\n reward,\n limit,\n maxReward = 0n,\n criteria,\n}: ERC20VariableCriteriaIncentiveV2Payload) {\n return encodeAbiParameters(\n [\n {\n type: 'tuple',\n name: 'initPayloadExtended',\n components: [\n { type: 'address', name: 'asset' },\n { type: 'uint256', name: 'reward' },\n { type: 'uint256', name: 'limit' },\n { type: 'uint256', name: 'maxReward' },\n {\n type: 'tuple',\n name: 'criteria',\n components: [\n { type: 'uint8', name: 'criteriaType' },\n { type: 'bytes32', name: 'signature' },\n { type: 'uint8', name: 'fieldIndex' },\n { type: 'address', name: 'targetContract' },\n { type: 'uint8', name: 'valueType' },\n ],\n },\n ],\n },\n ],\n [\n {\n asset: asset,\n reward: reward,\n limit: limit,\n maxReward: maxReward,\n criteria: {\n criteriaType: criteria.criteriaType,\n signature: criteria.signature,\n fieldIndex: criteria.fieldIndex,\n targetContract: criteria.targetContract,\n valueType: criteria.valueType,\n },\n },\n ],\n );\n}\n"],"names":["_ERC20VariableCriteriaIncentiveV2","ERC20VariableIncentive","erc20VariableCriteriaIncentiveV2Abi","params","readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria","e","IncentiveCriteriaNotFoundError","claimData","boostClaimData","decodeAbiParameters","signedAmount","claimAmount","reward","maxReward","parseEther","readErc20VariableCriteriaIncentiveV2GetMaxReward","chainId","hash","knownSignatures","criteria","SignatureType","transactionReceipt","getTransactionReceipt","CheatCodes","logs","NoMatchingLogsError","eventAbi","decodedEvents","parseEventLogs","scalarValue","_a","DecodedArgsError","transaction","getTransaction","func","decodeFunctionData","InvalidCriteriaTypeError","_payload","_options","payload","options","bytecode","prepareERC20VariableCriteriaIncentiveV2Payload","ERC20VariableCriteriaIncentiveV2Bases","ERC20VariableCriteriaIncentiveV2","gasRebateIncentiveCriteriaV2","zeroHash","zeroAddress","ValueType","asset","limit","encodeAbiParameters"],"mappings":";;;;;;;;wmiBA0HaA,IAAN,MAAMA,UAAyCC,EAIpD;AAAA,EAJK,cAAA;AAAA,UAAA,GAAA,SAAA,GAML,KAAyB,MAAMC;AAAAA,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAwB/B,MAAa,qBACXC,GAC8B;AAC1B,QAAA;AAUK,aARL,MAAMC;AAAAA,QACJ,KAAK;AAAA,QACL;AAAA,UACE,GAAGD;AAAA,UACH,SAAS,KAAK,mBAAmB;AAAA,QACnC;AAAA,MAAA;AAAA,aAIGE,GAAG;AACJ,YAAA,IAAIC,EAA+BD,CAAU;AAAA,IACrD;AAAA,EACF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAUA,MAAsB,gBAAgBE,GAAgB;AACpD,UAAMC,IAAiBC;AAAA,MACrB;AAAA,QACE;AAAA,UACE,MAAM;AAAA,UACN,MAAM;AAAA,UACN,YAAY;AAAA,YACV,EAAE,MAAM,SAAS,MAAM,gBAAgB;AAAA,YACvC,EAAE,MAAM,SAAS,MAAM,gBAAgB;AAAA,UACzC;AAAA,QACF;AAAA,MACF;AAAA,MACAF;AAAA,IAAA,GAEIG,IAAeD;AAAA,MACnB,CAAC,EAAE,MAAM,WAAW;AAAA,MACpBD,EAAe,CAAC,EAAE;AAAA,MAClB,CAAC;AACH,QAAIG,IAAcD;AAClB,UAAM,CAACE,GAAQC,CAAS,IAAI,MAAM,QAAQ,IAAI;AAAA,MAC5C,KAAK,OAAO;AAAA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A,QACtB;AAAA,MACF;AAAA,IACF;AAAA,EAAA;AAEJ;"}
1
+ {"version":3,"file":"ERC20VariableCriteriaIncentiveV2.js","sources":["../../src/Incentives/ERC20VariableCriteriaIncentiveV2.ts"],"sourcesContent":["import {\n erc20VariableCriteriaIncentiveV2Abi,\n readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria,\n readErc20VariableCriteriaIncentiveV2GetMaxReward,\n} from '@boostxyz/evm';\nimport { bytecode } from '@boostxyz/evm/artifacts/contracts/incentives/ERC20VariableCriteriaIncentiveV2.sol/ERC20VariableCriteriaIncentiveV2.json';\nimport { getTransaction, getTransactionReceipt } from '@wagmi/core';\nimport {\n type AbiEvent,\n type AbiFunction,\n type Address,\n type Hex,\n decodeAbiParameters,\n decodeFunctionData,\n encodeAbiParameters,\n parseEther,\n parseEventLogs,\n zeroAddress,\n zeroHash,\n} from 'viem';\nimport { ERC20VariableCriteriaIncentiveV2 as ERC20VariableCriteriaIncentiveV2Bases } from '../../dist/deployments.json';\nimport {\n SignatureType,\n ValueType,\n getScalarValueFromTuple,\n isCriteriaFieldIndexTuple,\n} from '../Actions/EventAction';\nimport type {\n DeployableOptions,\n GenericDeployableParams,\n} from '../Deployable/Deployable';\nimport {\n DecodedArgsError,\n IncentiveCriteriaNotFoundError,\n InvalidCriteriaTypeError,\n NoMatchingLogsError,\n} from '../errors';\nimport { CheatCodes, type ReadParams } from '../utils';\nimport { ERC20VariableIncentive } from './ERC20VariableIncentive';\n\nexport { erc20VariableCriteriaIncentiveV2Abi };\n\nexport interface ERC20VariableCriteriaIncentiveV2Payload {\n /**\n * The address of the incentivized asset.\n *\n * @type {Address}\n */\n asset: Address;\n /**\n * The amount of the asset to distribute as reward.\n *\n * @type {bigint}\n */\n reward: bigint;\n /**\n * The total spending limit of the asset that will be distributed.\n *\n * @type {bigint}\n */\n limit: bigint;\n /**\n * The total amount claimable in a single claim or maximum per-action reward.\n *\n * @type {bigint}\n * @optional\n */\n maxReward?: bigint;\n /**\n * The criteria for the incentive that determines how the reward is distributed.\n *\n * @type {IncentiveCriteria}\n */\n criteria: IncentiveCriteriaV2;\n}\n\nexport interface IncentiveCriteriaV2 {\n /**\n * The type of criteria used, either function signature or event signature.\n *\n * @type {SignatureType}\n */\n criteriaType: SignatureType;\n /**\n * The function or event signature used for criteria matching.\n *\n * @type {Hex}\n */\n signature: Hex;\n /**\n * The index of the field from where the scalar value is extracted.\n *\n * @type {number}\n */\n fieldIndex: number;\n /**\n * The address of the contract where the event/function is called/emitted.\n *\n * @type {Address}\n */\n targetContract: Address;\n /**\n * The type of value used for the scalar value (RAW or WAD).\n * - RAW: Raw integer value (e.g., NFT quantity)\n * - WAD: Value with 18 decimals (e.g., token amount)\n *\n * @type {ValueType}\n */\n valueType: ValueType;\n}\n\nexport interface ReadIncentiveCriteriaV2Params extends ReadParams {}\n\nexport interface GetIncentiveScalarV2Params {\n chainId: number;\n hash: Hex;\n knownSignatures: Record<Hex, AbiFunction | AbiEvent>;\n}\n\n/**\n * Extended ERC20 Variable Criteria Incentive class that fetches incentive criteria and scalar\n *\n * @export\n * @class ERC20VariableCriteriaIncentive\n * @typedef {ERC20VariableCriteriaIncentiveV2}\n * @extends {ERC20VariableIncentive<ERC20VariableCriteriaIncentiveV2Payload, typeof erc20VariableCriteriaIncentiveV2Abi>}\n */\nexport class ERC20VariableCriteriaIncentiveV2 extends ERC20VariableIncentive<\n ERC20VariableCriteriaIncentiveV2Payload,\n typeof erc20VariableCriteriaIncentiveV2Abi,\n Promise<bigint>\n> {\n //@ts-expect-error instantiated correctly\n public override readonly abi = erc20VariableCriteriaIncentiveV2Abi;\n /**\n * @inheritdoc\n *\n * @public\n * @static\n * @type {Record<number, Address>}\n */\n public static override bases: Record<number, Address> = {\n 31337: import.meta.env.VITE_ERC20_VARIABLE_CRITERIA_INCENTIVE_V2_BASE,\n ...(ERC20VariableCriteriaIncentiveV2Bases as Record<number, Address>),\n };\n\n /**\n *Functions from the ERC20VariableIncentive contract\n */\n\n /**\n * Fetches the IncentiveCriteria struct from the contract\n *\n * @param {?ReadParams} [params]\n * @returns {Promise<IncentiveCriteria>} Incentive criteria structure\n * @throws {IncentiveCriteriaNotFoundError}\n */\n public async getIncentiveCriteria(\n params?: ReadParams,\n ): Promise<IncentiveCriteriaV2> {\n try {\n const criteria =\n await readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria(\n this._config,\n {\n ...params,\n address: this.assertValidAddress(),\n },\n );\n\n return criteria;\n } catch (e) {\n throw new IncentiveCriteriaNotFoundError(e as Error);\n }\n }\n\n /**\n * Decodes claim data for the ERC20VariableCriteriaIncentiveV2, returning the claim amount.\n * Useful when deriving amount claimed from logs.\n *\n * @public\n * @param {Hex} claimData\n * @returns {Promise<bigint>} Returns the reward amount from a claim data payload\n */\n public override async decodeClaimData(claimData: Hex) {\n const boostClaimData = decodeAbiParameters(\n [\n {\n type: 'tuple',\n name: 'BoostClaimData',\n components: [\n { type: 'bytes', name: 'validatorData' },\n { type: 'bytes', name: 'incentiveData' },\n ],\n },\n ],\n claimData,\n );\n const signedAmount = decodeAbiParameters(\n [{ type: 'uint256' }],\n boostClaimData[0].incentiveData,\n )[0];\n let claimAmount = signedAmount;\n const [reward, maxReward] = await Promise.all([\n this.reward(),\n this.getMaxReward(),\n ]);\n\n if (reward === 0n) {\n return claimAmount;\n } else {\n claimAmount = (reward * signedAmount) / parseEther('1');\n }\n\n if (maxReward !== 0n && claimAmount > maxReward) {\n claimAmount = maxReward;\n }\n\n return claimAmount;\n }\n\n /**\n * Fetches the IncentiveCriteria struct from the contract\n *\n * @param {?ReadParams} [params]\n * @returns {Promise<IncentiveCriteria>} Incentive criteria structure\n * @throws {IncentiveCriteriaNotFoundError}\n */\n public async getMaxReward(params?: ReadParams): Promise<bigint> {\n const maxReward = await readErc20VariableCriteriaIncentiveV2GetMaxReward(\n this._config,\n {\n ...params,\n address: this.assertValidAddress(),\n },\n );\n\n return maxReward;\n }\n\n /**\n * Fetches the incentive scalar from a transaction hash\n *\n * @param {GetIncentiveScalarParams} params\n * @param {?ReadParams} [params]\n * @returns {Promise<bigint>}\n * @throws {InvalidCriteriaTypeError | NoMatchingLogsError | DecodedArgsError}\n */\n public async getIncentiveScalar(\n { chainId, hash, knownSignatures }: GetIncentiveScalarV2Params,\n params?: ReadParams,\n ): Promise<bigint> {\n const criteria = await this.getIncentiveCriteria(params);\n if (criteria.criteriaType === SignatureType.EVENT) {\n const transactionReceipt = await getTransactionReceipt(this._config, {\n chainId,\n hash,\n });\n if (criteria.fieldIndex === CheatCodes.GAS_REBATE_INCENTIVE) {\n const totalCost =\n transactionReceipt.gasUsed * transactionReceipt.effectiveGasPrice + // Normal gas cost\n (transactionReceipt.blobGasUsed ?? 0n) *\n (transactionReceipt.blobGasPrice ?? 0n); // Blob gas cost - account for potential undefined values\n return totalCost;\n }\n const logs = transactionReceipt.logs;\n\n if (logs.length === 0) {\n throw new NoMatchingLogsError(\n `No logs found for event signature ${criteria.signature}`,\n );\n }\n\n // Decode the event log\n try {\n const eventAbi = knownSignatures[criteria.signature] as AbiEvent;\n const decodedEvents = parseEventLogs({\n abi: [eventAbi],\n logs,\n });\n if (decodedEvents == undefined || decodedEvents.length === 0) {\n throw new NoMatchingLogsError(\n `No logs found for event signature ${criteria.signature}`,\n );\n }\n\n if (isCriteriaFieldIndexTuple(criteria.fieldIndex)) {\n return getScalarValueFromTuple(\n decodedEvents[0]?.args as unknown[],\n criteria.fieldIndex,\n );\n }\n\n const scalarValue =\n decodedEvents[0] && decodedEvents[0].args\n ? (decodedEvents[0].args as string[])[criteria.fieldIndex]\n : undefined;\n if (scalarValue === undefined) {\n throw new DecodedArgsError(\n `Decoded argument at index ${criteria.fieldIndex} is undefined`,\n );\n }\n return BigInt(scalarValue);\n } catch (e) {\n throw new DecodedArgsError(\n `Failed to decode event log for signature ${criteria.signature}: ${(e as Error).message}`,\n );\n }\n } else if (criteria.criteriaType === SignatureType.FUNC) {\n // Fetch the transaction data\n const transaction = await getTransaction(this._config, {\n chainId,\n hash,\n });\n try {\n // Decode function data\n const func = knownSignatures[criteria.signature] as AbiFunction;\n const decodedFunction = decodeFunctionData({\n abi: [func],\n data: transaction.input,\n });\n\n if (isCriteriaFieldIndexTuple(criteria.fieldIndex)) {\n return getScalarValueFromTuple(\n decodedFunction.args as unknown[],\n criteria.fieldIndex,\n );\n }\n\n const scalarValue = decodedFunction.args[criteria.fieldIndex] as string;\n if (scalarValue === undefined || scalarValue === null) {\n throw new DecodedArgsError(\n `Decoded argument at index ${criteria.fieldIndex} is undefined`,\n );\n }\n return BigInt(scalarValue);\n } catch (e) {\n throw new DecodedArgsError(\n `Failed to decode function data for signature ${criteria.signature}: ${(e as Error).message}`,\n );\n }\n } else {\n throw new InvalidCriteriaTypeError(\n `Invalid criteria type ${criteria.criteriaType}`,\n );\n }\n }\n\n /**\n * @inheritdoc\n *\n * @public\n * @param {?ERC20VariableCriteriaIncentiveV2Payload} [_payload]\n * @param {?DeployableOptions} [_options]\n * @returns {GenericDeployableParams}\n */\n public override buildParameters(\n _payload?: ERC20VariableCriteriaIncentiveV2Payload,\n _options?: DeployableOptions,\n ): GenericDeployableParams {\n const [payload, options] = this.validateDeploymentConfig(\n _payload,\n _options,\n );\n return {\n abi: erc20VariableCriteriaIncentiveV2Abi,\n bytecode: bytecode as Hex,\n args: [prepareERC20VariableCriteriaIncentiveV2Payload(payload)],\n ...this.optionallyAttachAccount(options.account),\n };\n }\n}\n\n/**\n * Creates an IncentiveCriteria object representing a gas rebate incentive.\n * This object defines a variable incentive criteria where the criteria will be the gas spent.\n *\n * The criteria uses a signatureType of EVENT, with a special `fieldIndex` of 255 (using CheatCodes enum), which indicates\n * that the entire gas cost of the transaction will be used as the scalar value. If you don't want to\n * rebate the entire gas cost, you can use a reward value on the incentive..\n *\n * - `criteriaType`: EVENT, indicating it's based on event logs.\n * - `signature`: A zeroed signature (0x0000...0000), matching any event.\n * - `fieldIndex`: 255, indicating the use of transaction gas cost using CheatCodes enum.\n * - `targetContract`: A zeroed address (0x0000...0000), applicable to any contract.\n *\n * @returns {IncentiveCriteria} Returns an IncentiveCriteria object for a gas rebate.\n *\n * @example\n * const incentive = gasRebateIncentiveCriteria();\n * const actionPayload = {\n * criteria: incentive,\n * asset: \"0xAssetAddress\",\n * reward: 0, // Set to zero to rebate the entire gas cost\n * limit: BigInt(1000) // This is the total spend limit for the incentive\n * };\n * deployIncentive(actionPayload);\n */\nexport function gasRebateIncentiveCriteriaV2(): IncentiveCriteriaV2 {\n return {\n criteriaType: SignatureType.EVENT,\n signature: zeroHash,\n fieldIndex: CheatCodes.GAS_REBATE_INCENTIVE,\n targetContract: zeroAddress,\n valueType: ValueType.WAD,\n };\n}\n\n/**\n *\n *\n * @param {InitPayloadExtended} param0\n * @param {Address} param0.asset - The address of the ERC20 asset to incentivize.\n * @param {bigint} param0.reward - The reward amount to distribute per action.\n * @param {bigint} param0.limit - The total limit of the asset distribution.\n * @param {bigint} param0.maxReward - The maximum value claimable from a single completion.\n * @param {IncentiveCriteria} param0.criteria - The incentive criteria for reward distribution.\n * @returns {Hex}\n */\nexport function prepareERC20VariableCriteriaIncentiveV2Payload({\n asset,\n reward,\n limit,\n maxReward = 0n,\n criteria,\n}: ERC20VariableCriteriaIncentiveV2Payload) {\n return encodeAbiParameters(\n [\n {\n type: 'tuple',\n name: 'initPayloadExtended',\n components: [\n { type: 'address', name: 'asset' },\n { type: 'uint256', name: 'reward' },\n { type: 'uint256', name: 'limit' },\n { type: 'uint256', name: 'maxReward' },\n {\n type: 'tuple',\n name: 'criteria',\n components: [\n { type: 'uint8', name: 'criteriaType' },\n { type: 'bytes32', name: 'signature' },\n { type: 'uint8', name: 'fieldIndex' },\n { type: 'address', name: 'targetContract' },\n { type: 'uint8', name: 'valueType' },\n ],\n },\n ],\n },\n ],\n [\n {\n asset: asset,\n reward: reward,\n limit: limit,\n maxReward: maxReward,\n criteria: {\n criteriaType: criteria.criteriaType,\n signature: criteria.signature,\n fieldIndex: criteria.fieldIndex,\n targetContract: criteria.targetContract,\n valueType: criteria.valueType,\n },\n },\n ],\n );\n}\n"],"names":["_ERC20VariableCriteriaIncentiveV2","ERC20VariableIncentive","erc20VariableCriteriaIncentiveV2Abi","params","readErc20VariableCriteriaIncentiveV2GetIncentiveCriteria","e","IncentiveCriteriaNotFoundError","claimData","boostClaimData","decodeAbiParameters","signedAmount","claimAmount","reward","maxReward","parseEther","readErc20VariableCriteriaIncentiveV2GetMaxReward","chainId","hash","knownSignatures","criteria","SignatureType","transactionReceipt","getTransactionReceipt","CheatCodes","logs","NoMatchingLogsError","eventAbi","decodedEvents","parseEventLogs","isCriteriaFieldIndexTuple","getScalarValueFromTuple","_a","scalarValue","DecodedArgsError","transaction","getTransaction","func","decodedFunction","decodeFunctionData","InvalidCriteriaTypeError","_payload","_options","payload","options","bytecode","prepareERC20VariableCriteriaIncentiveV2Payload","ERC20VariableCriteriaIncentiveV2Bases","ERC20VariableCriteriaIncentiveV2","gasRebateIncentiveCriteriaV2","zeroHash","zeroAddress","ValueType","asset","limit","encodeAbiParameters"],"mappings":";;;;;;;;wmiBA+HaA,IAAN,MAAMA,UAAyCC,EAIpD;AAAA,EAJK,cAAA;AAAA,UAAA,GAAA,SAAA,GAML,KAAyB,MAAMC;AAAAA,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAwB/B,MAAa,qBACXC,GAC8B;AAC1B,QAAA;AAUK,aARL,MAAMC;AAAAA,QACJ,KAAK;AAAA,QACL;AAAA,UACE,GAAGD;AAAA,UACH,SAAS,KAAK,mBAAmB;AAAA,QACnC;AAAA,MAAA;AAAA,aAIGE,GAAG;AACJ,YAAA,IAAIC,EAA+BD,CAAU;AAAA,IACrD;AAAA,EACF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAUA,MAAsB,gBAAgBE,GAAgB;AACpD,UAAMC,IAAiBC;AAAA,MACrB;AAAA,QACE;AAAA,UACE,MAAM;AAAA,UACN,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S;AAAA,UAClC,EAAE,MAAM,WAAW,MAAM,QAAQ;AAAA,UACjC,EAAE,MAAM,WAAW,MAAM,YAAY;AAAA,UACrC;AAAA,YACE,MAAM;AAAA,YACN,MAAM;AAAA,YACN,YAAY;AAAA,cACV,EAAE,MAAM,SAAS,MAAM,eAAe;AAAA,cACtC,EAAE,MAAM,WAAW,MAAM,YAAY;AAAA,cACrC,EAAE,MAAM,SAAS,MAAM,aAAa;AAAA,cACpC,EAAE,MAAM,WAAW,MAAM,iBAAiB;AAAA,cAC1C,EAAE,MAAM,SAAS,MAAM,YAAY;AAAA,YACrC;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAA,IACF;AAAA,IACA;AAAA,MACE;AAAA,QACE,OAAAF;AAAA,QACA,QAAAxC;AAAA,QACA,OAAAyC;AAAA,QACA,WAAAxC;AAAA,QACA,UAAU;AAAA,UACR,cAAcM,EAAS;AAAA,UACvB,WAAWA,EAAS;AAAA,UACpB,YAAYA,EAAS;AAAA,UACrB,gBAAgBA,EAAS;AAAA,UACzB,WAAWA,EAAS;AAAA,QACtB;AAAA,MACF;AAAA,IACF;AAAA,EAAA;AAEJ;"}
package/dist/index.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("./BoostRegistry.cjs"),d=require("./BoostCore.cjs"),A=require("./Boost.cjs"),I=require("./Actions/Action.cjs"),a=require("./Actions/EventAction.cjs"),E=require("./AllowLists/AllowList.cjs"),C=require("./AllowLists/SimpleAllowList.cjs"),v=require("./SimpleDenyList-B2YDJ_gk.cjs"),t=require("./Budget-uGKa2qzz.cjs"),n=require("./Budgets/ManagedBudget.cjs"),F=require("./Deployable/Deployable.cjs"),L=require("./Deployable/Contract.cjs"),f=require("./Deployable/DeployableTarget.cjs"),P=require("./Deployable/DeployableTargetWithRBAC.cjs"),b=require("./Incentives/AllowListIncentive.cjs"),R=require("./Incentives/CGDAIncentive.cjs"),S=require("./Incentives/ERC20Incentive.cjs"),l=require("./Incentive-Dufx0ZjH.cjs"),V=require("./Incentives/ERC20VariableIncentive.cjs"),y=require("./Incentives/ERC20VariableCriteriaIncentive.cjs"),m=require("./Incentives/ERC20PeggedVariableCriteriaIncentive.cjs"),u=require("./Incentives/ERC20VariableCriteriaIncentiveV2.cjs"),B=require("./Incentives/ERC20PeggedVariableCriteriaIncentiveV2.cjs"),T=require("./Incentives/PointsIncentive.cjs"),s=require("./Validators/SignerValidator.cjs"),p=require("./Validators/LimitedSignerValidator.cjs"),c=require("./Validators/Validator.cjs"),e=require("./errors.cjs"),i=require("./utils.cjs"),D=require("./claiming.cjs"),o=require("./transfers.cjs"),h=require("./Auth/PassthroughAuth.cjs"),r=require("./generated-C_JEoLDO.cjs");exports.BOOST_REGISTRY_ADDRESS=g.BOOST_REGISTRY_ADDRESS;exports.BOOST_REGISTRY_ADDRESSES=g.BOOST_REGISTRY_ADDRESSES;exports.BoostRegistry=g.BoostRegistry;exports.BOOST_CORE_ADDRESS=d.BOOST_CORE_ADDRESS;exports.BOOST_CORE_ADDRESSES=d.BOOST_CORE_ADDRESSES;exports.BoostCore=d.BoostCore;exports.FEE_DENOMINATOR=d.FEE_DENOMINATOR;exports.Boost=A.Boost;exports.prepareBoostPayload=A.prepareBoostPayload;exports.ActionByComponentInterface=I.ActionByComponentInterface;exports.actionFromAddress=I.actionFromAddress;exports.EventAction=a.EventAction;exports.FilterType=a.FilterType;exports.PrimitiveType=a.PrimitiveType;exports.SignatureType=a.SignatureType;exports.ValueType=a.ValueType;exports.anyActionParameter=a.anyActionParameter;exports.decodeAndReorderLogArgs=a.decodeAndReorderLogArgs;exports.detectSignatureType=a.detectSignatureType;exports.isEventActionPayloadSimple=a.isEventActionPayloadSimple;exports.packFieldIndexes=a.packFieldIndexes;exports.prepareEventActionPayload=a.prepareEventActionPayload;exports.transactionSenderClaimant=a.transactionSenderClaimant;exports.unpackFieldIndexes=a.unpackFieldIndexes;exports.AllowListByComponentInterface=E.AllowListByComponentInterface;exports.OpenAllowList=E.OpenAllowList;exports.allowListFromAddress=E.allowListFromAddress;exports.LIST_MANAGER_ROLE=C.LIST_MANAGER_ROLE;exports.SimpleAllowList=C.SimpleAllowList;exports.prepareSimpleAllowListPayload=C.prepareSimpleAllowListPayload;exports.SimpleDenyList=v.SimpleDenyList;exports.prepareSimpleDenyListPayload=v.prepareSimpleDenyListPayload;exports.BudgetByComponentInterface=t.BudgetByComponentInterface;exports.ManagedBudgetWithFees=t.ManagedBudgetWithFees;exports.ManagedBudgetWithFeesV2=t.ManagedBudgetWithFeesV2;exports.TransparentBudget=t.TransparentBudget;exports.budgetFromAddress=t.budgetFromAddress;exports.prepareManagedBudgetWithFeesPayload=t.prepareManagedBudgetWithFeesPayload;exports.prepareManagedBudgetWithFeesV2Payload=t.prepareManagedBudgetWithFeesV2Payload;exports.ManagedBudget=n.ManagedBudget;exports.ManagedBudgetRoles=n.ManagedBudgetRoles;exports.isERC1155TransferPayload=n.isERC1155TransferPayload;exports.isFungibleTransfer=n.isFungibleTransfer;exports.prepareManagedBudgetPayload=n.prepareManagedBudgetPayload;exports.prepareTransfer=n.prepareTransfer;exports.Deployable=F.Deployable;exports.Contract=L.Contract;exports.DeployableTarget=f.DeployableTarget;exports.DeployableTargetWithRBAC=P.DeployableTargetWithRBAC;exports.Roles=P.Roles;exports.AllowListIncentive=b.AllowListIncentive;exports.prepareAllowListIncentivePayload=b.prepareAllowListIncentivePayload;exports.CGDAIncentive=R.CGDAIncentive;exports.prepareCGDAIncentivePayload=R.prepareCGDAIncentivePayload;exports.ERC20Incentive=S.ERC20Incentive;exports.prepareERC20IncentivePayload=S.prepareERC20IncentivePayload;exports.ERC20PeggedIncentive=l.ERC20PeggedIncentive;exports.IncentiveByComponentInterface=l.IncentiveByComponentInterface;exports.incentiveFromAddress=l.incentiveFromAddress;exports.prepareERC20PeggedIncentivePayload=l.prepareERC20PeggedIncentivePayload;exports.ERC20VariableIncentive=V.ERC20VariableIncentive;exports.prepareERC20VariableIncentivePayload=V.prepareERC20VariableIncentivePayload;exports.ERC20VariableCriteriaIncentive=y.ERC20VariableCriteriaIncentive;exports.gasRebateIncentiveCriteria=y.gasRebateIncentiveCriteria;exports.prepareERC20VariableCriteriaIncentivePayload=y.prepareERC20VariableCriteriaIncentivePayload;exports.ERC20PeggedVariableCriteriaIncentive=m.ERC20PeggedVariableCriteriaIncentive;exports.prepareERC20PeggedVariableCriteriaIncentivePayload=m.prepareERC20PeggedVariableCriteriaIncentivePayload;exports.ERC20VariableCriteriaIncentiveV2=u.ERC20VariableCriteriaIncentiveV2;exports.gasRebateIncentiveCriteriaV2=u.gasRebateIncentiveCriteriaV2;exports.prepareERC20VariableCriteriaIncentiveV2Payload=u.prepareERC20VariableCriteriaIncentiveV2Payload;exports.ERC20PeggedVariableCriteriaIncentiveV2=B.ERC20PeggedVariableCriteriaIncentiveV2;exports.prepareERC20PeggedVariableCriteriaIncentiveV2Payload=B.prepareERC20PeggedVariableCriteriaIncentiveV2Payload;exports.PointsIncentive=T.PointsIncentive;exports.preparePointsIncentivePayload=T.preparePointsIncentivePayload;exports.SignerValidator=s.SignerValidator;exports.prepareSignerValidatorClaimDataPayload=s.prepareSignerValidatorClaimDataPayload;exports.prepareSignerValidatorInputParams=s.prepareSignerValidatorInputParams;exports.prepareSignerValidatorPayload=s.prepareSignerValidatorPayload;exports.LimitedSignerValidator=p.LimitedSignerValidator;exports.prepareLimitedSignerValidatorClaimDataPayload=p.prepareLimitedSignerValidatorClaimDataPayload;exports.prepareLimitedSignerValidatorInputParams=p.prepareLimitedSignerValidatorInputParams;exports.prepareLimitedSignerValidatorPayload=p.prepareLimitedSignerValidatorPayload;exports.BoostValidatorEOA=c.BoostValidatorEOA;exports.ValidatorByComponentInterface=c.ValidatorByComponentInterface;exports.decodeClaimData=c.decodeClaimData;exports.validatorFromAddress=c.validatorFromAddress;exports.BoostCoreNoIdentifierEmitted=e.BoostCoreNoIdentifierEmitted;exports.BoostNotFoundError=e.BoostNotFoundError;exports.BudgetMustAuthorizeBoostCore=e.BudgetMustAuthorizeBoostCore;exports.ContractAddressRequiredError=e.ContractAddressRequiredError;exports.DecodedArgsError=e.DecodedArgsError;exports.DecodedArgsMalformedError=e.DecodedArgsMalformedError;exports.DeployableAlreadyDeployedError=e.DeployableAlreadyDeployedError;exports.DeployableBuildParametersUnspecifiedError=e.DeployableBuildParametersUnspecifiedError;exports.DeployableMissingPayloadError=e.DeployableMissingPayloadError;exports.DeployableUnknownOwnerProvidedError=e.DeployableUnknownOwnerProvidedError;exports.DeployableWagmiConfigurationRequiredError=e.DeployableWagmiConfigurationRequiredError;exports.FieldActionValidationError=e.FieldActionValidationError;exports.FieldValueNotComparableError=e.FieldValueNotComparableError;exports.FieldValueUndefinedError=e.FieldValueUndefinedError;exports.FunctionDataDecodeError=e.FunctionDataDecodeError;exports.IncentiveCriteriaNotFoundError=e.IncentiveCriteriaNotFoundError;exports.IncentiveNotCloneableError=e.IncentiveNotCloneableError;exports.InvalidComponentInterfaceError=e.InvalidComponentInterfaceError;exports.InvalidCriteriaTypeError=e.InvalidCriteriaTypeError;exports.InvalidNumericalCriteriaError=e.InvalidNumericalCriteriaError;exports.InvalidProtocolChainIdError=e.InvalidProtocolChainIdError;exports.InvalidTupleDecodingError=e.InvalidTupleDecodingError;exports.InvalidTupleEncodingError=e.InvalidTupleEncodingError;exports.MustInitializeBudgetError=e.MustInitializeBudgetError;exports.NoConnectedChainIdError=e.NoConnectedChainIdError;exports.NoContractAddressUponReceiptError=e.NoContractAddressUponReceiptError;exports.NoEventActionStepsProvidedError=e.NoEventActionStepsProvidedError;exports.NoMatchingLogsError=e.NoMatchingLogsError;exports.TooManyEventActionStepsProvidedError=e.TooManyEventActionStepsProvidedError;exports.UnknownTransferPayloadSupplied=e.UnknownTransferPayloadSupplied;exports.UnparseableAbiParamError=e.UnparseableAbiParamError;exports.UnrecognizedFilterTypeError=e.UnrecognizedFilterTypeError;exports.ValidationAbiMissingError=e.ValidationAbiMissingError;exports.CheatCodes=i.CheatCodes;exports.RegistryType=i.RegistryType;exports.TRANSFER_SIGNATURE=i.TRANSFER_SIGNATURE;exports.assertValidAddressByChainId=i.assertValidAddressByChainId;exports.awaitResult=i.awaitResult;exports.bytes4=i.bytes4;exports.getDeployedContractAddress=i.getDeployedContractAddress;exports.getErc20Balance=i.getErc20Balance;exports.StrategyType=D.StrategyType;exports.prepareClaimPayload=D.prepareClaimPayload;exports.AssetType=o.AssetType;exports.prepareERC1155Payload=o.prepareERC1155Payload;exports.prepareERC1155Transfer=o.prepareERC1155Transfer;exports.prepareFungiblePayload=o.prepareFungiblePayload;exports.prepareFungibleTransfer=o.prepareFungibleTransfer;exports.prepareTransferPayload=o.prepareTransferPayload;exports.PassthroughAuth=h.PassthroughAuth;exports.allowListIncentiveAbi=r._;exports.boostCoreAbi=r.M;exports.boostRegistryAbi=r.Ae;exports.cgdaIncentiveAbi=r.E;exports.erc20IncentiveAbi=r.T;exports.erc20PeggedIncentiveAbi=r.g;exports.erc20PeggedVariableCriteriaIncentiveAbi=r.y;exports.erc20PeggedVariableCriteriaIncentiveV2Abi=r.d;exports.erc20VariableCriteriaIncentiveAbi=r.c;exports.erc20VariableCriteriaIncentiveV2Abi=r.m;exports.erc20VariableIncentiveAbi=r.R;exports.limitedSignerValidatorAbi=r.D;exports.managedBudgetAbi=r.C;exports.managedBudgetWithFeesAbi=r.p;exports.managedBudgetWithFeesV2Abi=r.r;exports.passthroughAuthAbi=r.at;exports.pointsIncentiveAbi=r.z;exports.rbacAbi=r.S;exports.signerValidatorAbi=r.G;exports.simpleAllowListAbi=r.F;exports.simpleDenyListAbi=r.k;exports.transparentBudgetAbi=r.b;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("./BoostRegistry.cjs"),d=require("./BoostCore.cjs"),I=require("./Boost.cjs"),A=require("./Actions/Action.cjs"),a=require("./Actions/EventAction.cjs"),E=require("./AllowLists/AllowList.cjs"),C=require("./AllowLists/SimpleAllowList.cjs"),v=require("./SimpleDenyList-B2YDJ_gk.cjs"),t=require("./Budget-uGKa2qzz.cjs"),n=require("./Budgets/ManagedBudget.cjs"),F=require("./Deployable/Deployable.cjs"),L=require("./Deployable/Contract.cjs"),f=require("./Deployable/DeployableTarget.cjs"),P=require("./Deployable/DeployableTargetWithRBAC.cjs"),b=require("./Incentives/AllowListIncentive.cjs"),R=require("./Incentives/CGDAIncentive.cjs"),S=require("./Incentives/ERC20Incentive.cjs"),l=require("./Incentive-Dufx0ZjH.cjs"),V=require("./Incentives/ERC20VariableIncentive.cjs"),y=require("./Incentives/ERC20VariableCriteriaIncentive.cjs"),m=require("./Incentives/ERC20PeggedVariableCriteriaIncentive.cjs"),u=require("./Incentives/ERC20VariableCriteriaIncentiveV2.cjs"),B=require("./Incentives/ERC20PeggedVariableCriteriaIncentiveV2.cjs"),T=require("./Incentives/PointsIncentive.cjs"),s=require("./Validators/SignerValidator.cjs"),p=require("./Validators/LimitedSignerValidator.cjs"),c=require("./Validators/Validator.cjs"),e=require("./errors.cjs"),i=require("./utils.cjs"),D=require("./claiming.cjs"),o=require("./transfers.cjs"),h=require("./Auth/PassthroughAuth.cjs"),r=require("./generated-C_JEoLDO.cjs");exports.BOOST_REGISTRY_ADDRESS=g.BOOST_REGISTRY_ADDRESS;exports.BOOST_REGISTRY_ADDRESSES=g.BOOST_REGISTRY_ADDRESSES;exports.BoostRegistry=g.BoostRegistry;exports.BOOST_CORE_ADDRESS=d.BOOST_CORE_ADDRESS;exports.BOOST_CORE_ADDRESSES=d.BOOST_CORE_ADDRESSES;exports.BoostCore=d.BoostCore;exports.FEE_DENOMINATOR=d.FEE_DENOMINATOR;exports.Boost=I.Boost;exports.prepareBoostPayload=I.prepareBoostPayload;exports.ActionByComponentInterface=A.ActionByComponentInterface;exports.actionFromAddress=A.actionFromAddress;exports.EventAction=a.EventAction;exports.FilterType=a.FilterType;exports.PrimitiveType=a.PrimitiveType;exports.SignatureType=a.SignatureType;exports.ValueType=a.ValueType;exports.anyActionParameter=a.anyActionParameter;exports.decodeAndReorderLogArgs=a.decodeAndReorderLogArgs;exports.detectSignatureType=a.detectSignatureType;exports.getScalarValueFromTuple=a.getScalarValueFromTuple;exports.isCriteriaFieldIndexTuple=a.isCriteriaFieldIndexTuple;exports.isEventActionPayloadSimple=a.isEventActionPayloadSimple;exports.packCriteriaFieldIndexes=a.packCriteriaFieldIndexes;exports.packFieldIndexes=a.packFieldIndexes;exports.prepareEventActionPayload=a.prepareEventActionPayload;exports.transactionSenderClaimant=a.transactionSenderClaimant;exports.unpackCriteriaFieldIndexes=a.unpackCriteriaFieldIndexes;exports.unpackFieldIndexes=a.unpackFieldIndexes;exports.AllowListByComponentInterface=E.AllowListByComponentInterface;exports.OpenAllowList=E.OpenAllowList;exports.allowListFromAddress=E.allowListFromAddress;exports.LIST_MANAGER_ROLE=C.LIST_MANAGER_ROLE;exports.SimpleAllowList=C.SimpleAllowList;exports.prepareSimpleAllowListPayload=C.prepareSimpleAllowListPayload;exports.SimpleDenyList=v.SimpleDenyList;exports.prepareSimpleDenyListPayload=v.prepareSimpleDenyListPayload;exports.BudgetByComponentInterface=t.BudgetByComponentInterface;exports.ManagedBudgetWithFees=t.ManagedBudgetWithFees;exports.ManagedBudgetWithFeesV2=t.ManagedBudgetWithFeesV2;exports.TransparentBudget=t.TransparentBudget;exports.budgetFromAddress=t.budgetFromAddress;exports.prepareManagedBudgetWithFeesPayload=t.prepareManagedBudgetWithFeesPayload;exports.prepareManagedBudgetWithFeesV2Payload=t.prepareManagedBudgetWithFeesV2Payload;exports.ManagedBudget=n.ManagedBudget;exports.ManagedBudgetRoles=n.ManagedBudgetRoles;exports.isERC1155TransferPayload=n.isERC1155TransferPayload;exports.isFungibleTransfer=n.isFungibleTransfer;exports.prepareManagedBudgetPayload=n.prepareManagedBudgetPayload;exports.prepareTransfer=n.prepareTransfer;exports.Deployable=F.Deployable;exports.Contract=L.Contract;exports.DeployableTarget=f.DeployableTarget;exports.DeployableTargetWithRBAC=P.DeployableTargetWithRBAC;exports.Roles=P.Roles;exports.AllowListIncentive=b.AllowListIncentive;exports.prepareAllowListIncentivePayload=b.prepareAllowListIncentivePayload;exports.CGDAIncentive=R.CGDAIncentive;exports.prepareCGDAIncentivePayload=R.prepareCGDAIncentivePayload;exports.ERC20Incentive=S.ERC20Incentive;exports.prepareERC20IncentivePayload=S.prepareERC20IncentivePayload;exports.ERC20PeggedIncentive=l.ERC20PeggedIncentive;exports.IncentiveByComponentInterface=l.IncentiveByComponentInterface;exports.incentiveFromAddress=l.incentiveFromAddress;exports.prepareERC20PeggedIncentivePayload=l.prepareERC20PeggedIncentivePayload;exports.ERC20VariableIncentive=V.ERC20VariableIncentive;exports.prepareERC20VariableIncentivePayload=V.prepareERC20VariableIncentivePayload;exports.ERC20VariableCriteriaIncentive=y.ERC20VariableCriteriaIncentive;exports.gasRebateIncentiveCriteria=y.gasRebateIncentiveCriteria;exports.prepareERC20VariableCriteriaIncentivePayload=y.prepareERC20VariableCriteriaIncentivePayload;exports.ERC20PeggedVariableCriteriaIncentive=m.ERC20PeggedVariableCriteriaIncentive;exports.prepareERC20PeggedVariableCriteriaIncentivePayload=m.prepareERC20PeggedVariableCriteriaIncentivePayload;exports.ERC20VariableCriteriaIncentiveV2=u.ERC20VariableCriteriaIncentiveV2;exports.gasRebateIncentiveCriteriaV2=u.gasRebateIncentiveCriteriaV2;exports.prepareERC20VariableCriteriaIncentiveV2Payload=u.prepareERC20VariableCriteriaIncentiveV2Payload;exports.ERC20PeggedVariableCriteriaIncentiveV2=B.ERC20PeggedVariableCriteriaIncentiveV2;exports.prepareERC20PeggedVariableCriteriaIncentiveV2Payload=B.prepareERC20PeggedVariableCriteriaIncentiveV2Payload;exports.PointsIncentive=T.PointsIncentive;exports.preparePointsIncentivePayload=T.preparePointsIncentivePayload;exports.SignerValidator=s.SignerValidator;exports.prepareSignerValidatorClaimDataPayload=s.prepareSignerValidatorClaimDataPayload;exports.prepareSignerValidatorInputParams=s.prepareSignerValidatorInputParams;exports.prepareSignerValidatorPayload=s.prepareSignerValidatorPayload;exports.LimitedSignerValidator=p.LimitedSignerValidator;exports.prepareLimitedSignerValidatorClaimDataPayload=p.prepareLimitedSignerValidatorClaimDataPayload;exports.prepareLimitedSignerValidatorInputParams=p.prepareLimitedSignerValidatorInputParams;exports.prepareLimitedSignerValidatorPayload=p.prepareLimitedSignerValidatorPayload;exports.BoostValidatorEOA=c.BoostValidatorEOA;exports.ValidatorByComponentInterface=c.ValidatorByComponentInterface;exports.decodeClaimData=c.decodeClaimData;exports.validatorFromAddress=c.validatorFromAddress;exports.BoostCoreNoIdentifierEmitted=e.BoostCoreNoIdentifierEmitted;exports.BoostNotFoundError=e.BoostNotFoundError;exports.BudgetMustAuthorizeBoostCore=e.BudgetMustAuthorizeBoostCore;exports.ContractAddressRequiredError=e.ContractAddressRequiredError;exports.DecodedArgsError=e.DecodedArgsError;exports.DecodedArgsMalformedError=e.DecodedArgsMalformedError;exports.DeployableAlreadyDeployedError=e.DeployableAlreadyDeployedError;exports.DeployableBuildParametersUnspecifiedError=e.DeployableBuildParametersUnspecifiedError;exports.DeployableMissingPayloadError=e.DeployableMissingPayloadError;exports.DeployableUnknownOwnerProvidedError=e.DeployableUnknownOwnerProvidedError;exports.DeployableWagmiConfigurationRequiredError=e.DeployableWagmiConfigurationRequiredError;exports.FieldActionValidationError=e.FieldActionValidationError;exports.FieldValueNotComparableError=e.FieldValueNotComparableError;exports.FieldValueUndefinedError=e.FieldValueUndefinedError;exports.FunctionDataDecodeError=e.FunctionDataDecodeError;exports.IncentiveCriteriaNotFoundError=e.IncentiveCriteriaNotFoundError;exports.IncentiveNotCloneableError=e.IncentiveNotCloneableError;exports.InvalidComponentInterfaceError=e.InvalidComponentInterfaceError;exports.InvalidCriteriaTypeError=e.InvalidCriteriaTypeError;exports.InvalidNumericalCriteriaError=e.InvalidNumericalCriteriaError;exports.InvalidProtocolChainIdError=e.InvalidProtocolChainIdError;exports.InvalidTupleDecodingError=e.InvalidTupleDecodingError;exports.InvalidTupleEncodingError=e.InvalidTupleEncodingError;exports.MustInitializeBudgetError=e.MustInitializeBudgetError;exports.NoConnectedChainIdError=e.NoConnectedChainIdError;exports.NoContractAddressUponReceiptError=e.NoContractAddressUponReceiptError;exports.NoEventActionStepsProvidedError=e.NoEventActionStepsProvidedError;exports.NoMatchingLogsError=e.NoMatchingLogsError;exports.TooManyEventActionStepsProvidedError=e.TooManyEventActionStepsProvidedError;exports.UnknownTransferPayloadSupplied=e.UnknownTransferPayloadSupplied;exports.UnparseableAbiParamError=e.UnparseableAbiParamError;exports.UnrecognizedFilterTypeError=e.UnrecognizedFilterTypeError;exports.ValidationAbiMissingError=e.ValidationAbiMissingError;exports.CheatCodes=i.CheatCodes;exports.RegistryType=i.RegistryType;exports.TRANSFER_SIGNATURE=i.TRANSFER_SIGNATURE;exports.assertValidAddressByChainId=i.assertValidAddressByChainId;exports.awaitResult=i.awaitResult;exports.bytes4=i.bytes4;exports.getDeployedContractAddress=i.getDeployedContractAddress;exports.getErc20Balance=i.getErc20Balance;exports.StrategyType=D.StrategyType;exports.prepareClaimPayload=D.prepareClaimPayload;exports.AssetType=o.AssetType;exports.prepareERC1155Payload=o.prepareERC1155Payload;exports.prepareERC1155Transfer=o.prepareERC1155Transfer;exports.prepareFungiblePayload=o.prepareFungiblePayload;exports.prepareFungibleTransfer=o.prepareFungibleTransfer;exports.prepareTransferPayload=o.prepareTransferPayload;exports.PassthroughAuth=h.PassthroughAuth;exports.allowListIncentiveAbi=r._;exports.boostCoreAbi=r.M;exports.boostRegistryAbi=r.Ae;exports.cgdaIncentiveAbi=r.E;exports.erc20IncentiveAbi=r.T;exports.erc20PeggedIncentiveAbi=r.g;exports.erc20PeggedVariableCriteriaIncentiveAbi=r.y;exports.erc20PeggedVariableCriteriaIncentiveV2Abi=r.d;exports.erc20VariableCriteriaIncentiveAbi=r.c;exports.erc20VariableCriteriaIncentiveV2Abi=r.m;exports.erc20VariableIncentiveAbi=r.R;exports.limitedSignerValidatorAbi=r.D;exports.managedBudgetAbi=r.C;exports.managedBudgetWithFeesAbi=r.p;exports.managedBudgetWithFeesV2Abi=r.r;exports.passthroughAuthAbi=r.at;exports.pointsIncentiveAbi=r.z;exports.rbacAbi=r.S;exports.signerValidatorAbi=r.G;exports.simpleAllowListAbi=r.F;exports.simpleDenyListAbi=r.k;exports.transparentBudgetAbi=r.b;
2
2
  //# sourceMappingURL=index.cjs.map
package/dist/index.js CHANGED
@@ -1,194 +1,198 @@
1
- import { BOOST_REGISTRY_ADDRESS as a, BOOST_REGISTRY_ADDRESSES as o, BoostRegistry as i } from "./BoostRegistry.js";
1
+ import { BOOST_REGISTRY_ADDRESS as a, BOOST_REGISTRY_ADDRESSES as i, BoostRegistry as o } from "./BoostRegistry.js";
2
2
  import { BOOST_CORE_ADDRESS as n, BOOST_CORE_ADDRESSES as d, BoostCore as p, FEE_DENOMINATOR as l } from "./BoostCore.js";
3
3
  import { Boost as c, prepareBoostPayload as g } from "./Boost.js";
4
4
  import { ActionByComponentInterface as E, actionFromAddress as A } from "./Actions/Action.js";
5
- import { EventAction as y, FilterType as b, PrimitiveType as I, SignatureType as v, ValueType as f, anyActionParameter as P, decodeAndReorderLogArgs as R, detectSignatureType as u, isEventActionPayloadSimple as V, packFieldIndexes as S, prepareEventActionPayload as B, transactionSenderClaimant as x, unpackFieldIndexes as T } from "./Actions/EventAction.js";
6
- import { AllowListByComponentInterface as F, OpenAllowList as L, allowListFromAddress as h } from "./AllowLists/AllowList.js";
7
- import { LIST_MANAGER_ROLE as O, SimpleAllowList as N, prepareSimpleAllowListPayload as w } from "./AllowLists/SimpleAllowList.js";
8
- import { S as U, p as W } from "./SimpleDenyList-BlLgvhjE.js";
9
- import { B as k, M as z, a as q, T as Y, b as j, p as H, c as J } from "./Budget-B-grnRq9.js";
10
- import { ManagedBudget as Q, ManagedBudgetRoles as X, isERC1155TransferPayload as Z, isFungibleTransfer as $, prepareManagedBudgetPayload as ee, prepareTransfer as re } from "./Budgets/ManagedBudget.js";
11
- import { Deployable as oe } from "./Deployable/Deployable.js";
12
- import { Contract as te } from "./Deployable/Contract.js";
13
- import { DeployableTarget as de } from "./Deployable/DeployableTarget.js";
14
- import { DeployableTargetWithRBAC as le, Roles as se } from "./Deployable/DeployableTargetWithRBAC.js";
15
- import { AllowListIncentive as ge, prepareAllowListIncentivePayload as me } from "./Incentives/AllowListIncentive.js";
16
- import { CGDAIncentive as Ae, prepareCGDAIncentivePayload as Ce } from "./Incentives/CGDAIncentive.js";
17
- import { ERC20Incentive as be, prepareERC20IncentivePayload as Ie } from "./Incentives/ERC20Incentive.js";
18
- import { E as fe, I as Pe, i as Re, p as ue } from "./Incentive-Bz_g-nID.js";
19
- import { ERC20VariableIncentive as Se, prepareERC20VariableIncentivePayload as Be } from "./Incentives/ERC20VariableIncentive.js";
20
- import { ERC20VariableCriteriaIncentive as Te, gasRebateIncentiveCriteria as De, prepareERC20VariableCriteriaIncentivePayload as Fe } from "./Incentives/ERC20VariableCriteriaIncentive.js";
21
- import { ERC20PeggedVariableCriteriaIncentive as he, prepareERC20PeggedVariableCriteriaIncentivePayload as Me } from "./Incentives/ERC20PeggedVariableCriteriaIncentive.js";
22
- import { ERC20VariableCriteriaIncentiveV2 as Ne, gasRebateIncentiveCriteriaV2 as we, prepareERC20VariableCriteriaIncentiveV2Payload as _e } from "./Incentives/ERC20VariableCriteriaIncentiveV2.js";
23
- import { ERC20PeggedVariableCriteriaIncentiveV2 as We, prepareERC20PeggedVariableCriteriaIncentiveV2Payload as Ge } from "./Incentives/ERC20PeggedVariableCriteriaIncentiveV2.js";
24
- import { PointsIncentive as ze, preparePointsIncentivePayload as qe } from "./Incentives/PointsIncentive.js";
25
- import { SignerValidator as je, prepareSignerValidatorClaimDataPayload as He, prepareSignerValidatorInputParams as Je, prepareSignerValidatorPayload as Ke } from "./Validators/SignerValidator.js";
26
- import { LimitedSignerValidator as Xe, prepareLimitedSignerValidatorClaimDataPayload as Ze, prepareLimitedSignerValidatorInputParams as $e, prepareLimitedSignerValidatorPayload as er } from "./Validators/LimitedSignerValidator.js";
27
- import { BoostValidatorEOA as ar, ValidatorByComponentInterface as or, decodeClaimData as ir, validatorFromAddress as tr } from "./Validators/Validator.js";
28
- import { BoostCoreNoIdentifierEmitted as dr, BoostNotFoundError as pr, BudgetMustAuthorizeBoostCore as lr, ContractAddressRequiredError as sr, DecodedArgsError as cr, DecodedArgsMalformedError as gr, DeployableAlreadyDeployedError as mr, DeployableBuildParametersUnspecifiedError as Er, DeployableMissingPayloadError as Ar, DeployableUnknownOwnerProvidedError as Cr, DeployableWagmiConfigurationRequiredError as yr, FieldActionValidationError as br, FieldValueNotComparableError as Ir, FieldValueUndefinedError as vr, FunctionDataDecodeError as fr, IncentiveCriteriaNotFoundError as Pr, IncentiveNotCloneableError as Rr, InvalidComponentInterfaceError as ur, InvalidCriteriaTypeError as Vr, InvalidNumericalCriteriaError as Sr, InvalidProtocolChainIdError as Br, InvalidTupleDecodingError as xr, InvalidTupleEncodingError as Tr, MustInitializeBudgetError as Dr, NoConnectedChainIdError as Fr, NoContractAddressUponReceiptError as Lr, NoEventActionStepsProvidedError as hr, NoMatchingLogsError as Mr, TooManyEventActionStepsProvidedError as Or, UnknownTransferPayloadSupplied as Nr, UnparseableAbiParamError as wr, UnrecognizedFilterTypeError as _r, ValidationAbiMissingError as Ur } from "./errors.js";
29
- import { CheatCodes as Gr, RegistryType as kr, TRANSFER_SIGNATURE as zr, assertValidAddressByChainId as qr, awaitResult as Yr, bytes4 as jr, getDeployedContractAddress as Hr, getErc20Balance as Jr } from "./utils.js";
30
- import { StrategyType as Qr, prepareClaimPayload as Xr } from "./claiming.js";
31
- import { AssetType as $r, prepareERC1155Payload as ea, prepareERC1155Transfer as ra, prepareFungiblePayload as aa, prepareFungibleTransfer as oa, prepareTransferPayload as ia } from "./transfers.js";
32
- import { PassthroughAuth as na } from "./Auth/PassthroughAuth.js";
33
- import { _ as pa, M as la, A as sa, E as ca, T as ga, g as ma, y as Ea, d as Aa, c as Ca, m as ya, R as ba, D as Ia, C as va, p as fa, r as Pa, a as Ra, z as ua, S as Va, G as Sa, F as Ba, k as xa, b as Ta } from "./generated-CINzoGbl.js";
5
+ import { EventAction as y, FilterType as I, PrimitiveType as b, SignatureType as v, ValueType as f, anyActionParameter as P, decodeAndReorderLogArgs as u, detectSignatureType as R, getScalarValueFromTuple as V, isCriteriaFieldIndexTuple as S, isEventActionPayloadSimple as x, packCriteriaFieldIndexes as B, packFieldIndexes as T, prepareEventActionPayload as D, transactionSenderClaimant as F, unpackCriteriaFieldIndexes as L, unpackFieldIndexes as h } from "./Actions/EventAction.js";
6
+ import { AllowListByComponentInterface as O, OpenAllowList as N, allowListFromAddress as w } from "./AllowLists/AllowList.js";
7
+ import { LIST_MANAGER_ROLE as U, SimpleAllowList as W, prepareSimpleAllowListPayload as k } from "./AllowLists/SimpleAllowList.js";
8
+ import { S as z, p as q } from "./SimpleDenyList-BlLgvhjE.js";
9
+ import { B as j, M as H, a as J, T as K, b as Q, p as X, c as Z } from "./Budget-B-grnRq9.js";
10
+ import { ManagedBudget as ee, ManagedBudgetRoles as re, isERC1155TransferPayload as ae, isFungibleTransfer as ie, prepareManagedBudgetPayload as oe, prepareTransfer as te } from "./Budgets/ManagedBudget.js";
11
+ import { Deployable as de } from "./Deployable/Deployable.js";
12
+ import { Contract as le } from "./Deployable/Contract.js";
13
+ import { DeployableTarget as ce } from "./Deployable/DeployableTarget.js";
14
+ import { DeployableTargetWithRBAC as me, Roles as Ee } from "./Deployable/DeployableTargetWithRBAC.js";
15
+ import { AllowListIncentive as Ce, prepareAllowListIncentivePayload as ye } from "./Incentives/AllowListIncentive.js";
16
+ import { CGDAIncentive as be, prepareCGDAIncentivePayload as ve } from "./Incentives/CGDAIncentive.js";
17
+ import { ERC20Incentive as Pe, prepareERC20IncentivePayload as ue } from "./Incentives/ERC20Incentive.js";
18
+ import { E as Ve, I as Se, i as xe, p as Be } from "./Incentive-Bz_g-nID.js";
19
+ import { ERC20VariableIncentive as De, prepareERC20VariableIncentivePayload as Fe } from "./Incentives/ERC20VariableIncentive.js";
20
+ import { ERC20VariableCriteriaIncentive as he, gasRebateIncentiveCriteria as Me, prepareERC20VariableCriteriaIncentivePayload as Oe } from "./Incentives/ERC20VariableCriteriaIncentive.js";
21
+ import { ERC20PeggedVariableCriteriaIncentive as we, prepareERC20PeggedVariableCriteriaIncentivePayload as _e } from "./Incentives/ERC20PeggedVariableCriteriaIncentive.js";
22
+ import { ERC20VariableCriteriaIncentiveV2 as We, gasRebateIncentiveCriteriaV2 as ke, prepareERC20VariableCriteriaIncentiveV2Payload as Ge } from "./Incentives/ERC20VariableCriteriaIncentiveV2.js";
23
+ import { ERC20PeggedVariableCriteriaIncentiveV2 as qe, prepareERC20PeggedVariableCriteriaIncentiveV2Payload as Ye } from "./Incentives/ERC20PeggedVariableCriteriaIncentiveV2.js";
24
+ import { PointsIncentive as He, preparePointsIncentivePayload as Je } from "./Incentives/PointsIncentive.js";
25
+ import { SignerValidator as Qe, prepareSignerValidatorClaimDataPayload as Xe, prepareSignerValidatorInputParams as Ze, prepareSignerValidatorPayload as $e } from "./Validators/SignerValidator.js";
26
+ import { LimitedSignerValidator as rr, prepareLimitedSignerValidatorClaimDataPayload as ar, prepareLimitedSignerValidatorInputParams as ir, prepareLimitedSignerValidatorPayload as or } from "./Validators/LimitedSignerValidator.js";
27
+ import { BoostValidatorEOA as nr, ValidatorByComponentInterface as dr, decodeClaimData as pr, validatorFromAddress as lr } from "./Validators/Validator.js";
28
+ import { BoostCoreNoIdentifierEmitted as cr, BoostNotFoundError as gr, BudgetMustAuthorizeBoostCore as mr, ContractAddressRequiredError as Er, DecodedArgsError as Ar, DecodedArgsMalformedError as Cr, DeployableAlreadyDeployedError as yr, DeployableBuildParametersUnspecifiedError as Ir, DeployableMissingPayloadError as br, DeployableUnknownOwnerProvidedError as vr, DeployableWagmiConfigurationRequiredError as fr, FieldActionValidationError as Pr, FieldValueNotComparableError as ur, FieldValueUndefinedError as Rr, FunctionDataDecodeError as Vr, IncentiveCriteriaNotFoundError as Sr, IncentiveNotCloneableError as xr, InvalidComponentInterfaceError as Br, InvalidCriteriaTypeError as Tr, InvalidNumericalCriteriaError as Dr, InvalidProtocolChainIdError as Fr, InvalidTupleDecodingError as Lr, InvalidTupleEncodingError as hr, MustInitializeBudgetError as Mr, NoConnectedChainIdError as Or, NoContractAddressUponReceiptError as Nr, NoEventActionStepsProvidedError as wr, NoMatchingLogsError as _r, TooManyEventActionStepsProvidedError as Ur, UnknownTransferPayloadSupplied as Wr, UnparseableAbiParamError as kr, UnrecognizedFilterTypeError as Gr, ValidationAbiMissingError as zr } from "./errors.js";
29
+ import { CheatCodes as Yr, RegistryType as jr, TRANSFER_SIGNATURE as Hr, assertValidAddressByChainId as Jr, awaitResult as Kr, bytes4 as Qr, getDeployedContractAddress as Xr, getErc20Balance as Zr } from "./utils.js";
30
+ import { StrategyType as ea, prepareClaimPayload as ra } from "./claiming.js";
31
+ import { AssetType as ia, prepareERC1155Payload as oa, prepareERC1155Transfer as ta, prepareFungiblePayload as na, prepareFungibleTransfer as da, prepareTransferPayload as pa } from "./transfers.js";
32
+ import { PassthroughAuth as sa } from "./Auth/PassthroughAuth.js";
33
+ import { _ as ga, M as ma, A as Ea, E as Aa, T as Ca, g as ya, y as Ia, d as ba, c as va, m as fa, R as Pa, D as ua, C as Ra, p as Va, r as Sa, a as xa, z as Ba, S as Ta, G as Da, F as Fa, k as La, b as ha } from "./generated-CINzoGbl.js";
34
34
  export {
35
35
  E as ActionByComponentInterface,
36
- F as AllowListByComponentInterface,
37
- ge as AllowListIncentive,
38
- $r as AssetType,
36
+ O as AllowListByComponentInterface,
37
+ Ce as AllowListIncentive,
38
+ ia as AssetType,
39
39
  n as BOOST_CORE_ADDRESS,
40
40
  d as BOOST_CORE_ADDRESSES,
41
41
  a as BOOST_REGISTRY_ADDRESS,
42
- o as BOOST_REGISTRY_ADDRESSES,
42
+ i as BOOST_REGISTRY_ADDRESSES,
43
43
  c as Boost,
44
44
  p as BoostCore,
45
- dr as BoostCoreNoIdentifierEmitted,
46
- pr as BoostNotFoundError,
47
- i as BoostRegistry,
48
- ar as BoostValidatorEOA,
49
- k as BudgetByComponentInterface,
50
- lr as BudgetMustAuthorizeBoostCore,
51
- Ae as CGDAIncentive,
52
- Gr as CheatCodes,
53
- te as Contract,
54
- sr as ContractAddressRequiredError,
55
- cr as DecodedArgsError,
56
- gr as DecodedArgsMalformedError,
57
- oe as Deployable,
58
- mr as DeployableAlreadyDeployedError,
59
- Er as DeployableBuildParametersUnspecifiedError,
60
- Ar as DeployableMissingPayloadError,
61
- de as DeployableTarget,
62
- le as DeployableTargetWithRBAC,
63
- Cr as DeployableUnknownOwnerProvidedError,
64
- yr as DeployableWagmiConfigurationRequiredError,
65
- be as ERC20Incentive,
66
- fe as ERC20PeggedIncentive,
67
- he as ERC20PeggedVariableCriteriaIncentive,
68
- We as ERC20PeggedVariableCriteriaIncentiveV2,
69
- Te as ERC20VariableCriteriaIncentive,
70
- Ne as ERC20VariableCriteriaIncentiveV2,
71
- Se as ERC20VariableIncentive,
45
+ cr as BoostCoreNoIdentifierEmitted,
46
+ gr as BoostNotFoundError,
47
+ o as BoostRegistry,
48
+ nr as BoostValidatorEOA,
49
+ j as BudgetByComponentInterface,
50
+ mr as BudgetMustAuthorizeBoostCore,
51
+ be as CGDAIncentive,
52
+ Yr as CheatCodes,
53
+ le as Contract,
54
+ Er as ContractAddressRequiredError,
55
+ Ar as DecodedArgsError,
56
+ Cr as DecodedArgsMalformedError,
57
+ de as Deployable,
58
+ yr as DeployableAlreadyDeployedError,
59
+ Ir as DeployableBuildParametersUnspecifiedError,
60
+ br as DeployableMissingPayloadError,
61
+ ce as DeployableTarget,
62
+ me as DeployableTargetWithRBAC,
63
+ vr as DeployableUnknownOwnerProvidedError,
64
+ fr as DeployableWagmiConfigurationRequiredError,
65
+ Pe as ERC20Incentive,
66
+ Ve as ERC20PeggedIncentive,
67
+ we as ERC20PeggedVariableCriteriaIncentive,
68
+ qe as ERC20PeggedVariableCriteriaIncentiveV2,
69
+ he as ERC20VariableCriteriaIncentive,
70
+ We as ERC20VariableCriteriaIncentiveV2,
71
+ De as ERC20VariableIncentive,
72
72
  y as EventAction,
73
73
  l as FEE_DENOMINATOR,
74
- br as FieldActionValidationError,
75
- Ir as FieldValueNotComparableError,
76
- vr as FieldValueUndefinedError,
77
- b as FilterType,
78
- fr as FunctionDataDecodeError,
79
- Pe as IncentiveByComponentInterface,
80
- Pr as IncentiveCriteriaNotFoundError,
81
- Rr as IncentiveNotCloneableError,
82
- ur as InvalidComponentInterfaceError,
83
- Vr as InvalidCriteriaTypeError,
84
- Sr as InvalidNumericalCriteriaError,
85
- Br as InvalidProtocolChainIdError,
86
- xr as InvalidTupleDecodingError,
87
- Tr as InvalidTupleEncodingError,
88
- O as LIST_MANAGER_ROLE,
89
- Xe as LimitedSignerValidator,
90
- Q as ManagedBudget,
91
- X as ManagedBudgetRoles,
92
- z as ManagedBudgetWithFees,
93
- q as ManagedBudgetWithFeesV2,
94
- Dr as MustInitializeBudgetError,
95
- Fr as NoConnectedChainIdError,
96
- Lr as NoContractAddressUponReceiptError,
97
- hr as NoEventActionStepsProvidedError,
98
- Mr as NoMatchingLogsError,
99
- L as OpenAllowList,
100
- na as PassthroughAuth,
101
- ze as PointsIncentive,
102
- I as PrimitiveType,
103
- kr as RegistryType,
104
- se as Roles,
74
+ Pr as FieldActionValidationError,
75
+ ur as FieldValueNotComparableError,
76
+ Rr as FieldValueUndefinedError,
77
+ I as FilterType,
78
+ Vr as FunctionDataDecodeError,
79
+ Se as IncentiveByComponentInterface,
80
+ Sr as IncentiveCriteriaNotFoundError,
81
+ xr as IncentiveNotCloneableError,
82
+ Br as InvalidComponentInterfaceError,
83
+ Tr as InvalidCriteriaTypeError,
84
+ Dr as InvalidNumericalCriteriaError,
85
+ Fr as InvalidProtocolChainIdError,
86
+ Lr as InvalidTupleDecodingError,
87
+ hr as InvalidTupleEncodingError,
88
+ U as LIST_MANAGER_ROLE,
89
+ rr as LimitedSignerValidator,
90
+ ee as ManagedBudget,
91
+ re as ManagedBudgetRoles,
92
+ H as ManagedBudgetWithFees,
93
+ J as ManagedBudgetWithFeesV2,
94
+ Mr as MustInitializeBudgetError,
95
+ Or as NoConnectedChainIdError,
96
+ Nr as NoContractAddressUponReceiptError,
97
+ wr as NoEventActionStepsProvidedError,
98
+ _r as NoMatchingLogsError,
99
+ N as OpenAllowList,
100
+ sa as PassthroughAuth,
101
+ He as PointsIncentive,
102
+ b as PrimitiveType,
103
+ jr as RegistryType,
104
+ Ee as Roles,
105
105
  v as SignatureType,
106
- je as SignerValidator,
107
- N as SimpleAllowList,
108
- U as SimpleDenyList,
109
- Qr as StrategyType,
110
- zr as TRANSFER_SIGNATURE,
111
- Or as TooManyEventActionStepsProvidedError,
112
- Y as TransparentBudget,
113
- Nr as UnknownTransferPayloadSupplied,
114
- wr as UnparseableAbiParamError,
115
- _r as UnrecognizedFilterTypeError,
116
- Ur as ValidationAbiMissingError,
117
- or as ValidatorByComponentInterface,
106
+ Qe as SignerValidator,
107
+ W as SimpleAllowList,
108
+ z as SimpleDenyList,
109
+ ea as StrategyType,
110
+ Hr as TRANSFER_SIGNATURE,
111
+ Ur as TooManyEventActionStepsProvidedError,
112
+ K as TransparentBudget,
113
+ Wr as UnknownTransferPayloadSupplied,
114
+ kr as UnparseableAbiParamError,
115
+ Gr as UnrecognizedFilterTypeError,
116
+ zr as ValidationAbiMissingError,
117
+ dr as ValidatorByComponentInterface,
118
118
  f as ValueType,
119
119
  A as actionFromAddress,
120
- h as allowListFromAddress,
121
- pa as allowListIncentiveAbi,
120
+ w as allowListFromAddress,
121
+ ga as allowListIncentiveAbi,
122
122
  P as anyActionParameter,
123
- qr as assertValidAddressByChainId,
124
- Yr as awaitResult,
125
- la as boostCoreAbi,
126
- sa as boostRegistryAbi,
127
- j as budgetFromAddress,
128
- jr as bytes4,
129
- ca as cgdaIncentiveAbi,
130
- R as decodeAndReorderLogArgs,
131
- ir as decodeClaimData,
132
- u as detectSignatureType,
133
- ga as erc20IncentiveAbi,
134
- ma as erc20PeggedIncentiveAbi,
135
- Ea as erc20PeggedVariableCriteriaIncentiveAbi,
136
- Aa as erc20PeggedVariableCriteriaIncentiveV2Abi,
137
- Ca as erc20VariableCriteriaIncentiveAbi,
138
- ya as erc20VariableCriteriaIncentiveV2Abi,
139
- ba as erc20VariableIncentiveAbi,
140
- De as gasRebateIncentiveCriteria,
141
- we as gasRebateIncentiveCriteriaV2,
142
- Hr as getDeployedContractAddress,
143
- Jr as getErc20Balance,
144
- Re as incentiveFromAddress,
145
- Z as isERC1155TransferPayload,
146
- V as isEventActionPayloadSimple,
147
- $ as isFungibleTransfer,
148
- Ia as limitedSignerValidatorAbi,
149
- va as managedBudgetAbi,
150
- fa as managedBudgetWithFeesAbi,
151
- Pa as managedBudgetWithFeesV2Abi,
152
- S as packFieldIndexes,
153
- Ra as passthroughAuthAbi,
154
- ua as pointsIncentiveAbi,
155
- me as prepareAllowListIncentivePayload,
123
+ Jr as assertValidAddressByChainId,
124
+ Kr as awaitResult,
125
+ ma as boostCoreAbi,
126
+ Ea as boostRegistryAbi,
127
+ Q as budgetFromAddress,
128
+ Qr as bytes4,
129
+ Aa as cgdaIncentiveAbi,
130
+ u as decodeAndReorderLogArgs,
131
+ pr as decodeClaimData,
132
+ R as detectSignatureType,
133
+ Ca as erc20IncentiveAbi,
134
+ ya as erc20PeggedIncentiveAbi,
135
+ Ia as erc20PeggedVariableCriteriaIncentiveAbi,
136
+ ba as erc20PeggedVariableCriteriaIncentiveV2Abi,
137
+ va as erc20VariableCriteriaIncentiveAbi,
138
+ fa as erc20VariableCriteriaIncentiveV2Abi,
139
+ Pa as erc20VariableIncentiveAbi,
140
+ Me as gasRebateIncentiveCriteria,
141
+ ke as gasRebateIncentiveCriteriaV2,
142
+ Xr as getDeployedContractAddress,
143
+ Zr as getErc20Balance,
144
+ V as getScalarValueFromTuple,
145
+ xe as incentiveFromAddress,
146
+ S as isCriteriaFieldIndexTuple,
147
+ ae as isERC1155TransferPayload,
148
+ x as isEventActionPayloadSimple,
149
+ ie as isFungibleTransfer,
150
+ ua as limitedSignerValidatorAbi,
151
+ Ra as managedBudgetAbi,
152
+ Va as managedBudgetWithFeesAbi,
153
+ Sa as managedBudgetWithFeesV2Abi,
154
+ B as packCriteriaFieldIndexes,
155
+ T as packFieldIndexes,
156
+ xa as passthroughAuthAbi,
157
+ Ba as pointsIncentiveAbi,
158
+ ye as prepareAllowListIncentivePayload,
156
159
  g as prepareBoostPayload,
157
- Ce as prepareCGDAIncentivePayload,
158
- Xr as prepareClaimPayload,
159
- ea as prepareERC1155Payload,
160
- ra as prepareERC1155Transfer,
161
- Ie as prepareERC20IncentivePayload,
162
- ue as prepareERC20PeggedIncentivePayload,
163
- Me as prepareERC20PeggedVariableCriteriaIncentivePayload,
164
- Ge as prepareERC20PeggedVariableCriteriaIncentiveV2Payload,
165
- Fe as prepareERC20VariableCriteriaIncentivePayload,
166
- _e as prepareERC20VariableCriteriaIncentiveV2Payload,
167
- Be as prepareERC20VariableIncentivePayload,
168
- B as prepareEventActionPayload,
169
- aa as prepareFungiblePayload,
170
- oa as prepareFungibleTransfer,
171
- Ze as prepareLimitedSignerValidatorClaimDataPayload,
172
- $e as prepareLimitedSignerValidatorInputParams,
173
- er as prepareLimitedSignerValidatorPayload,
174
- ee as prepareManagedBudgetPayload,
175
- H as prepareManagedBudgetWithFeesPayload,
176
- J as prepareManagedBudgetWithFeesV2Payload,
177
- qe as preparePointsIncentivePayload,
178
- He as prepareSignerValidatorClaimDataPayload,
179
- Je as prepareSignerValidatorInputParams,
180
- Ke as prepareSignerValidatorPayload,
181
- w as prepareSimpleAllowListPayload,
182
- W as prepareSimpleDenyListPayload,
183
- re as prepareTransfer,
184
- ia as prepareTransferPayload,
185
- Va as rbacAbi,
186
- Sa as signerValidatorAbi,
187
- Ba as simpleAllowListAbi,
188
- xa as simpleDenyListAbi,
189
- x as transactionSenderClaimant,
190
- Ta as transparentBudgetAbi,
191
- T as unpackFieldIndexes,
192
- tr as validatorFromAddress
160
+ ve as prepareCGDAIncentivePayload,
161
+ ra as prepareClaimPayload,
162
+ oa as prepareERC1155Payload,
163
+ ta as prepareERC1155Transfer,
164
+ ue as prepareERC20IncentivePayload,
165
+ Be as prepareERC20PeggedIncentivePayload,
166
+ _e as prepareERC20PeggedVariableCriteriaIncentivePayload,
167
+ Ye as prepareERC20PeggedVariableCriteriaIncentiveV2Payload,
168
+ Oe as prepareERC20VariableCriteriaIncentivePayload,
169
+ Ge as prepareERC20VariableCriteriaIncentiveV2Payload,
170
+ Fe as prepareERC20VariableIncentivePayload,
171
+ D as prepareEventActionPayload,
172
+ na as prepareFungiblePayload,
173
+ da as prepareFungibleTransfer,
174
+ ar as prepareLimitedSignerValidatorClaimDataPayload,
175
+ ir as prepareLimitedSignerValidatorInputParams,
176
+ or as prepareLimitedSignerValidatorPayload,
177
+ oe as prepareManagedBudgetPayload,
178
+ X as prepareManagedBudgetWithFeesPayload,
179
+ Z as prepareManagedBudgetWithFeesV2Payload,
180
+ Je as preparePointsIncentivePayload,
181
+ Xe as prepareSignerValidatorClaimDataPayload,
182
+ Ze as prepareSignerValidatorInputParams,
183
+ $e as prepareSignerValidatorPayload,
184
+ k as prepareSimpleAllowListPayload,
185
+ q as prepareSimpleDenyListPayload,
186
+ te as prepareTransfer,
187
+ pa as prepareTransferPayload,
188
+ Ta as rbacAbi,
189
+ Da as signerValidatorAbi,
190
+ Fa as simpleAllowListAbi,
191
+ La as simpleDenyListAbi,
192
+ F as transactionSenderClaimant,
193
+ ha as transparentBudgetAbi,
194
+ L as unpackCriteriaFieldIndexes,
195
+ h as unpackFieldIndexes,
196
+ lr as validatorFromAddress
193
197
  };
194
198
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@boostxyz/sdk",
3
- "version": "7.0.0",
3
+ "version": "7.2.0",
4
4
  "license": "GPL-3.0-or-later",
5
5
  "type": "module",
6
6
  "files": [