coinflux-api

0.0.5 • Public • Published

coinflux-api

CoinFlux.com JavaScript API Client

This is an asynchronous NodeJS client for the coinflux.com API. It exposes all the API methods found here: https://api.coinflux.com/v0/ through the api method:


Install

$ npm install coinflux-api

Example Usage:

const key          = '...'; // API Key
const secret       = '...'; // API Private Key
const options      = {
	"env": "test", //defaults to prod -> production
	"timeout": 20000, //optional, defaults to 20000
	"ua" : "Client software name" //optional
}
const CoinFluxClient = require('coinflux-api');
const coinflux       = new CoinFluxClient(key, secret, options);

(async () => {
	// Get Ticker Info
	console.log(await coinflux.api('getRate', { pair : 'XBTEUR' }));

	// Get Ticker Info
	console.log(await coinflux.api('getWallet', { walletid : '0a846ac16f5842e6b48e769e6caa8942' }));
})();

Documentation

This section states available methods and required parameters.

Public methods (no authentication required)

Rates

getRates

getRate

parameters: pair

Private methods (authentication required)

Fluxes

getFluxes

getFlux

parameters: fluxid

getFluxAddresses

parameters: fluxid

getFluxOfAddress

parameters: address

newSellAddress

parameters: fluxid

Wallets

getWallets

getWallet

parameters: walletid

getWalletHistory

parameters: walletid

getWalletHistoryTx

parameters: walletid and historyid

Ledger

getLedger

getLedgerTx

parameters: ledgerid

Bank accounts

getBankAccounts

getBankAccount

parameters: accountid

Trade

buyToAddress

parameters: walletid, address, ccy1, cost and, optionally for XRP, address_tag


Credit:

We used the NodeJS implementation from https://github.com/nothingisdead/npm-kraken-api as reference.

Readme

Keywords

Package Sidebar

Install

npm i coinflux-api

Weekly Downloads

4

Version

0.0.5

License

MIT

Unpacked Size

13.4 kB

Total Files

4

Last publish

Collaborators

  • coinflux