[Need Help] Response body, Console logs are not working

I am facing a weird issues with newman HtmlExtra teports.
In final report, the request headers, body is correctly showing. But response body is showing as “Cannot POST /write”.
And the console logs are also showing as [object] [object].

Also showing “connect ECONNREFUSED” when I run my collection.
There is below code under collection level Tests. If I comment it the blow code, I am getting ECONNREFUSED error.

let opts = {
requestName: request.name || request.url,
fileExtension: ‘csv’,
responseData: pm.response.text(),
reqBody: request.data,
mode: ‘writeFile’, // Change this to any function of the fs library of node to use it.
uniqueIdentifier: Date.now()

url: ‘[http://localhost:3000](http://localhost:3000/)’,
method: ‘POST’,
header: ‘Content-Type:application/json’,
body: {
mode: ‘raw’,
raw: JSON.stringify(opts)
}, function (err,res) {
// console.log(res);

Thank you