I'm looking a way to pass a content-type in RequestJS using with Nodejs.
Right now I have this as params:
'use strict';
request = require('request'),
app.register = function(req, res) {
request.post({
headers: {'Content-Type' : 'application/json'},
url: 'my.url.here',
form: req.body,
}).pipe(res);
}
But for some reason the server it still says it's a content-type text/xml.. Anyone can tell me how to customize this?