Skip to content
This repository has been archived by the owner on Jan 20, 2020. It is now read-only.

Cannot use withdraw API using crypto_address #176

Closed
adityamertia opened this issue Dec 24, 2017 · 5 comments
Closed

Cannot use withdraw API using crypto_address #176

adityamertia opened this issue Dec 24, 2017 · 5 comments

Comments

@adityamertia
Copy link
Contributor

adityamertia commented Dec 24, 2017

Hi,

When i try to withdraw ETH from gdax to another crypto_address using withdraw API it throws error "opts must include param coinbase_account_id"

Documentation of gdax-node documents it as below:

// Withdraw from your Exchange BTC account to another BTC address.
const withdrawAddressParams = {
  'amount': 10.00,
  'currency': 'BTC',
  'crypto_address': '15USXR6S4DhSWVHUxXRCuTkD1SA6qAdy'
}
authedClient.withdrawCrypto(withdrawAddressParams, callback);

This throws error that withdrawCrypto method doesnt exists. It looks like a typo in documentation.

If i use following code:

const withdrawAddressParams = {
  'amount': 0.002,
  'currency': 'ETH',
  'crypto_address': '03x245276ad8c2747ec69a6005970769280d'
}
authedClient.withdraw(withdrawAddressParams, function(response){
   console.log(response);
});

it throws error "opts must include param coinbase_account_id"

Thanks
Aditya

@fb55
Copy link
Contributor

fb55 commented Dec 25, 2017

The method definitely exists: https://github.com/coinbase/gdax-node/blob/17619ca073a64f20674a2c125d6cbe7a43b2d420/lib/clients/authenticated.js#L260-L263

Not sure what your error is, would be great if you could provide some more context.

@wannesdemaeght
Copy link

wannesdemaeght commented Dec 31, 2017

Had this error too.
In my case, it's because i used npm install gdax-node.
In that library, withdrawcrypto is not available.
Download directly from github (zip file), problem goes away.

@adityamertia
Copy link
Contributor Author

adityamertia commented Jan 3, 2018

from npm
npm install gdax
from GitHub
npm install coinbase/gdax-node

Issue is because GitHub has the latest version and npm repo has older version which doesn't have withdrawCrypto function. npm repo needs to be updated.

@rmm5t
Copy link
Contributor

rmm5t commented Jan 3, 2018

@adityamertia See #148

@drewrothstein
Copy link

Hi, we are closing out PRs + Issues as this project is being archived.

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

No branches or pull requests

5 participants