Closed sschiessl-bcp closed 5 years ago
Found following working:
Default behavior of getAddressFromPublicKey
is switching to tbnb
. Needs second argument to switch to bnb
Solved?
Yes, so far haven't found other need to differentiate between main and testnet
having same problem
const BnbApiClient = require('@binance-chain/javascript-sdk');
const api = ' https://dex.binance.org/';
const bncClient = new BnbApiClient(api); bncClient.initChain();
const acc = bncClient.createAccountWithMneomnic(); console.log(acc);
but it create testnet wallet
Check if createAccountWithMneomnic
also has second prefix argument
Luke: Use bncClient.chooseNetwork(“mainnet”)
Got it Thanks
I am connected to mainnet through dex.binance.org and I am converting private key to address, in that process I am getting a ''tbnb'' prefixed address.
How can I switch that behavior?