fetch("https://api.cryptoquant.com/v1/btc/market-data/coinbase-premium-index?window=day&from=20191001T000000&limit=2") .then(response => response.json()) .then(data => console.log(data))