# parseFactoryAddressFromAccountInitCode | @aa-sdk/core

> Overview of the parseFactoryAddressFromAccountInitCode function from @aa-sdk/core

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

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

```ts
function parseFactoryAddressFromAccountInitCode(
  initCode,
): [`0x${string}`, `0x${string}`];
```

Defined in: [aa-sdk/core/src/account/smartContractAccount.ts:189](https://github.com/alchemyplatform/aa-sdk/blob/main/aa-sdk/core/src/account/smartContractAccount.ts#L189)

Parses the factory address and factory calldata from the provided account initialization code (initCode).

## Example

```ts
import { parseFactoryAddressFromAccountInitCode } from "@aa-sdk/core";

const [address, calldata] =
  parseFactoryAddressFromAccountInitCode("0xAddressCalldata");
```

## Parameters

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

  <tbody>
    <tr>
      <td>
        `initCode`
      </td>

      <td>
        `` `0x${string}` ``
      </td>

      <td>
        The initialization code from which to parse the factory address and calldata
      </td>
    </tr>

  </tbody>
</table>

## Returns

\[`` `0x${string}` ``, `` `0x${string}` ``]

A tuple containing the parsed factory address and factory calldata