JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q27519F
  • License MIT

Crypto currency trade API

Package Exports

  • tradex2

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tradex2) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

๐Ÿ’ฑTradex

Crypto currency trade API for Nodejs

Features

  • Support some popular crypto currency exchanges
  • Lightweight
  • Less dependencies
  • Only support spot, futures is planning
  • Support Node 12+

Installing

Using yarn:

$ yarn add tradex

Or using npm:

$ npm install tradex

Useage

const Tradex = require('tradex');

const tradex = new Tradex({
    id: 'binance',
    host: 'https://api.domain.com',
    apiKey: 'vmPUZE6mv9SD5VNHk4HlWFsOr6aKE2zvsw0MuIgwCIPy6utIco14y7Ju91duEh8A',
    secretKey: 'NhqPtmdSJYdKjVHjA7PZj4Mge3R5YNiP1e3UZjInClVN65XAbvqqM6A7H5fATj0j'
});

// use promise.then()
radex.getBalance('usdt').then(res => {
    console.log(res);
})

// or use async/await
(async () => {
    const balance = await tradex.getBalance('usdt');
    console.log(balance);
})();

How to get API's access permission

Supported Exchange Markets

Name id Document
Binance binance doc
Huobi Global huobi doc
OKEx okex doc

APIs

  • โœ… getTrick(symbol)
  • ๐Ÿ• getTricks()
  • โœ… getBalance(currency)
  • โœ… getBalances(currencies)
  • โœ… buy({ symbol, amount, price })
  • ๐Ÿ• buys(orders)
  • โœ… sell({ symbol, amount, price })
  • ๐Ÿ• sells(orders)
  • ๐Ÿ• order(options)
  • โœ… getOrder(id, symbol)
  • ๐Ÿ• getOrders()

License

MIT

Copyright (c) 2020-present, ไธ€ไฟข(1Jay)