getKmdWalletAccount
getKmdWalletAccount(
walletAccount
,algod
,kmdClient
?):Promise
<Account
|undefined
>
Defined in: src/localnet/get-kmd-wallet-account.ts:27
Parameters
walletAccount
The details of the wallet, with:
name
: The name of the wallet to retrieve an account frompredicate
: An optional filter to use to find the account (otherwise it will return a random account from the wallet)
name
string
predicate
(account
) => boolean
algod
AlgodClient
An algod client
kmdClient?
KmdClient
A KMD client, if not specified then a default KMD client will be loaded from environment variables
Returns
Promise
<Account
| undefined
>
Example
const defaultDispenserAccount = await getKmdWalletAccount(algod, 'unencrypted-default-wallet', a => a.status !== 'Offline' && a.amount > 1_000_000_000)