Skip to main content

UserWallet.recoverAddress() method

Recover the signing address from a signed message

Example

const message = "Sign this message...";
const signature = await sdk.wallet.sign(message);

// Now we can recover the signing address
const address = sdk.wallet.recoverAddress(message, signature);

Signature:

recoverAddress(message: string, signature: string): string;

Parameters

ParameterTypeDescription
messagestringthe original message that was signed
signaturestringthe signature to recover the address from

Returns:

string

the address that signed the message