Skip to content

Instantly share code, notes, and snippets.

@toamitkumar
Created June 24, 2014 07:05
Show Gist options
  • Save toamitkumar/afe3433b5126f3252458 to your computer and use it in GitHub Desktop.
Save toamitkumar/afe3433b5126f3252458 to your computer and use it in GitHub Desktop.
function getHalResource(req, path, callback) {
var headers = {};
headers['Content-Type'] = 'application/hal+json';
var options = {
method: 'GET',
headers: headers
}
requestResource(req, path, options, callback);
}
function requestResource(req, path, options, callback, data) {
.....
var options = {uri: url}.merge(options);
.....
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment