# Batched transactions

Authereum supported batched transactions right out of the box. This means that you can send an array of transactions and they will all get processed in 1 single transaction. Authereum batched transactions are also atomic meaning that all transactions in the batch must succeed, otherwise if any of the batched transactions fails then they are all cancelled.&#x20;

For example, a common series of transaction is an `approve` and `transfer` call with ERC20 tokens. With batched transactions you can approve and transfer in a single transaction. If the approve call fails then the transfer call won't happen since the transaction before it failed. If the approve succeeds but the transfer fails then approve call is reverted and cancelled. If the approve succeeds and transfer succeeds then the entire transaction is successful.

In order to estimate the gas for a batched transaction, you can call `estimateGasBatch` on the provider. This will return an array of numbers that represent the estimated gas, one for each transaction in the batch.

To learn how to implement batched transactions with the web3 provider, check out the documentation link below:

{% content-ref url="/pages/-Lu-Yjsb12c254kb1gy\_" %}
[Web3 provider](/web3-provider.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.authereum.com/batched-transactions.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
