2

I am facing an issue when calling the withdraw API or using it through the SDK. The problem is that when I try to withdraw funds, it withdraws a smaller amount than expected and leaves the remaining balance in the wallet. For example, when withdrawing 6 DOGE, instead of sending 6 to the address, it sends 2, and 4 remains in my wallet. What could be the issue? Has anyone else faced this? I’ve been stuck on this for a while, so please let me know the solution. Thanks!

Code:

const withdrawToken = async (symbol, address, amount, network) => {
 try {
 const response = await client.withdraw(symbol, address, amount, network);
 console.log(`Withdrawal successful for ${symbol}:`, response.data);
 } catch (error) {
 console.log(
 `Error withdrawing ${symbol}:`,
 error.response.data || error.message
 );
 }
};
const symbol = "DOGE";
const address = "6";
const amount = "DOGE";
const network = "Bsc";
withdrawToken(symbol, address, amount, network);
asked Dec 10, 2024 at 20:32

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.