# etherBalanceOf

Returns the ETH (native base layer currency) balance of a user managed by a wallet module.

## Usage

The following example creates an inspect request handler that assumes the `payload` is an user address and just prints the balance of that user to the console.

```ts twoslash
import { Rollup } from "@cartesi/rollup";
import { createWallet } from "@deroll/wallet";

// open the rollup device
const rollup = new Rollup();

// create wallet
const wallet = createWallet();

rollup.run({
    advance: wallet.handler,
    inspect: ({ payload }) => { // [!code focus]
        const address = payload.toString(); // [!code focus]
        const balance = wallet.etherBalanceOf(address); // [!code focus]
        console.log(balance); // [!code focus]
    }, // [!code focus]
});
```

## Returns

Type: `bigint`

The ETH balance of the given address.

## Parameters

Type: `string`

The address of the user to get the balance from.
