List of all kibana apis

Hi all,

I wanted to customized kibana. The ideas is to filter all the apis calls made by kibana which I do not.
So I worrying if somebody can help me with the list of all the apis that kibana calls when it connects to elasticsearch.

Here are some that I could collect.
http://ip_of_kibana-server:9200/_nodes
http://ip_of_kibana-server:9200/_cluster/health/.kibana
http://ip_of_kibana-server:9200/.kibana/config/_search
http://ip_of_kibana-server:9200//_aliases
http://ip_of_kibana-server:9200/logstash-
/_mapping/field/*
http://ip_of_kibana-server:9200/.kibana/__kibanaQueryValidator/_validate/query
http://ip_of_kibana-server:9200/.kibana/visualization/_search
http://ip_of_kibana-server:9200/.kibana/_mapping/*/field/_source
http://ip_of_kibana-server:9200/.kibana/index-pattern/_search

thanks.

This is undocumented and constantly changing. I wouldn't recommend going down this path. What are you trying to accomplish? You can achieve quiet a bit by writing a Kibana plugin or Hack:


I have setup an ELK stack and secure it with the shield. While playing with the secure ELK, I was stucked with a security exception. That is if a user X login and does query on his index indexOfX (X has sufficient permission on the index indexOfX). Then when another user Y comes and login, he/she will get a security exception because kibana goes and retrieves the previous queried index (indexOfX). But Y does not has sufficient permission on indexOfX thus the security exception.

My goal is to render kibana multi-tenant. I addressed this issue by proxying all the calls of kibana to elasticsearch. By so doing I will modify the responce to kibana so that it will only print the indexes of a currently login user.

Thanks.

How many different user roles do you need to support? If it's a small number, one easy way to do multi-tenancy is to simply setup multiple Kibana instances, each pointing to a different configuration index.

If it's a large number, this is much more difficult. Proxying the calls to elasticsearch will be impossible because the APIs we use are constantly changing. Multi-tenancy is definitely something we're interested in implementing down the road, but it's a huge task.

If you just want to avoid the second user getting a security exception on the initial page load, you could switch the default index pattern to an empty index that everyone has access to. That way when each user logs in, they'll get that index by default and can then manually switch to their own index. They would still see other users' indices in the list in Kibana, but they would get an exception if they tried to access them.

If you absolutely need to try to implement something yourself, I'd recommend going down the road of implementing a Kibana Hack. These give you the ability to to override pretty much anything in Kibana, so you might be able to figure out a way to override things cleanly.

Thanks for the reply @Bargs . We really need to add a big number of user roles. So setup multiple Kibana instances is not suitable for us. Also, The fact to switch to a default index pattern is not a good idea for our case. Btw I didn't ever write hacks for kibana, so this solution may take too long. Could you please give me the apis if you have them?

That's what I'm trying to say, I don't have a comprehensive list of every elasticsearch API that Kibana uses, nor does anyone else. The APIs we use are constantly changing as development continues on.

Thank you very much for your answers. It will be helpful

Hey @Bargs I have a question. Do you know which api kibana calls to get all the indexes from elasticsearch?

I don't know off the top of my head unfortunately. If you want to go down that route you'll need to either read the source code or look at the network traffic between Kibana and Elasticsearch.

Hi

is there a source code where i could look for the kibana apis supported by elasticsearch

Thanks

@Bargs Thanks a lot for the reply, i am trying to automate all the kibana ui tasks, is there a example where i could look at?

I am using selenium test framework to create index, create graphs but am unable to find the ui ids linked to it? is there a place where i could find to automate all the kibana graphs creations etc...