import { IEsSearchResponse } from '../../../../../../../../../src/plugins/data/common' ; import { ActionDetailsStrategyResponse , ActionDetailsRequestOptions , OsqueryQueries , } from '../../../../../../common/search_strategy/osquery' ; import { inspectStringifyObject } from '../../../../../../common/utils/build_query' ; import { OsqueryFactory } from '../../types' ; import { buildActionDetailsQuery } from './query.action_details.dsl' ; export const actionDetails = { buildDsl : ( options ) => buildActionDetailsQuery ( options ) , parse : async ( options , response ) : Promise < ActionDetailsStrategyResponse > => { const inspect = { dsl : [ inspectStringifyObject ( buildActionDetailsQuery ( options ) ) ] , } ; return { ... response , inspect , actionDetails : response . rawResponse . hits . hits [ 0 ] , } ; } , } ;