Hello. I want to withdraw BTC from my Incognito wallet to the outer wallet using NodeJS SDK. Important - I am in the testnet.
According to the docs (https://github.com/incognitochain/sdk-v2), I have to call
But each time when I do it I am getting the following error:
TypeError: walletBTCToken.bridgeWithdraw is not a function.
I am calling bridgeWithdraw with the following code snippet:
const masterAccount = await wallet.masterAccount.getAccountByName(masterAccountName) const walletBTCToken = await masterAccount.getFollowingPrivacyToken(BTCTokenId) await walletBTCToken.bridgeWithdraw(outerWalletAddress, amountToWithdraw)
Maybe I have the wrong version of the SDK or should I use another method? Thanks.
I have also tried to use
bridgeBurningCentralized and then
bridgeWithdrawCentralized methods but each time when I call
bridgeBurningCentralized I get the error saying:
Token 4584d5e9b2fc0337dfb17f4b5bb025e5b82c38cfa4f54e8a3d4fcdd03954ff82 is not has exchange rate.