Tenant saved objects .kibana index

Is there any way to get the tenants .kibana index pattern (the index where Kibana saved objects are stored) upon tenant creation or any other method?
It seems to be constructed like this .kibana_-{unknow_id}_{user_name} but the documentation doesn’t mention it?

here it’s mentioned :
https://opendistro.github.io/for-elasticsearch-docs/docs/security-access-control/multi-tenancy/

Manage Kibana indices

The open source version of Kibana saves all objects to a single index: .kibana . The Security plugin uses this index for the global tenant, but separate indices for every other tenant. Each user also has a private tenant, so you might see a large number of indices that follow two patterns:

.kibana_<hash>_<tenant_name>
.kibana_<hash>_<username>

The Security plugin scrubs these index names of special characters, so they might not be a perfect match of tenant names and usernames.

To back up your Kibana data, take a snapshot of all tenant indices using an index pattern such as .kibana* .

Thank you, I’ve found it myself but still can’t find what is the hash and how it’s generated?

It’s is some random unique number or we can say unique identifier for each tenants and users.

Maybe the hash is generated from java.lang.String#hashCode().

Here is a simple JavaScript online implementation which can get you the hash: http://jsfiddle.net/Ciul/w42en/