Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@coinpaprika/api-nodejs-client

Package Overview
Dependencies
Maintainers
3
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@coinpaprika/api-nodejs-client

This library provides convenient way to use Coinpaprika.com API in NodeJS

  • 2.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

Coinpaprika API NodeJS Client

NPM version Travis CI Build Status NPM downloads NPM downloads Dependency Status

This library provides convenient way to use Coinpaprika.com API in NodeJS.

Coinpaprika delivers full market data to the world of crypto: coin prices, volumes, market caps, ATHs, return rates and more.

Install

npm install @coinpaprika/api-nodejs-client

Usage

const CoinpaprikaAPI = require('@coinpaprika/api-nodejs-client');

const client = new CoinpaprikaAPI();

client.getTicker().then(console.log).catch(console.error);
client.getGlobal().then(console.log).catch(console.error);

Check out the Coinpaprika API documentation for more information!

API

getGlobal

Get global information

Examples
const client = new CoinpaprikaAPI();
client.getGlobal().then(console.log).catch(console.error);
getCoins

Get a list of all cryptocurrencies available on coinpaprika.com.

Examples
const client = new CoinpaprikaAPI();
client.getCoins().then(console.log).catch(console.error);
getCoinsOHLCVHistorical

Get the OHLCV historical for a coin

Examples
const client = new CoinpaprikaAPI()
client.getCoinsOHLCVHistorical({
    coinId: "btc-bitcoin",
    quote: "usd",
    start: "2020-01-01",
    end: "2020-01-02" 
}).then(console.log).catch(console.error)
getTicker

(DEPRECATED) Get information on all tickers or specifed ticker.

Parameters
  • args (optional, default {})
  • options Object Options for the request
    • options.coinId String Coinpaprika ID from getCoins() (optional, default ``)
Examples
const client = new CoinpaprikaAPI();
client.getTicker().then(console.log).catch(console.error);
client.getTicker({coinId: 'btc-bitcoin'}).then(console.log).catch(console.error);
getAllTickers

Get tickers for all coins

Parameters
  • params (optional, default {})
    • coinId string (optional but required with historical key)
    • quotes array of strings (optional)
    • historical object (optional)
      • start: string (required)
      • end: string (optional)
      • limit: integer (optional)
      • quote: string (optional)
      • interval: string (optional)
Examples
const client = new CoinpaprikaAPI()
client.getAllTickers({
    coinId:'btc-bitcoin',
    quotes: ['BTC', 'ETH']
}).then(console.log).catch(console.error)

client.getAllTickers({
    coinId:'btc-bitcoin',
    historical: {
        start: '2018-02-15',
        end: '2018-02-16',
        limit: 2000,
        quote: 'btc',
        interval: '30m'
    }
}).then(console.log).catch(console.error)

License

CoinpaprikaAPI is available under the MIT license. See the LICENSE file for more info.

Keywords

FAQs

Package last updated on 12 May 2023

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc