Skip to content
Alchemy Logo

prepareSign

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

Defined in: account-kit/wallet-client/src/client/actions/prepareSign.ts:40

Prepares a signature request for signing messages or transactions.

// Prepare a message to be signed
const result = await client.prepareSign({
  from: "0x1234...",
  type: "personal_sign",
  data: "Hello, world!",
});

Type ParameterDefault type

TAccount extends undefined | `0x${string}`

undefined | `0x${string}`

ParameterTypeDescription

client

InnerWalletApiClient

The wallet API client to use for the request

params

PrepareSignParams<TAccount>

Parameters for preparing the signature request

Promise<{ }>

A Promise that resolves to the prepare sign result containing a signature request

Was this page helpful?