How can we request Kibana with REST API to get the visualization request and response?
I want to do that using NodeJS to manipulate this results of Kibana. The purpose is that I want to directly query Kibana programmatically (via REST API) to get the ES request body.
You can directly request the ES. The documentation is here
You can go to kibana\kibana-4.5.1-windows\optimize\bundles\kibana.bundle.js file, search the function "Transport.prototype.request = function (params, cb)", and add in the first line
parent.postMessage(params.body, "*");
Now go to the controller or script that manage the iframe(iframe parent) and addfor example:
Now you will get the request query