UNPKG

coin-ticker

Version:

Wrapper for bitcoin exchange apis. The easiest way to add cryptocurrency market data into your application!

14 lines (12 loc) 314 B
const axios = require('axios'); module.exports = () => { return axios.get('https://api.gdax.com/products/') .then((res) => { return res.data.map((product) => ( product.id.replace('-', '_') )) }) .catch((err) => { console.error('Error fetching gdax pairs:', err); }); }