Generate Xpub

Generating an extended public key (xpub) is a way to allow the creation of public addresses without exposing the corresponding private keys. It's an important function for maintaining security while still being able to receive funds.

You can generate Xpub with or without mnemonic.

// Import the necessary library and initialize the SDK
import { EvmWalletProvider } from '@tatumio/evm-wallet-provider';
import { TatumSDK, Network, Ethereum } from '@tatumio/tatum';

const tatumSdk = await TatumSDK.init<Ethereum>({network: Network.ETHEREUM,
     configureWalletProviders: [

// Generate xpub using the generated mnemonic
const xpubDetails = await tatumSdk.walletProvider.use(EvmWalletProvider)

console.log(xpubDetails.xpub);  // This will print the generated xpub

await tatum.destroy()

Last updated

ยฉ Tatum Technology, LLC