Need help on reading files on server from a custom plugin

I'm developing a plugin which will read a fixed csv file from the server.

The problem is I'm not able to comprehend how Kibana exposes the files that I can read or can't.
I'm running both Elasticsearch and Kibana with yarn, in my folder kibana/plugins/editor.

Where should I place my csv file so that I could read it with a XMLHttpRequest().open("GET", , true)?

If you want the CSV data exposed to browser code when you make an AJAX call, your plugin will need to create a new server route that is responsible for responding to queries and in response, sends back the CSV data to the client.

The browser code would make the AJAX call to your new server route.

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