Can I use other node.js libraries in Meteor?

meteor

Solution

Looks like you can get at `require` this way:

var http = __meteor_bootstrap__.require('http');

Note that this'll probably only work on the server, so make sure it's protected with a check for `Meteor.is_server`.

Problem

I was playing around with an idea and wanted to get some json from another site. I found with node.js people seem to use http.get to accomplish this however I discovered it wasn't that easy in Meteor. Is there another way to do this or a way to access http so I can call get? I wanted an interval that could collect data from an external source to augment the data the clients would interact with.

Original source