RSS feed only returns content:encoded


#1

When I request rss.xml from my hubspot blog, the xml file is not returned, only the value in “< content:encoded >”. I use the same code and call a different URL and it retrieves the xml file without a problem.
I am using Node.js with express and the request module https://github.com/request/request.

Why am I unable to retrieve the actual xml file the same way I do when I just type the url into my browser considering it works fine with other xml files I access remotely? This only happens with the Hubspot blog rss feed xml.

var options = {
	method: 'GET',
	url: '[hubspotblog]/event/topic/announcement/rss.xml',
	headers: { 'Content-Type': 'text/xml' }
}

request.get(options, function(err, response, body) {
	if (!err && response.statusCode == 200) {
		announcement = body;

		res.render('home', {
			'announcement': announcement
		});
	}
});

#2

The issue was the request module.
You can close this thread.