Wondering how I can make a GET request to a JSON API using Node.js. I preferably want to use Express however it is not necessary, and for the output to be on a Jade page. I\'m s
I like to use the request package:
npm install --save request
And the code:
var request = require('request'); request({url: 'http://yourapi.com/', json: true}, function(err, res, json) { if (err) { throw err; } console.log(json); });