question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

wrong withdraw() with mexc api

See original GitHub issue

MUST READ THIS BEFORE SUBMITTING ISSUES (read the links, then delete this message before submitting):

Make sure your local version of CCXT is up to date. Check by comparing the output of ccxt.version to https://github.com/ccxt/ccxt/blob/master/package.json#L3

  • OS: Ubuntu 20
  • Programming Language version: Javascript
  • CCXT version:@1.63.32
const ccxt = require ('ccxt');
const key = require('./key.json');
const mexc = new ccxt.mexc ();
mexc.apiKey = key.mexc.AccessKey;
mexc.secret = key.mexc.SecretKey;
mexc.requiredCredentials;
mexc.checkRequiredCredentials();

// the address is checked that it's in the whitelist and has a withdraw permission
const address = '';
console.log(await mexc.withdraw('USDT','50',address,'',{chain:'BEP20(BSC)'}));

ExchangeError: mexc {"code":10212,"msg":"This withdrawal address is not on the commonly used address list or has been invalidated"}
    at mexc.handleErrors (/root/node_modules/ccxt/js/mexc.js:2094:19)
    at /root/node_modules/ccxt/js/base/Exchange.js:670:18
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async timeout (/root/node_modules/ccxt/js/base/functions/time.js:203:20)
    at async mexc.withdraw (/root/node_modules/ccxt/js/mexc.js:2034:26)
    at async main (file:///root/arbot/arb/biarb/mexc.mjs:63:21) {
  constructor: [class ExchangeError extends BaseError]
}

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
franklee00commented, Dec 9, 2021

@franklee00 it actually worked, your transaction went through, but it failed to parse the response. Pushed a fix to it, let me know if you have the same last issue with version 1.63.35+ or not (the new build will arrive in ~20 minutes). Thanks for reporting it.

let me try, thx a lot.

1reaction
kroitorcommented, Dec 9, 2021

@franklee00 it actually worked, your transaction went through, but it failed to parse the response. Pushed a fix to it, let me know if you have the same last issue with version 1.63.35+ or not (the new build will arrive in ~20 minutes). Thanks for reporting it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Introduction – MEXC API - GitHub Pages
Welcome to use MEXC API! This document provides you with REST API related information to help you obtain market information, manage account information, ......
Read more >
What If I Withdraw To The Wrong Adress Or Enter Wrong ... - MEXC
If you realized that the withdrawal address is wrong before you confirm the withdrawal SMS or email, you can go to the withdrawal...
Read more >
ccxt/mexc.py at master - GitHub
A JavaScript / Python / PHP cryptocurrency trading API with support for more than 100 bitcoin/altcoin exchanges - ccxt/mexc.py at master · ccxt/ccxt....
Read more >
Manual — ccxt 2.4.71 documentation
unified data structures and formats, orderbooks, trades, orders, candles, timeframes, … exceptions and error mappings; authentication and API keys (for private ...
Read more >
FAQ: Signature for this request is not valid. - API
For new users to API, one of the most common questions is how to work out the signature. The error code and message...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found