# Create new or obtain default private-api-key

**URL:** <https://discuss.elastic.co/t/create-new-or-obtain-default-private-api-key/257789>\
**Category:** Elastic Search\
**Tags:** elastic-app-search\
**Created:** [December 6, 2020, 11:43pm UTC](https://discuss.elastic.co/t/create-new-or-obtain-default-private-api-key/257789 "2020-12-06T23:43:26Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![ismarslomic](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ismarslomic/32/63870_2.png) [@ismarslomic](https://discuss.elastic.co/u/ismarslomic)\
**Post date:** [December 7, 2020, 9:01am UTC](https://discuss.elastic.co/t/create-new-or-obtain-default-private-api-key/257789/3 "2020-12-07T09:01:30Z")

</div>

> [@MadsOhm](#):
>
> You want to be able to define an API key that Enterprise Search is "born" with out of your Kubernetes code?

You are correct! I have described what I really want in an duplicate post (sorry for that) here: [Create custom API Key for Enterprise Search/App Search in ECK through Kubernetes resource](https://discuss.elastic.co/t/create-custom-api-key-for-enterprise-search-app-search-in-eck-through-kubernetes-resource/257771). I would like to configure my API Keys as part of the Kubernetes resource spec, similar to configuring Elasticsearch Users by using [Elasticsearch File Realm](https://www.elastic.co/guide/en/cloud-on-k8s/1.3/k8s-users-and-roles.html#k8s_creating_custom_users).

---

_[View the full topic](https://discuss.elastic.co/t/create-new-or-obtain-default-private-api-key/257789)._
