• Introduction
  • IDLs
    • getIdlFromAddress()
    • getInstructionFromIdl()
    • useRequestIdlFromAddress()
  • PDAs
    • getPdaFromSeedAndProgramAddress()
    • usePdaFromUserPublicKeyAndProgramAddress()
  • URLs
    • getRpcEndpointUrl()
    • getExplorerUrl()
    • getAllExplorerUrls()
    • getFaucetUrl()
  • Blockchain
    • getSolanaStatus()
    • useSolanaStatus()
  • Cluster
    • getNewConnection()
    • getClusterName()
    • getClusterNameFromEndpoint()
  • Keypairs
    • getNewKeypair()
    • getKeypairFromSecretKey()
    • getAddressFromPublicKey()
    • getPublicKeyFromAddress()
    • getShortAddress()
  • Serialization
    • getEmptyBuffer()
    • getEncodedBufferFromData()
    • getDecodedDataFromBufferAndSchema()
  • Tokens
    • useRequestSolAirdrop()
    • useTransferTokens()
  • Transactions
    • getIsValidTransaction()
    • getTransactionDetails()
    • useIsValidTransaction()
    • useTransactionDetails()
  • Units
    • getLamportsToSol()
    • getSolToLamports()
  • Wallet
    • useWalletTokenBalance()
  • Introduction
  • IDLs
    • getIdlFromAddress()
    • getInstructionFromIdl()
    • useRequestIdlFromAddress()
  • PDAs
    • getPdaFromSeedAndProgramAddress()
    • usePdaFromUserPublicKeyAndProgramAddress()
  • URLs
    • getRpcEndpointUrl()
    • getExplorerUrl()
    • getAllExplorerUrls()
    • getFaucetUrl()
  • Blockchain
    • getSolanaStatus()
    • useSolanaStatus()
  • Cluster
    • getNewConnection()
    • getClusterName()
    • getClusterNameFromEndpoint()
  • Keypairs
    • getNewKeypair()
    • getKeypairFromSecretKey()
    • getAddressFromPublicKey()
    • getPublicKeyFromAddress()
    • getShortAddress()
  • Serialization
    • getEmptyBuffer()
    • getEncodedBufferFromData()
    • getDecodedDataFromBufferAndSchema()
  • Tokens
    • useRequestSolAirdrop()
    • useTransferTokens()
  • Transactions
    • getIsValidTransaction()
    • getTransactionDetails()
    • useIsValidTransaction()
    • useTransactionDetails()
  • Units
    • getLamportsToSol()
    • getSolToLamports()
  • Wallet
    • useWalletTokenBalance()
Question? Give us feedback → (opens in a new tab)Edit this page
Keypairs
getNewKeypair()

Returns a new account keypair that could be used for testing purposes like signing transactions.

import { getNewKeypair } from '@lndgalante/solutils';
 
const { keypair } = getNewKeypair();
getClusterNameFromEndpoint()getKeypairFromSecretKey()

MIT 2024 © Nextra.