# toModularAccountV2Base

> Overview of the toModularAccountV2Base function

> For the complete documentation index, see [llms.txt](/docs/llms.txt).

{/* This file is auto-generated by TypeDoc. Do not edit manually. */}

```ts
function toModularAccountV2Base<TTransport>(
  params,
): Promise<ModularAccountV2Base>;
```

Defined in: [packages/smart-accounts/src/ma-v2/accounts/base.ts:114](https://github.com/alchemyplatform/aa-sdk/blob/v5.x.x/packages/smart-accounts/src/ma-v2/accounts/base.ts#L114)

Creates a ModularAccountV2Base instance.

## Type Parameters

<table>
  <thead>
    <tr>
      <th align="left">Type Parameter</th>
      <th align="left">Default type</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `TTransport` *extends* [`Transport`](https://viem.sh)
      </td>

      <td>
        [`Transport`](https://viem.sh)
      </td>
    </tr>

  </tbody>
</table>

## Parameters

<table>
  <thead>
    <tr>
      <th align="left">Parameter</th>
      <th align="left">Type</th>
      <th align="left">Description</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `params`
      </td>

      <td>
        [`ToModularAccountV2BaseParams`](../type-aliases/ToModularAccountV2BaseParams)\<`TTransport`>
      </td>

      <td>
        The parameters for creating a ModularAccountV2Base instance.
      </td>
    </tr>

  </tbody>
</table>

## Returns

`Promise`\<[`ModularAccountV2Base`](../type-aliases/ModularAccountV2Base)>

A promise that resolves to a ModularAccountV2Base instance.