🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

tradex

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tradex

Crypto currency trade API

latest
Source
npmnpm
Version
0.1.4-beta.6
Version published
Maintainers
1
Created
Source

💱Tradex

Cryptocurrency trade API for Nodejs.

Features · Install · Useage · Contact · APIs · License · 中文

⚖️Features

  • Support some popular cryptocurrency exchanges;
  • Lightweight, Less dependencies;
  • Easy to use;
  • Support spot and perpetual futures;
  • 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: 'your-apiKey',
    secretKey: 'your-secretKey'
});

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

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

🔐How to get API's access permission

☎️Contact

If you have any other questions on APIs, you can contact us by below ways:

  • Telegram: 👉https://t.me/aikuant👈
  • Wechat: Scan 👇QR code👇 and add as a friend, then invite you to join the technical group

Wechat

🏋🏻‍♂️Supported Exchange Markets

NameidDocument
Binancebinancedoc
Huobi Globalhuobidoc
OKExokexdoc

📖APIs

  • spot
    • ✅ getTrick(symbol)
    • ✅ getDepth({ symbol, limit })
    • ✅ getKlines({ symbol, period, limit })
    • ✅ getBalance(currency)
    • ✅ getBalances(currencies)
    • ✅ buy({ symbol, amount, price })
    • ✅ sell({ symbol, amount, price })
    • ✅ cancelOrder({ id, symbol })
    • ✅ getOrder({ id, symbol })
    • 🚧 getOrders({ symbol, startTime, endTime, limit })
    • ✅ invoke({ method, path, data })
  • futures(perpetual)
    • ✅ getTrick(symbol)
    • ✅ getDepth({ symbol, limit })
    • ✅ getKlines({ symbol, period, limit })
    • ✅ setLeverage({ symbol, leverage })
    • 🛠 order({ symbol, position, price, amount })
    • 🛠 cancelOrder({ id, symbol })
    • 🛠 getOrder({ id, symbol })
    • 🚧 getOrders({ symbol, startTime, endTime, limit })
    • ✅ invoke({ method, path, data })

Models

📄License

MIT

Copyright (c) 2020-present, 一俢(1Jay)

Keywords

quant

FAQs

Package last updated on 23 Sep 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts