idex-sdk-js

IDEX 2.0 SDK built with TypeScript, supporting both web and Node environments.

idexio/idex-sdk-js
starsStars 15
forksForks 5
watchersWatchers 15
current-versionCurrent version v1.5.2
total-releasesTotal releases 83
open_issues_countOpen issues 8
dateFirst release 2020-08-01
dateLatest release 2020-11-20
updateLast update 2020-11-20

Javascript SDK

The official library for REST and WebSocket APIs

Complete documentation for the IDEX 2.0 API is available at https://docs.idex.io.

Features

  • Easy functionality to use in programmatic trading
  • A WebSocket-backed real-time order book implementation
  • Clients with convenient methods for every API endpoint
  • Abstracted interfaces – don't worry about HMAC signing, JSON formatting, or ECDSA signatures; the library does it for you
  • Supports both Node.js and browser environments
  • Written in Typescript with full typings for all requests and responses

Installation

yarn add @idexio/idex-sdk
// or
npm install --save @idexio/idex-sdk

Getting Started

Get IDEX 2.0 sandbox API keys.

import * as idex from '@idexio/idex-sdk';

const publicClient = new idex.RestPublicClient({
  sandbox: true,
});
console.log(await publicClient.getServerTime());

In-depth usage documentation by endpoint is available here.

Contracts

Included in the contracts/ directory are the Solidity source and corresponding ABI for the faucet function for dispensing tokens.

See the idex-contracts repo for a reference Solidity implementation of order and withdrawal signature verification that exactly mirrors the Javascript implementation found in this repo.

The Exchange ABI can be used to query contract state, exit wallets.

License

The IDEX Javascript SDK is released under the MIT License.