Bundler API

What is a bundler

A Bundler, as introduced by ERC-4337, is a pivotal infrastructure component enabling account abstraction on Ethereum Virtual Machine (EVM) networks.

Its core function is to manage a mempool of User Operations (UserOps), aggregating them and submitting them to an Entry Point Contract for on-chain execution.

This process involves a decentralized, permissionless peer-to-peer network of bundlers, ensuring that UserOps are validated and compliant with rigorous security protocols designed to prevent various attack vectors, including Denial of Service (DoS) attacks.

Endpoints

We support multiple chains for the bundler service, you just need to modify the chainId and apiKey to your network. Here the list of our current supported networks.

URL

https://bundler.cometh.io/CHAIN_ID?apikey=API_KEY

Example for Arbitrum Sepolia : https://bundler.cometh.io/421614?apikey=API_KEY

Bundler RPC Method

Here are all the available methods for a Bundler in the context of ERC-4337. Each method facilitates the submission, gas estimation, retrieval of information, and management of User Operations (UserOps) efficiently and securely on the Ethereum network.

  1. eth_sendUserOperation: This method submits a User Operation (UserOp) to the mempool. If the operation is accepted, it returns a userOpHash. If unsuccessful, it returns an error. This ensures that UserOps are included in the blockchain network for execution.

  2. eth_estimateUserOperationGas : Estimates the gas values required for a given User Operation, including PreVerificationGas, VerificationGas, and CallGasLimit. It can also simulate different states using optional state overrides, making it useful for scenarios where precise gas estimation is needed without actual execution.

  3. eth_getUserOperationByHash: Retrieves a User Operation and its transaction context based on a given userOpHash. Provides detailed information about the UserOp, including its status and related transaction details.

  4. eth_getUserOperationReceipt: Fetches the receipt of a User Operation based on a given userOpHash. The receipt includes metadata and the final status of the UserOp, such as whether it was successfully executed and any logs generated during its execution.

  5. eth_supportedEntryPoints: Returns an array of supported EntryPoint addresses as specified in the configuration. The first element in the array is the preferred EntryPoint of the bundler. This helps in identifying which EntryPoints can be used for submitting UserOps.

Last updated