UNPKG

@owlprotocol/contracts-account-abstraction

Version:

ERC4337 Account Abstraction support for deploying relevant smart contracts and interacting with UserOps.

1,678 lines 144 kB
var __defProp = Object.defineProperty; var __getOwnPropDesc = Object.getOwnPropertyDescriptor; var __getOwnPropNames = Object.getOwnPropertyNames; var __hasOwnProp = Object.prototype.hasOwnProperty; var __export = (target, all) => { for (var name in all) __defProp(target, name, { get: all[name], enumerable: true }); }; var __copyProps = (to, from, except, desc) => { if (from && typeof from === "object" || typeof from === "function") { for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); } return to; }; var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); var EntryPointSimulations_exports = {}; __export(EntryPointSimulations_exports, { EntryPointSimulations: () => EntryPointSimulations }); module.exports = __toCommonJS(EntryPointSimulations_exports); const EntryPointSimulations = { compiler: { version: "0.8.23+commit.f704f362" }, language: "Solidity", output: { abi: [ { inputs: [], stateMutability: "nonpayable", type: "constructor" }, { inputs: [ { internalType: "bool", name: "success", type: "bool" }, { internalType: "bytes", name: "ret", type: "bytes" } ], name: "DelegateAndRevert", type: "error" }, { inputs: [ { internalType: "uint256", name: "opIndex", type: "uint256" }, { internalType: "string", name: "reason", type: "string" } ], name: "FailedOp", type: "error" }, { inputs: [ { internalType: "uint256", name: "opIndex", type: "uint256" }, { internalType: "string", name: "reason", type: "string" }, { internalType: "bytes", name: "inner", type: "bytes" } ], name: "FailedOpWithRevert", type: "error" }, { inputs: [ { internalType: "bytes", name: "returnData", type: "bytes" } ], name: "PostOpReverted", type: "error" }, { inputs: [], name: "ReentrancyGuardReentrantCall", type: "error" }, { inputs: [ { internalType: "address", name: "sender", type: "address" } ], name: "SenderAddressResult", type: "error" }, { inputs: [ { internalType: "address", name: "aggregator", type: "address" } ], name: "SignatureValidationFailed", type: "error" }, { anonymous: false, inputs: [ { indexed: true, internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { indexed: true, internalType: "address", name: "sender", type: "address" }, { indexed: false, internalType: "address", name: "factory", type: "address" }, { indexed: false, internalType: "address", name: "paymaster", type: "address" } ], name: "AccountDeployed", type: "event" }, { anonymous: false, inputs: [], name: "BeforeExecution", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address" }, { indexed: false, internalType: "uint256", name: "totalDeposit", type: "uint256" } ], name: "Deposited", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { indexed: true, internalType: "address", name: "sender", type: "address" }, { indexed: false, internalType: "uint256", name: "nonce", type: "uint256" }, { indexed: false, internalType: "bytes", name: "revertReason", type: "bytes" } ], name: "PostOpRevertReason", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "aggregator", type: "address" } ], name: "SignatureAggregatorChanged", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address" }, { indexed: false, internalType: "uint256", name: "totalStaked", type: "uint256" }, { indexed: false, internalType: "uint256", name: "unstakeDelaySec", type: "uint256" } ], name: "StakeLocked", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address" }, { indexed: false, internalType: "uint256", name: "withdrawTime", type: "uint256" } ], name: "StakeUnlocked", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address" }, { indexed: false, internalType: "address", name: "withdrawAddress", type: "address" }, { indexed: false, internalType: "uint256", name: "amount", type: "uint256" } ], name: "StakeWithdrawn", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { indexed: true, internalType: "address", name: "sender", type: "address" }, { indexed: true, internalType: "address", name: "paymaster", type: "address" }, { indexed: false, internalType: "uint256", name: "nonce", type: "uint256" }, { indexed: false, internalType: "bool", name: "success", type: "bool" }, { indexed: false, internalType: "uint256", name: "actualGasCost", type: "uint256" }, { indexed: false, internalType: "uint256", name: "actualGasUsed", type: "uint256" } ], name: "UserOperationEvent", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { indexed: true, internalType: "address", name: "sender", type: "address" }, { indexed: false, internalType: "uint256", name: "nonce", type: "uint256" } ], name: "UserOperationPrefundTooLow", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { indexed: true, internalType: "address", name: "sender", type: "address" }, { indexed: false, internalType: "uint256", name: "nonce", type: "uint256" }, { indexed: false, internalType: "bytes", name: "revertReason", type: "bytes" } ], name: "UserOperationRevertReason", type: "event" }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "account", type: "address" }, { indexed: false, internalType: "address", name: "withdrawAddress", type: "address" }, { indexed: false, internalType: "uint256", name: "amount", type: "uint256" } ], name: "Withdrawn", type: "event" }, { inputs: [ { internalType: "uint32", name: "unstakeDelaySec", type: "uint32" } ], name: "addStake", outputs: [], stateMutability: "payable", type: "function" }, { inputs: [ { internalType: "address", name: "account", type: "address" } ], name: "balanceOf", outputs: [ { internalType: "uint256", name: "", type: "uint256" } ], stateMutability: "view", type: "function" }, { inputs: [ { internalType: "address", name: "target", type: "address" }, { internalType: "bytes", name: "data", type: "bytes" } ], name: "delegateAndRevert", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "address", name: "account", type: "address" } ], name: "depositTo", outputs: [], stateMutability: "payable", type: "function" }, { inputs: [ { internalType: "address", name: "", type: "address" } ], name: "deposits", outputs: [ { internalType: "uint256", name: "deposit", type: "uint256" }, { internalType: "bool", name: "staked", type: "bool" }, { internalType: "uint112", name: "stake", type: "uint112" }, { internalType: "uint32", name: "unstakeDelaySec", type: "uint32" }, { internalType: "uint48", name: "withdrawTime", type: "uint48" } ], stateMutability: "view", type: "function" }, { inputs: [ { internalType: "address", name: "account", type: "address" } ], name: "getDepositInfo", outputs: [ { components: [ { internalType: "uint256", name: "deposit", type: "uint256" }, { internalType: "bool", name: "staked", type: "bool" }, { internalType: "uint112", name: "stake", type: "uint112" }, { internalType: "uint32", name: "unstakeDelaySec", type: "uint32" }, { internalType: "uint48", name: "withdrawTime", type: "uint48" } ], internalType: "struct IStakeManager.DepositInfo", name: "info", type: "tuple" } ], stateMutability: "view", type: "function" }, { inputs: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint192", name: "key", type: "uint192" } ], name: "getNonce", outputs: [ { internalType: "uint256", name: "nonce", type: "uint256" } ], stateMutability: "view", type: "function" }, { inputs: [ { internalType: "bytes", name: "initCode", type: "bytes" } ], name: "getSenderAddress", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation", name: "userOp", type: "tuple" } ], name: "getUserOpHash", outputs: [ { internalType: "bytes32", name: "", type: "bytes32" } ], stateMutability: "view", type: "function" }, { inputs: [ { components: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation[]", name: "userOps", type: "tuple[]" }, { internalType: "contract IAggregator", name: "aggregator", type: "address" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct IEntryPoint.UserOpsPerAggregator[]", name: "opsPerAggregator", type: "tuple[]" }, { internalType: "address payable", name: "beneficiary", type: "address" } ], name: "handleAggregatedOps", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation[]", name: "ops", type: "tuple[]" }, { internalType: "address payable", name: "beneficiary", type: "address" } ], name: "handleOps", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "uint192", name: "key", type: "uint192" } ], name: "incrementNonce", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "bytes", name: "callData", type: "bytes" }, { components: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "uint256", name: "verificationGasLimit", type: "uint256" }, { internalType: "uint256", name: "callGasLimit", type: "uint256" }, { internalType: "uint256", name: "paymasterVerificationGasLimit", type: "uint256" }, { internalType: "uint256", name: "paymasterPostOpGasLimit", type: "uint256" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "address", name: "paymaster", type: "address" }, { internalType: "uint256", name: "maxFeePerGas", type: "uint256" }, { internalType: "uint256", name: "maxPriorityFeePerGas", type: "uint256" } ], internalType: "struct EntryPoint.MemoryUserOp", name: "mUserOp", type: "tuple" }, { internalType: "bytes32", name: "userOpHash", type: "bytes32" }, { internalType: "uint256", name: "prefund", type: "uint256" }, { internalType: "uint256", name: "contextOffset", type: "uint256" }, { internalType: "uint256", name: "preOpGas", type: "uint256" } ], internalType: "struct EntryPoint.UserOpInfo", name: "opInfo", type: "tuple" }, { internalType: "bytes", name: "context", type: "bytes" } ], name: "innerHandleOp", outputs: [ { internalType: "uint256", name: "actualGasCost", type: "uint256" } ], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "address", name: "", type: "address" }, { internalType: "uint192", name: "", type: "uint192" } ], name: "nonceSequenceNumber", outputs: [ { internalType: "uint256", name: "", type: "uint256" } ], stateMutability: "view", type: "function" }, { inputs: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation", name: "op", type: "tuple" }, { internalType: "address", name: "target", type: "address" }, { internalType: "bytes", name: "targetCallData", type: "bytes" } ], name: "simulateCallData", outputs: [ { components: [ { internalType: "uint256", name: "gasUsed", type: "uint256" }, { internalType: "bool", name: "success", type: "bool" }, { internalType: "bytes", name: "returnData", type: "bytes" } ], internalType: "struct IEntryPointSimulations.TargetCallResult", name: "", type: "tuple" } ], stateMutability: "nonpayable", type: "function" }, { inputs: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation", name: "op", type: "tuple" } ], name: "simulateHandleOp", outputs: [ { components: [ { internalType: "uint256", name: "preOpGas", type: "uint256" }, { internalType: "uint256", name: "paid", type: "uint256" }, { internalType: "uint256", name: "accountValidationData", type: "uint256" }, { internalType: "uint256", name: "paymasterValidationData", type: "uint256" }, { internalType: "bool", name: "targetSuccess", type: "bool" }, { internalType: "bytes", name: "targetResult", type: "bytes" } ], internalType: "struct IEntryPointSimulations.ExecutionResult", name: "", type: "tuple" } ], stateMutability: "nonpayable", type: "function" }, { inputs: [ { components: [ { internalType: "address", name: "sender", type: "address" }, { internalType: "uint256", name: "nonce", type: "uint256" }, { internalType: "bytes", name: "initCode", type: "bytes" }, { internalType: "bytes", name: "callData", type: "bytes" }, { internalType: "bytes32", name: "accountGasLimits", type: "bytes32" }, { internalType: "uint256", name: "preVerificationGas", type: "uint256" }, { internalType: "bytes32", name: "gasFees", type: "bytes32" }, { internalType: "bytes", name: "paymasterAndData", type: "bytes" }, { internalType: "bytes", name: "signature", type: "bytes" } ], internalType: "struct PackedUserOperation", name: "userOp", type: "tuple" } ], name: "simulateValidation", outputs: [ { components: [ { components: [ { internalType: "uint256", name: "preOpGas", type: "uint256" }, { internalType: "uint256", name: "prefund", type: "uint256" }, { internalType: "uint256", name: "accountValidationData", type: "uint256" }, { internalType: "uint256", name: "paymasterValidationData", type: "uint256" }, { internalType: "bytes", name: "paymasterContext", type: "bytes" } ], internalType: "struct IEntryPoint.ReturnInfo", name: "returnInfo", type: "tuple" }, { components: [ { internalType: "uint256", name: "stake", type: "uint256" }, { internalType: "uint256", name: "unstakeDelaySec", type: "uint256" } ], internalType: "struct IStakeManager.StakeInfo", name: "senderInfo", type: "tuple" }, { components: [ { internalType: "uint256", name: "stake", type: "uint256" }, { internalType: "uint256", name: "unstakeDelaySec", type: "uint256" } ], internalType: "struct IStakeManager.StakeInfo", name: "factoryInfo", type: "tuple" }, { components: [ { internalType: "uint256", name: "stake", type: "uint256" }, { internalType: "uint256", name: "unstakeDelaySec", type: "uint256" } ], internalType: "struct IStakeManager.StakeInfo", name: "paymasterInfo", type: "tuple" }, { components: [ { internalType: "address", name: "aggregator", type: "address" }, { components: [ { internalType: "uint256", name: "stake", type: "uint256" }, { internalType: "uint256", name: "unstakeDelaySec", type: "uint256" } ], internalType: "struct IStakeManager.StakeInfo", name: "stakeInfo", type: "tuple" } ], internalType: "struct IEntryPoint.AggregatorStakeInfo", name: "aggregatorInfo", type: "tuple" } ], internalType: "struct IEntryPointSimulations.ValidationResult", name: "", type: "tuple" } ], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "bytes4", name: "interfaceId", type: "bytes4" } ], name: "supportsInterface", outputs: [ { internalType: "bool", name: "", type: "bool" } ], stateMutability: "view", type: "function" }, { inputs: [], name: "unlockStake", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "address payable", name: "withdrawAddress", type: "address" } ], name: "withdrawStake", outputs: [], stateMutability: "nonpayable", type: "function" }, { inputs: [ { internalType: "address payable", name: "withdrawAddress", type: "address" }, { internalType: "uint256", name: "withdrawAmount", type: "uint256" } ], name: "withdrawTo", outputs: [], stateMutability: "nonpayable", type: "function" }, { stateMutability: "payable", type: "receive" } ], devdoc: { errors: { "FailedOp(uint256,string)": [ { params: { opIndex: "- Index into the array of ops to the failed one (in simulateValidation, this is always zero).", reason: '- Revert reason. The string starts with a unique code "AAmn", where "m" is "1" for factory, "2" for account and "3" for paymaster issues, so a failure can be attributed to the correct entity.' } } ], "FailedOpWithRevert(uint256,string,bytes)": [ { details: "note that inner is truncated to 2048 bytes", params: { inner: "- data from inner cought revert reason", opIndex: "- Index into the array of ops to the failed one (in simulateValidation, this is always zero).", reason: "- Revert reason. see FailedOp(uint256,string), above" } } ], "ReentrancyGuardReentrantCall()": [ { details: "Unauthorized reentrant call." } ], "SignatureValidationFailed(address)": [ { params: { aggregator: "The aggregator that failed to verify the signature" } } ] }, events: { "AccountDeployed(bytes32,address,address,address)": { params: { factory: "- The factory used to deploy this account (in the initCode)", paymaster: "- The paymaster used by this UserOp", sender: "- The account that is deployed", userOpHash: "- The userOp that deployed this account. UserOperationEvent will follow." } }, "PostOpRevertReason(bytes32,address,uint256,bytes)": { params: { nonce: "- The nonce used in the request.", revertReason: '- The return bytes from the (reverted) call to "callData".', sender: "- The sender of this request.", userOpHash: "- The request unique identifier." } }, "SignatureAggregatorChanged(address)": { params: { aggregator: "- The aggregator used for the following UserOperationEvents." } }, "UserOperationPrefundTooLow(bytes32,address,uint256)": { params: { nonce: "- The nonce used in the request.", sender: "- The sender of this request.", userOpHash: "- The request unique identifier." } }, "UserOperationRevertReason(bytes32,address,uint256,bytes)": { params: { nonce: "- The nonce used in the request.", revertReason: '- The return bytes from the (reverted) call to "callData".', sender: "- The sender of this request.", userOpHash: "- The request unique identifier." } } }, kind: "dev", methods: { "addStake(uint32)": { params: { unstakeDelaySec: "The new lock duration before the deposit can be withdrawn." } }, "balanceOf(address)": { params: { account: "- The account to query." }, returns: { _0: "- The deposit (for gas payment) of the account." } }, "delegateAndRevert(address,bytes)": { details: "calling this method, the EntryPoint will make a delegatecall to the given data, and report (via revert) the result. The method always revert, so is only useful off-chain for dry run calls, in cases where state-override to replace actual EntryPoint code is less convenient.", params: { data: "data to pass to target in a delegatecall", target: "a target contract to make a delegatecall from entrypoint" } }, "getDepositInfo(address)": { params: { account: "- The account to query." }, returns: { info: " - Full deposit information of given account." } }, "getNonce(address,uint192)": { params: { key: "the high 192 bit of the nonce", sender: "the account address" }, returns: { nonce: "a full nonce to pass for next UserOp with this sender." } }, "getSenderAddress(bytes)": { params: { initCode: "- The constructor code to be passed into the UserOperation." } }, "getUserOpHash((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { params: { userOp: "- The user operation to generate the request ID for." }, returns: { _0: "hash the hash of this UserOperation" } }, "handleAggregatedOps(((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes)[],address,bytes)[],address)": { params: { beneficiary: "- The address to receive the fees.", opsPerAggregator: "- The operations to execute, grouped by aggregator (or address(0) for no-aggregator accounts)." } }, "handleOps((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes)[],address)": { params: { beneficiary: "- The address to receive the fees.", ops: "- The operations to execute." } }, "innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)": { params: { callData: "- The callData to execute.", context: "- The context bytes.", opInfo: "- The UserOpInfo struct." }, returns: { actualGasCost: "- the actual cost in eth this UserOperation paid for gas" } }, "simulateHandleOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { params: { op: "The UserOperation to simulate." }, returns: { _0: "the execution result structure" } }, "simulateValidation((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { details: "The node must also verify it doesn't use banned opcodes, and that it doesn't reference storage outside the account's data.", params: { userOp: "- The user operation to validate." }, returns: { _0: "the validation result structure" } }, "supportsInterface(bytes4)": { details: "Returns true if this contract implements the interface defined by `interfaceId`. See the corresponding https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] to learn more about how these ids are created. This function call must use less than 30 000 gas." }, "withdrawStake(address)": { params: { withdrawAddress: "- The address to send withdrawn value." } }, "withdrawTo(address,uint256)": { params: { withdrawAddress: "- The address to send withdrawn value.", withdrawAmount: "- The amount to withdraw." } } }, version: 1 }, userdoc: { errors: { "FailedOp(uint256,string)": [ { notice: "A custom revert error of handleOps, to identify the offending op. Should be caught in off-chain handleOps simulation and not happen on-chain. Useful for mitigating DoS attempts against batchers or for troubleshooting of factory/account/paymaster reverts. NOTE: If simulateValidation passes successfully, there should be no reason for handleOps to fail on it." } ], "FailedOpWithRevert(uint256,string,bytes)": [ { notice: "A custom revert error of handleOps, to report a revert by account or paymaster." } ], "SignatureValidationFailed(address)": [ { notice: "Error case when a signature aggregator fails to verify the aggregated signature it had created." } ] }, events: { "AccountDeployed(bytes32,address,address,address)": { notice: 'Account "sender" was deployed.' }, "BeforeExecution()": { notice: "An event emitted by handleOps(), before starting the execution loop. Any event emitted before this event, is part of the validation." }, "PostOpRevertReason(bytes32,address,uint256,bytes)": { notice: `An event emitted if the UserOperation Paymaster's "postOp" call reverted with non-zero length.` }, "SignatureAggregatorChanged(address)": { notice: "Signature aggregator used by the following UserOperationEvents within this bundle." }, "UserOperationPrefundTooLow(bytes32,address,uint256)": { notice: "UserOp consumed more than prefund. The UserOperation is reverted, and no refund is made." }, "UserOperationRevertReason(bytes32,address,uint256,bytes)": { notice: 'An event emitted if the UserOperation "callData" reverted with non-zero length.' } }, kind: "user", methods: { "addStake(uint32)": { notice: "Add to the account's stake - amount and delay any pending unstake is first cancelled." }, "balanceOf(address)": { notice: "Get account balance." }, constructor: { notice: "simulation contract should not be deployed, and specifically, accounts should not trust it as entrypoint, since the simulation functions don't check the signatures Edit (Leo Vigna): Actually it SHOULD be deployed now that EntryPointV07 is designed for modular gas estimations without the need for state overrides thanks to the addition of `delegateAndRevert` to the EntryPoint contract. The change below is from the alto bundler contract but comments were not updated to reflect this. Also see bottom section (\"What's new v0.7\") in this article for more info https://blog.smart-contracts-developer.com/entrypoint-v0-7-0-the-new-era-of-account-abstraction-854f9f82912e" }, "delegateAndRevert(address,bytes)": { notice: "Helper method for dry-run testing." }, "deposits(address)": { notice: "maps paymaster to their deposits and stakes" }, "getDepositInfo(address)": { notice: "Get deposit info." }, "getNonce(address,uint192)": { notice: "Return the next nonce for this sender. Within a given key, the nonce values are sequenced (starting with zero, and incremented by one on each userop) But UserOp with different keys can come with arbitrary order." }, "getSenderAddress(bytes)": { notice: "Get counterfactual sender address. Calculate the sender contract address that will be generated by the initCode and salt in the UserOperation. This method always revert, and returns the address in SenderAddressResult error" }, "getUserOpHash((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { notice: "Generate a request Id - unique identifier for this request. The request ID is a hash over the content of the userOp (except the signature), the entrypoint and the chainid." }, "handleAggregatedOps(((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes)[],address,bytes)[],address)": { notice: "Execute a batch of UserOperation with Aggregators" }, "handleOps((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes)[],address)": { notice: "Execute a batch of UserOperations. No signature aggregator is used. If any account requires an aggregator (that is, it returned an aggregator when performing simulateValidation), then handleAggregatedOps() must be used instead." }, "incrementNonce(uint192)": { notice: 'Manually increment the nonce of the sender. This method is exposed just for completeness.. Account does NOT need to call it, neither during validation, nor elsewhere, as the EntryPoint will update the nonce regardless. Possible use-case is call it with various keys to "initialize" their nonces to one, so that future UserOperations will not pay extra for the first transaction with a given key.' }, "innerHandleOp(bytes,((address,uint256,uint256,uint256,uint256,uint256,uint256,address,uint256,uint256),bytes32,uint256,uint256,uint256),bytes)": { notice: 'Inner function to handle a UserOperation. Must be declared "external" to open a call context, but it can only be called by handleOps.' }, "nonceSequenceNumber(address,uint192)": { notice: "The next valid sequence number for a given nonce key." }, "simulateHandleOp((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { notice: "Simulate full execution of a UserOperation (including both validation and target execution) It performs full validation of the UserOperation, but ignores signature error. An optional target address is called after the userop succeeds, and its value is returned (before the entire call is reverted). Note that in order to collect the the success/failure of the target call, it must be executed with trace enabled to track the emitted events." }, "simulateValidation((address,uint256,bytes,bytes,bytes32,uint256,bytes32,bytes,bytes))": { notice: "Simulate a call to account.validateUserOp and paymaster.validatePaymasterUserOp." }, "unlockStake()": { notice: "Attempt to unlock the stake. The value can be withdrawn (using withdrawStake) after the unstake delay." }, "withdrawStake(address)": { notice: "Withdraw from the (unlocked) stake. Must first call unlockStake and wait for the unstakeDelay to pass." }, "withdrawTo(address,uint256)": { notice: "Withdraw from the deposit." } }, ve