# Suggest brain key

A brain key is a long passphrase that provides enough entropy to generate cryptographic keys. The suggestBrainKey function returns a brain key along with the corresponding private and public keys.

Using a brain key, you can regenerate the same key pairs whenever needed, provided the exact same mnemonic phrase is used. This is especially useful in scenarios requiring backup and recovery of cryptographic keys, ensuring they are never permanently lost.

# Code Snippet to Suggest a Brain Key

import { createWaxFoundation } from '@hiveio/wax';

const waxApi = await createWaxFoundation();

// Suggest brain key
const privateKeyData = waxApi.suggestBrainKey();

console.log(`Associated Public Key: ${privateKeyData.associatedPublicKey}`);
console.log(`WIF Private Key: ${privateKeyData.wifPrivateKey}`);
console.log(`Brain Key: ${privateKeyData.brainKey}`);