Skip to content

mikunimaru/nomics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cnomics

The node.js module for the nomics.com API.

Install

npm install --save mikunimaru/nomics.git

Usage

Each class requires an API key as its initial value.
If it is blank, it will operate in demo mode.

new Nomics({}) // Demo mode.
new Nomics({apiKey: "your-api-key"}) // Normal mode

Class

Nomics (default export)

It is a class corresponding API name and method name with 1: 1.
Returns data of type Object.

NomicsNode

Class that returns processed data.

currenciesArray()

Array of nomics currency id.

[ '0XBTC','1ST','2GIVE','3DES', ...

pricesObject()

An object of Prices.

 { _1ST: 0.02829,
   _2GIVE: 0.00138,
   ABA: 0.01547,
   ABT: 0.07469,
   ABTC: 0.13559,
   ABY: 0.00124,
   ABYSS: 0.00632,
   ...

If the ID name is a currency beginning with a number or symbol, an underscore is
added at the beginning of the name to make it easier to work with GraphQL.

dashboardObject()

Dashboard version of the above method.

exchangeRatesObject()

Get exchangeRates with a single object.

 {
   USD:
   { currency: 'USD',
     rate: 1,
     timestamp: '2019-01-16T00:00:00Z' },
   EUR:
   { currency: 'EUR',
     rate: 1.14142,
     timestamp: '2019-01-16T00:00:00Z' },
   JPY:
   { currency: 'JPY',
     rate: 0.0092,
     timestamp: '2019-01-16T00:00:00Z' },
   ...

currenciesIntervalObject()

Get currenciesInterval with a single object.

  {
    BTC:
    { currency: 'BTC',
      volume: 4887265624.18739,
      open: 3650.91796,
      open_timestamp: '2019-01-13T00:00:00Z',
      close: 3770.37047,
      close_timestamp: '2019-01-19T00:00:00Z' },
    ETH:
    { currency: 'ETH',
      volume: 2011702447.65631,
    ...

About

The simple npm package for nomics.com API.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published