How to enable verbose log for the following node request module?
https://github.com/mikeal/request
var reqParam = { 'headers': { 'User-Agent': 'CLA' }, 'body': 'CSCCDDSADADDADADADAAAEE', 'strictSSL': true, 'jar': false, 'encoding': null, 'timeout': 300000 }; request.post(reqParam, function (err, res, body) { if (err) { console.log('Curl request received an error:' + err); } console.log(body); };
What is the option which will enable http VERBOSE log for the https://github.com/mikeal/request module ??
I used to following code by using the Tail package which worked: const filepath = "path/to/file"; var Tail = require('tail'). Tail; var options = {fromBeginning: true}; var tail = new Tail(filepath, options); tail. on('line', function(data) { //do something with data }); tail. on("error", function(error) { console.
Using the Node. To connect to it, open up Google Chrome and enter about:inspect into the URL bar and press Enter. Afterward, you will be redirected to chrome://inspect/ and be presented with a list of available devices to debug. If successful, your screen should show something similar to the image below.
Do you mean debug?
NODE_DEBUG=request node yourscript.js
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With