or .get _source response just shows Object

Running a query from a js file executed by node.js. The query executes correctly but objects like system.auth.program, system.auth.message, don't display correctly and only show up as
_source: { system: { auth {: [Object] } } }.

Is this a mapping/nesting?
All the fields show up in kibana just not when I use a node js client.

My js query:
var client = require('./connection.js');

index: 'filebeat-6.3.0-2018.07.11',
_source: 'system.auth.program',
type: 'doc',
id: "bRukiWQBmx8wJj3Gwe5q"
},function (error, response,status) {
if (error){
console.log("search error: "+error)
else {
console.log("--- Response ---");

What is returned on the console:
--- Response ---
{ _index: 'filebeat-6.3.0-2018.07.11',
_type: 'doc',
_id: 'bRukiWQBmx8wJj3Gwe5q',
_version: 2,
found: true,
_source: { system: { auth: [Object] } } }

Would expect to see system.auth.program: sshd returned

Never mind: Turned out I needed to use client.getSource getSource

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.