nothingisdead / npm-kraken-api

[DEPRECATED] NodeJS Client Library for the Kraken (kraken.com) API
Other
412 stars 188 forks source link

ReferenceError: buy is not defined #60

Open marccasco opened 6 years ago

marccasco commented 6 years ago

Good morning,

I am trying to make purchases but they do not work, and they return error, why?

Code: var buy1 = await kraken.api('OpenOrders', { pair : 'XETHXXBT', type : buy, ordertype: market, volume: 0.10 }); console.log(buy1);

Error: UnhandledPromiseRejectionWarning: ReferenceError: buy is not defined

Thank you very much, greetings.

kattatzu commented 5 years ago

You must enclose the word "buy" in quotes like "market", it is a syntax error.