const fetch = require('isomorphic-fetch') const query = fetch('https://www.freecodecamp.org/page-data/sq/d/4195245674.json') .then(resp => resp.json()) .then(data => { // console.log(data) return data.data.allChallengeNode.edges.map(e => { // console.log(e.node) const url_pieces = e.node.fields.slug.split('/') return { name: e.node.title, cert: url_pieces[2], section: url_pieces[3], task: url_pieces[4] } }) }).then(q => console.log(q))