Embedded Wallets
SDK
Javascript
How to
Wallet Operation
Refresh Token

Refresh Wallet Token

This method allows you to refresh your wallet token.

Method Signature

async refreshToken(refreshToken: string): Promise<string>

Parameters

refreshToken: string - The current refresh token

Returns

  • walletToken: string - The new access token
  • refreshToken: string - The new refresh token

Example Usage

const newToken = await sdk.wallet.refreshToken("your_current_refresh_token");
console.log(newToken);
ℹ️

Ensure to securely store the new wallet token for future use.