1const request = require('request');
2request('http://www.google.com', function (error, response, body) {
3 console.error('error:', error); // Print the error if one occurred
4 console.log('statusCode:', response && response.statusCode); // Print the response status code if a response was received
5 console.log('body:', body); // Print the HTML for the Google homepage.
6});