Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

throw new Error('Insufficient ust balance'); #35

Open
Djainesh opened this issue May 11, 2022 · 0 comments
Open

throw new Error('Insufficient ust balance'); #35

Djainesh opened this issue May 11, 2022 · 0 comments

Comments

@Djainesh
Copy link

Hello folks, I my facing the above issue while implementing the code of deposit. If anyone could guide me for this error it would be great as I'm new in this field. thank you in advance. i had also entered my Mnemonickey but still it not works for me. It says throw new Error('Insufficient ust balance');

import { Account, AnchorEarn, CHAINS, NETWORKS, TxOutput } from '@anchor-protocol/anchor-earn/dist/facade';
import {MnemonicKey} from '@anchor-protocol/anchor-earn/dist/facade';
import {DENOMS} from '@anchor-protocol/anchor-earn/dist/address-provider'

/**
*
*For creating new account
*/
// const account = new Account(CHAINS.TERRA);
// console.log(account.toData());

const account = new MnemonicKey({
mnemonic:
'',
});

console.log(account.accAddress);

const anchorEarn = new AnchorEarn({
chain: CHAINS.TERRA,
network: NETWORKS.BOMBAY_12,
privateKey: account.privateKey,
});

async function start() {
const deposit = await anchorEarn.deposit({
amount: '1.0',
currency: DENOMS.UST,
})

}

start();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant