# ApiError AuthenticationException even correct API Key is provided

**URL:** <https://discuss.elastic.co/t/apierror-authenticationexception-even-correct-api-key-is-provided/353121>\
**Category:** Elastic Search\
**Tags:** elastic-app-search\
**Created:** [February 13, 2024, 5:30am UTC](https://discuss.elastic.co/t/apierror-authenticationexception-even-correct-api-key-is-provided/353121 "2024-02-13T05:30:57Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [February 13, 2024, 6:44am UTC](https://discuss.elastic.co/t/apierror-authenticationexception-even-correct-api-key-is-provided/353121/2 "2024-02-13T06:44:20Z")

</div>

Hi @tfulanchan Welcome to the community.

Kinda a common mistake when getting started.

> [@tfulanchan](#):
>
> Organization \> API Keys \> Create API key".

That creates An API Key for using The ESS / Elastic Cloud API to create and modify whole clusters. Etc.

To work within an Elasticsearch cluster...I.e the REST API to load data and work inside an Elasticsearch cluster

Go to  
Kibana - Stack Management - API Keys

Make sure you get the correct format for the REST API

---

_[View the full topic](https://discuss.elastic.co/t/apierror-authenticationexception-even-correct-api-key-is-provided/353121)._
