Send atomic batch transactions
You can send and manage atomic batch transactions in MetaMask, using the methods specified by EIP-5792:
wallet_getCapabilities
- Query whether support for atomic batch transactions is available.wallet_sendCalls
- Submit multiple transactions to be processed atomically as one by the wallet.wallet_getCallsStatus
- Track the status of your transaction batch.
The key benefits of atomic batch transactions include:
- Fewer clicks and less friction - Users only need to review and approve a single wallet confirmation, instead of multiple confirmations.
- Faster completion times - Only a single atomic batch transaction must be confirmed onchain, instead of multiple individual transactions.
Steps
1. Query whether the wallet supports atomic batch
Important
If atomic batch is not supported, fall back to eth_sendTransaction
instead of wallet_sendCalls
,
and eth_getTransactionReceipt
instead of wallet_getCallsStatus
.