# Integrate a batch into a Hook using Squid

Now that you have your encoded batch call made of several encoded subcall data, you can easily add the full encoded batch data to a Hook using Squid SDK.

This is doable by adding a `postHook` or `preHooks` parameter to the route object passed to Squid.

```javascript
         postHook: {
            chainType: "evm",
            calls: [
              {
                chainType: "evm",
                callType: 2,
                target: batchAddress, // 0x0000000000000000000000000000000000000808
                value: "0", // this will be replaced by the full native balance of the multicall after the swap
                callData: batchEncodedData,
                payload: {
                  tokenAddress: "0xAcc15dC74880C9944775448304B263D191c6077F",
                  inputPos: 0, // unused
                },
                estimatedGas: "150000",
              },
```

By using this technique, you can do multiple calls before bridging to any EVM chain (preHook) and after bridging from any EVM chain to Moonbeam (postHook).


---

# 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://jungle-toolkit.gitbook.io/evm-xcm-jungle-toolkit/build-batches-on-source-and-destination-chains-using-squid-and-batch-precompile/integrate-a-batch-into-a-hook-using-squid.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.
