Skip to content
Alchemy Logo

listAccounts

function listAccounts(client, params): Promise<{}>;

Defined in: packages/wallet-apis/src/actions/listAccounts.ts:56

Lists all smart accounts for a given signer using the wallet API client.

// Fetch the first page of accounts
const firstPage = await client.listAccounts({
  signerAddress: "0x123...",
  limit: 10,
});
 
// If an 'after' cursor exists, use it to fetch the next page
const nextPage = await client.listAccounts({
  signerAddress: "0x123...",
  limit: 10,
  after: firstPage.meta.after,
});

ParameterTypeDescription

client

InnerWalletApiClient

The wallet API client to use for the request

params

Object

Parameters for listing accounts

Promise<{ }>

A Promise that resolves to the list of accounts and pagination metadata

Was this page helpful?