JSON requests made easy. No more dealing with low-level HTTP events, chunked requests or responses, buffering, parsing, try-catching, etc. Just get and post to send and receive.
npm install jsonreq
var json = require('jsonreq');
json.get('http://api.example.com/foo.json', function (err, data) {
// ...
});
var obj = {
key: 'value',
items: [1, 2, 3],
};
json.post('http://api.example.com/foo.json', obj, function (err, data) {
// ...
});
npm link
npm test