# Particle Bundler Source: https://developers.particle.network/aa/architecture/bundler Particle Network's Bundler is now fully open-source! *** An ERC-4337 Bundler acts as a transaction aggregator that collects individual `UserOperations` from a specialized mempool, bundles them, and submits them as a single transaction to the network. This enables enhanced account abstraction on Ethereum and other EVM networks. It is a core infrastructure component for account abstraction on Ethereum Virtual Machine (EVM) networks. The Particle Bundler is a specialized tool designed to make smart contracts and transactions work smoothly using the ERC-4337 standard. It is a fully compliant, feature-rich, high-performance, infinitely scalable 4337 Bundler implementation. ## Advantages of the Particle Bundler Particle's Bundler offers several compelling advantages: * **Seamless `UserOperations`:** We have implemented the persistence of `UserOperations`, Smart Account Nonce management, and automatic batch sending of `UserOperations`, among other features. The Particle Bundler simplifies the transaction process for users, streamlining the submission of `UserOperations`. This enhances the accessibility of ERC-4337, making it more user-friendly and approachable for a broader audience. * **Smart Ops:** We know the importance of stable and reliable operational features for developers, so we have implemented functionalities like Bundler Signer configuration, automatic recharging, automatic blocking and recovery, and automatic monitoring alerts, enabling easy management and automatic expansion. The era of multi-chain Web3 is still unfolding, so we have simplified the deployment process to new chains down to executing a single command with minimum additional configurations. Thanks to this, support for a new chain can be completed within 5 minutes. * **High Performance:** Particle's Bundler is engineered for optimal performance and can efficiently handle demanding workloads. Leveraging proprietary technology and optimization techniques, the Bundler ensures transactions are processed swiftly and effectively. * **High Stability:** Stability is a hallmark feature of Particle's Bundler. Built with reliability in mind, it operates seamlessly, even under challenging conditions. Its robust architecture and adherence to best practices in infrastructure management contribute to its exceptional stability, providing users and developers with a dependable platform to solve their needs. As a high-performance, highly stable Bundler implementation, the Bundler also features: ## Features * All standard RPCs supported. * Configurable RPCs, Signers, etc. * Support for any chain. * `UserOp` Persistence. * `UserOp` Concurrent Handling. * Built-in Gas Price Oracle. * Multi-Bundler Signers Manager. * Auto-fulfill bundler Signers’ balance. * Auto-retry for failed transactions from a Bundler Signer account. * Returns the correct transaction even when affected by MEV. * Deploy new chains with one command. Learn more through the [open-source repository](https://github.com/Particle-Network/particle-bundler-server). # Omnichain Paymaster Source: https://developers.particle.network/aa/architecture/omni-paymaster Our proprietary Paymaster allows developers to recharge and spend across different chains. *** Particle Network’s Paymaster is a specialized tool designed to make gas payments easier and friendlier for end users across chains, leveraging Particle Network's Omnichain Account Abstraction design. This service, which has helped us sponsor over 500k `UserOperations` across different networks in the previous month, is already fully integrated with Particle’s Wallet as a Service (WaaS). ## Advantages of the Particle Paymaster Particle's Paymaster offers several compelling advantages, making it a powerful component of the Omnichain AA ecosystem: * **Multi-chain usage:** Once developers deposit USDT, they can sponsor UserOps on every EVM-compatible chain. * **Adaptable sponsorship logic using Webhooks:** Configuring webhooks allows developers to accurately control which UserOP can be accepted by the cross-chain Paymaster * **Monitoring:** Developers are able to monitor every UserOp they sponsored. * **Expiration times:** Developers can define an expiration time for the Paymaster signature. Once the UserOperation reaches its expiration, the Paymaster signature will automatically lapse. ## How to use 1. Use [Particle Network's AA SDKs](/aa/sdks/desktop/web.mdx), Particle's Paymaster will be automatically included, and no extra configuration is needed; 2. Use [Particle Paymaster's RPC](/aa/paymaster) directly to plug the multi-chain paymaster in your AA project. ## Webhooks Configuring webhooks allows developers to accurately control which UserOP can be accepted by the Paymaster. We use two types of webhooks: 1. Before the Paymaster signs— `before_paymaster_sign`. 2. After the Paymaster signs— `after_paymaster_sign`. Every time a Webhook request is made, a signature for the body is generated, which developers can verify to determine whether the request was sent by Particle Network. A unique public and private key (RSA-2048) is generated for each project. This key can be downloaded from the users’ [Particle dashboard page](https://dashboard.particle.network/#/login) for verification.
Webhooks in the Particle Network dashboard. Webhooks in the Particle Network dashboard.
### Webhook: `before_paymaster_sign` This hook will be triggered before the Paymaster signs. The Paymaster will determine whether to sign the UserOP based on the status code returned by the Hook. It includes: * Body * `chainId` * `UserOp` - UserOperation struct. * `entryPoint` - The entryPoint address. * `parsed` - Transaction struct. The Paymaster will attempt to parse the calldata of the UserOP. If it cannot be parsed, this field may not exist. * Response\ If the status code of the response returned is 200, then the Paymaster will accept the UserOP and sign it. ### Webhook: `after_paymaster_sign` This hook will trigger after the Paymaster signs. It includes: * Body * `chainId` * `UserOp` - UserOperation struct. * `entryPoint` - The entryPoint address. * `parsed` - Transaction struct. The Paymaster will attempt to parse the calldata of the `UserOP`. If it cannot be parsed, this field may not exist. Find a guide on how to implement webhooks in [Paymaster guidance](/aa/guides/paymaster#conditional-sponsorship-webhooks). ### Whitelist Smart Contract Developers can configure a whitelist of contract methods they want to sponsor in the backend. This means that after configuration, our server will only provide the Paymaster’s signature for the specified contract methods. Whitelist Smart Contracts for Paymaster on Dashbaord ## Sponsorship Policy The simplest way is to configure a whitelist of contract methods to sponsor. However, using Webhooks provides more flexibility, allowing for unlimited sponsorship strategies through any programmatic logic. Developers can use Webhooks to implement any sponsorship logic they wish in conjunction with the Paymaster. For the `before_paymaster_sign` webhook, we return all the data necessary: * projectUuid * chainId * `UserOp` * and parsed data: * accountType: BICONOMY, CYBERCONNECT, SIMPLE * txs * Any policy * You can use chainId to decide which chains you want to sponsor. * You can use `UserOp` to decide which user address(sender) you want to sponsor. * You can use `UserOp` to calculate the gas fee and decide whether to sponsor or not. * You can use the accountType and txs to use them as a smart contract whitelist or blacklist. This allows, for example, for the following business scenarios: * A GameFi project to allow every new user to mint a game NFT gaslessly. * A financial platform can sponsor gas for every deposit, so their users don't need to learn the concept of gas. * An NFT platform can enable users to trade NFTs without gas, using their own fees to cover gas. In many cases, programmatic sponsorship policies can be used and adapted to create a friendly experience and simplify experiences where it matters most. To learn more about Particle's Account Abstraction Stack, head over to the relevant [AA SDK reference pages](/aa/introduction). # estimateUserOperationGas Source: https://developers.particle.network/aa/bundler/estimateuseroperationgas openapi-bundler POST /#eth_estimateUserOperationGas Learn how to use the estimateUserOperationGas JSON-RPC method. ## Understanding `estimateUserOperationGas` * `estimateUserOperationGas` takes a partial UserOperation object and returns detailed gas estimates to be used in continued UserOperation construction. It takes: * Partial user operation object: * `sender` - string. * `nonce` - string. * `initCode` - string. * `callData` - string. * `signature` - string.`signature` can be a dummy string, such as `0xfffffffffffffffffffffffffffffff0000000000000000000000000000000007aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa1c`. * `entrypointAddress` - string. *** ## Query example ```json JSON theme={null} { "method": "eth_estimateUserOperationGas", "params": [ // partial user operation { "sender": "0x8fb859e944561678be40cdd2db16551396c0b074", "nonce": "0x0152", "initCode": "0x", "callData": "0x9e5d4c49000000000000000000000000329a7f8b91ce7479035cb1b5d62ab41845830ce8000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000", "signature": "0x73c3ac716c487ca34bb858247b5ccf1dc354fbaabdd089af3b2ac8e78ba85a4959a2d76250325bd67c11771c31fccda87c33ceec17cc0de912690521bb95ffcb1b" }, "0x5ff137d4b0fdcd49dca30c7cf57e578a026d2789" ], "id": 1695717515, "jsonrpc": "2.0", "chainId": 80001 } ``` # getUserOperationByHash Source: https://developers.particle.network/aa/bundler/getuseroperationbyhash openapi-bundler POST /#eth_getUserOperationByHash Learn how to use the getUserOperationByHash JSON-RPC method. ## Understanding `getUserOperationByHash` * `getUserOperationByHash` returns a UserOperation object corresponding with a specific hash. It takes: * `hash` - string. *** ## Query example ```json JSON theme={null} { "method": "eth_getUserOperationByHash", "params": [ // user operation hash "0x1ee478a6e967c407e8dfb5e3f2eb1131a7418c36396147fce1f7e81a871102a3" ], "id": 1695717473, "jsonrpc": "2.0", "chainId": 80001 } ``` # getUserOperationReceipt Source: https://developers.particle.network/aa/bundler/getuseroperationreceipt openapi-bundler POST /#eth_getUserOperationReceipt Learn how to use the getUserOperationReceipt JSON-RPC method. ## Understanding `getUserOperationReceipt` * `getUserOperationReceipt` returns a detailed object containing specific transaction details for a given user operation hash. It takes: * `hash` - string. *** ## Query example ```json JSON theme={null} { "method": "eth_getUserOperationReceipt", "params": [ // user operation hash "0x1ee478a6e967c407e8dfb5e3f2eb1131a7418c36396147fce1f7e81a871102a3" ], "id": 1695717473, "jsonrpc": "2.0", "chainId": 80001 } ``` # sendUserOperation Source: https://developers.particle.network/aa/bundler/senduseroperation openapi-bundler POST /#eth_sendUserOperation Learn how to use the sendUserOperation JSON-RPC method. ## Contextualizing `sendUserOperation` * `sendUserOperation` pushes a signed UserOperation to the network, in this case through the Particle Bundler. It takes: * UserOperation object. * `entrypointAddress` - string. *** ## Query example ```json JSON theme={null} { "method": "eth_sendUserOperation", "params": [ // user operation { "sender": "0x8Fb859E944561678be40Cdd2dB16551396c0b074", "nonce": "0x0150", "initCode": "0x", "callData": "0x9e5d4c49000000000000000000000000329a7f8b91ce7479035cb1b5d62ab41845830ce8000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000", "callGasLimit": "0xa13c", "verificationGasLimit": "0xe2d8", "maxFeePerGas": "0x7ca702cd", "maxPriorityFeePerGas": "0x7ca702b0", "paymasterAndData": "0x000031dd6d9d3a133e663660b959162870d755d4000000000000000000000000329a7f8b91ce7479035cb1b5d62ab41845830ce8000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000416665636080709b968ebec098bf71fb0e79b3b480cc9ff809f192afb478c84ec50ad2de74b93a67860542099b11a1b5dbfa9bc21a2790c58e10015ce992a02f411b00000000000000000000000000000000000000000000000000000000000000", "preVerificationGas": "0x011120", "signature": "0x7cc0a2ae350b79c5b189bd36d55ab6a2756097d6d37537e3ec2c26daaa82c6d909fed87ff9d79a6fa127bd798126259ee72fa9395ecbeb1f70ed22ca35983aea1c" }, // entrypoint contract address "0x5ff137d4b0fdcd49dca30c7cf57e578a026d2789" ], "id": 1695717470, "jsonrpc": "2.0", "chainId": 80001 } ``` # supportedEntryPoints Source: https://developers.particle.network/aa/bundler/supportedentrypoints openapi-bundler POST /#eth_supportedEntryPoints Learn how to use the supportedEntryPoints JSON-RPC method. ## Contextualizing `supportEntryPoints` * `supportEntryPoints` returns a list of EntryPoint addresses supported by the Particle Bundler. It takes no parameters. At the moment, only `0x5ff137d4b0fdcd49dca30c7cf57e578a026d2789` is supported due to it being the flagship EntryPoint contract for ERC-4337. *** ## Query example ```json JSON theme={null} { "chainId": 80001, "jsonrpc": "2.0", "id": 1, "method": "eth_supportedEntryPoints", "params": [] } ``` # Particle Account Abstraction FAQ Source: https://developers.particle.network/aa/faq Find Frequently Asked Questions about Particle Account Abstraction. **Answer:** Particle Network uses the Biconomy Paymaster to sponsor transactions using ERC-20 tokens for gas fees. To support new ERC-20 tokens, it is dependent on Biconomy's integration. The availability of a token for gas payments is determined by Biconomy's supported token list. For a complete list of supported ERC-20 tokens, please refer to the [Biconomy documentation](https://docs.biconomy.io/supportedNetworks#supported-tokens). **Answer:** You can fund the Paymaster by depositing **USDT** on either **Ethereum** or **BNB Chain** through the **Paymaster** menu on the **Particle Network Dashboard**. The choice of chain only affects the deposit origin, not the Paymaster’s functionality. Once deposited, USDT is converted to the native token of the target chain, enabling you to sponsor transactions on any supported EVM chain. To view the full list of supported EVM chains, head over to the [Network Coverage](/social-logins/network-coverage) page. No USDT deposit is needed for testnet sponsorship. **Answer:** The AA SDK currently doesn't offer native support for custom smart accounts. We support a select range of smart accounts: * **SimpleAccount**: `SIMPLE` * **Biconomy**: `BICONOMY` * **CyberConnect**: `CYBERCONNECT` * **Light**: `LIGHT` * **Coinbase**: `COINBASE` For more information on supported smart accounts and how to initialize them, visit the [AA SDK documentation](/aa/sdks/desktop/web#initialization). **Answer:** Yes, with Biconomy V2, you can use **session keys** to grant users the ability to conditionally delegate signing authority. This allows for the automation of transactions and the elimination of confirmation pop-ups, providing a smoother user experience. Learn more about implementing [Session Keys](/aa/guides/keys) in your application. **Answer:** Although our SDK doesn't natively support custom Bundlers, you can still create a `UserOperation` object using the SDK. Once constructed, this object can be executed via a standard API call to your own Bundler endpoint. For detailed guidance on creating and using `UserOperation` objects, check out our [API reference](/aa/rpc/createuserop). **Answer:** The AA SDK currently only supports Particle's native Paymaster, accessible via the [Particle Network Dashboard](https://dashboard.particle.network), and Biconomy's Paymaster. If you wish to use a custom Paymaster, you'll need to integrate it through a custom API in your application, sponsoring a `UserOperation` constructed by the AA SDK/API. After that, using our SDK, you can execute the resulting `UserOperation` (including `paymasterAndData` from your Paymaster). For more details on the available endpoints, visit the [AA APIs documentation](/aa/rpc/getsmartaccount). **Answer:** Each natively-supported smart account differs in feature-set (such as session keys, multi-chain signatures, and so on). Below is a table detailing the core differences between account types as it relates to the features they support. | Account Type | Session Keys | Transferable Signer | Multichain Signatures | Gasless Transactions | | ----------------------------------------------------------------------------------------------------------------------- | ------------ | ------------------- | --------------------- | -------------------- | | [Biconomy (V2)](https://github.com/bcnmy/scw-contracts/blob/main/contracts/smart-account/SmartAccount.sol) | ✓ | ✓ | ✓ | ✓ | | Biconomy (V1) | ✗ | ✗ | ✗ | ✓ | | [Light](https://github.com/alchemyplatform/light-account) | ✗ | ✓ | ✗ | ✓ | | [Coinbase](https://github.com/coinbase/coinbase-wallet-sdk) | ✗ | ✗ | ✗ | ✓ | | CyberConnect | ✗ | ✗ | ✗ | ✓ | | [SimpleAccount](https://github.com/eth-infinitism/account-abstraction/blob/develop/contracts/samples/SimpleAccount.sol) | ✗ | ✗ | ✗ | ✓ | For more information on the chains supported by each account type, head over to the [Network Coverage page](/social-logins/network-coverage). **Still need help?** [Open a ticket](https://t.me/particle_developer_bot) with Particle's Developer Relations team through the dedicated Telegram support bot. # Bundler Source: https://developers.particle.network/aa/guides/bundler # Particle Bundler The **Particle Bundler** is our open-source, production-ready ERC-4337 bundler.\ It has already processed **nearly 1M+ UserOperations** across the EVM ecosystem and powers some of the largest AA campaigns in Web3. * Free to use via a public RPC: `https://bundler.particle.network` * Automatically included in all Particle AA SDKs * Proven to scale and battle-tested in live campaigns Explore the [Particle Bundler repository](https://github.com/Particle-Network/particle-bundler-server). *** ## Why use the Particle Bundler? * **Open-source & free** — no lock-in, use it standalone or with our SDKs * **Production-grade** — tested at scale with millions of UserOps * **Full RPC support** — standard bundler methods available out of the box * **Multi-chain ready** — live on every chain supported by Particle’s Smart Wallet-as-a-Service *** ## Available RPC Methods The Bundler RPC endpoint: [https://bundler.particle.network/\{chainId?}](https://bundler.particle.network/\{chainId?}) Supported methods (no auth required): * `eth_supportedEntryPoints` * `eth_estimateUserOperationGas` * `eth_sendUserOperation` * `eth_getUserOperationByHash` * `eth_getUserOperationReceipt` Example request: ```json JSON [expandable] theme={null} { "method": "eth_sendUserOperation", "params": [ { "sender": "0x8Fb859E944561678be40Cdd2dB16551396c0b074", "nonce": "0x0150", "initCode": "0x", "callData": "0x9e5d4c49000000000000000000000000329a7f8b91ce7479035cb1b5d62ab41845830ce8000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000", "callGasLimit": "0xa13c", "verificationGasLimit": "0xe2d8", "maxFeePerGas": "0x7ca702cd", "maxPriorityFeePerGas": "0x7ca702b0", "paymasterAndData": "0x000031dd6d9d3a133e663660b959162870d755d4000000000000000000000000329a7f8b91ce7479035cb1b5d62ab41845830ce8000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000416665636080709b968ebec098bf71fb0e79b3b480cc9ff809f192afb478c84ec50ad2de74b93a67860542099b11a1b5dbfa9bc21a2790c58e10015ce992a02f411b00000000000000000000000000000000000000000000000000000000000000", "preVerificationGas": "0x011120", "signature": "0x7cc0a2ae350b79c5b189bd36d55ab6a2756097d6d37537e3ec2c26daaa82c6d909fed87ff9d79a6fa127bd798126259ee72fa9395ecbeb1f70ed22ca35983aea1c" }, "0x5ff137d4b0fdcd49dca30c7cf57e578a026d2789" ], "id": 1695717470, "jsonrpc": "2.0", "chainId": 80001 } ``` ### Supported Chains The Particle Bundler supports all chains available in Smart Wallet-as-a-Service. 👉 For the full list, see [Network Coverage](/social-logins/network-coverage). ### Interactive Examples You can try Bundler methods directly in our docs: ``` ``` # Session Keys Source: https://developers.particle.network/aa/guides/keys How to use session keys with Particle’s Account Abstraction SDKs and RPC. # Session Keys **Session keys** let you delegate signing permissions under specific conditions to a temporary keypair. With session keys, your app can: * Allow users to interact without constant signature popups * Enable short-term delegated permissions * Automate transactions safely under defined rules Particle Network supports session keys through both the [AA SDKs](/aa/introduction) and the [Account Abstraction RPC](/aa/rpc/getsmartaccount). Currently supported only on the **Biconomy v2.0.0 smart account implementation**. Other smart account types will throw errors. *** ## How It Works The session key flow has two main parts: 1. **Create & register the session** * Generate a temporary keypair (session key). * Define metadata (`sessionKeyData`) including: * Session key address (temporary public key) * Linked user address * Permission parameters (limits, scope, etc.) * Deploy or configure a **`sessionValidationModule`** contract to validate `UserOps`. * Register the session on-chain. 2. **Use the session key** * `UserOps` can now be signed by the session key instead of the primary wallet. * The validation module ensures only authorized operations go through. 👉 Check out this [demo repo](https://github.com/TABASCOatw/particle-session-key-demo/blob/main/src/App.tsx) for a practical example. *** ## API & SDK Methods To work with session keys, use: * `createSessions` — create and register a new session * `validateSession` — validate that a `UserOperation` is authorized under the session Both are available in: * **AA SDKs** * **AA RPC** ([createSessions](/aa/rpc/createsessions), [validateSession](/aa/rpc/validatesession)) *** ## Example Validation Contract Here’s an example `sessionValidationModule` contract that implements `validateSessionUserOp`: ```solidity Solidity [expandable] theme={null} // SPDX-License-Identifier: MIT pragma solidity 0.8.19; import {UserOperation} from "@account-abstraction/contracts/interfaces/UserOperation.sol"; abstract contract ISessionValidationModule { // execute(address,uint256,bytes) bytes4 public constant EXECUTE_SELECTOR = 0xb61d27f6; // execute_ncC(address,uint256,bytes) bytes4 public constant EXECUTE_OPTIMIZED_SELECTOR = 0x0000189a; /** * @dev validates if the _op (UserOperation) matches the SessionKey permissions * and that _op has been signed by this SessionKey * @param _op User Operation to be validated. * @param _userOpHash Hash of the User Operation to be validated. * @param _sessionKeyData SessionKey data, that describes sessionKey permissions * @param _sessionKeySignature Signature over the the _userOpHash. * @return true if the _op is valid, false otherwise. */ function validateSessionUserOp( UserOperation calldata _op, bytes32 _userOpHash, bytes calldata _sessionKeyData, bytes calldata _sessionKeySignature ) external virtual returns (bool); } ``` ## Tutorial Video