Skip to content

Commit 7a7d586

Browse files
Merge branch 'main' into esserverless
2 parents 367322a + 6c0ab30 commit 7a7d586

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+513
-243
lines changed

deploy-manage/api-keys.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
---
2+
applies_to:
3+
stack: ga
4+
deployment:
5+
eck: ga
6+
ess: ga
7+
ece: ga
8+
self: ga
9+
serverless: ga
10+
---
11+
112
# Manage API keys
213

314
% What needs to be done: Write from scratch
@@ -6,4 +17,16 @@
617

718
% Scope notes: Elasticsearch & Kibana authentication API Keys
819

9-
⚠️ **This page is a work in progress.** ⚠️
20+
21+
API keys are security mechanisms used to authenticate and authorize access to your deployments and {{es}} resources.
22+
23+
They ensure that only authorized users or applications interact with these resources through [Elastic APIs](https://www.elastic.co/docs/api/).
24+
25+
For example, if you extract data from an {{es}} cluster on a daily basis, you might create an API key tied to your credentials, configure it with minimum access, and then put the API credentials into a cron job. Or you might create API keys to automate ingestion of new data from remote sources, without a live user interaction.
26+
27+
Depending on the APIs you want to use, the API keys to create are different, and managed at different locations:
28+
29+
- **[](api-keys/elasticsearch-api-keys.md)**, to use [{{es}}](https://www.elastic.co/docs/api/doc/elasticsearch/) and [{{kib}}](https://www.elastic.co/docs/api/doc/kibana/) APIs, and to manage remote cluster connections.
30+
- **[](api-keys/serverless-project-api-keys.md)**, to use [{{es}}](https://www.elastic.co/docs/api/doc/elasticsearch-serverless/) and [{{kib}}](https://www.elastic.co/docs/api/doc/serverless/) serverless APIs.
31+
- **[](api-keys/elastic-cloud-api-keys.md)**, to manage your {{ecloud}} organization, {{ech}} deployments, and serverless projects using the [{{ecloud}}](https://www.elastic.co/docs/api/doc/cloud/) and [{{ecloud}} serverless](https://www.elastic.co/docs/api/doc/elastic-cloud-serverless/) APIs.
32+
- **[](api-keys/elastic-cloud-enterprise-api-keys.md)**, to manage your {{ece}} platform and deployments using the [{{ece}}](https://www.elastic.co/docs/api/doc/cloud-enterprise/) API.

deploy-manage/api-keys/elastic-cloud-api-keys.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,31 @@
11
---
2+
applies_to:
3+
deployment:
4+
ess: ga
5+
serverless: ga
26
mapped_pages:
37
- https://www.elastic.co/guide/en/cloud/current/ec-api-authentication.html
48
---
59

6-
# Elastic Cloud API keys [ec-api-authentication]
10+
# {{ecloud}} API keys [ec-api-authentication]
711

8-
With a valid Elastic Cloud API key, you can access the API from its base URL at `api.elastic-cloud.com`.
12+
{{ecloud}} API keys allow you to use the [{{ecloud}}](https://www.elastic.co/docs/api/doc/cloud/) and [{{ecloud}} serverless](https://www.elastic.co/docs/api/doc/elastic-cloud-serverless/) APIs.
13+
14+
With a valid {{ecloud}} API key, you can access the API from its base URL at `api.elastic-cloud.com`.
915

1016
Only **Organization owners** can create and manage API keys. An API key is not tied to the user who created it. When creating a key, you assign it specific roles to control its access to organizational resources, including hosted deployments and serverless projects. If a user leaves the organization, the API keys they have created will still function until they expire.
1117

1218
You can have multiple API keys for different purposes, and you can revoke them when you no longer need them.
1319

20+
::::{note}
21+
These keys provides access to the API that enables you to manage your deployments. It does not provide access to {{es}}. To access {{es}} with an API key, create a key [in {{kib}}](elasticsearch-api-keys.md) or [using the {{es}} API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key).
22+
::::
1423

1524
## Create an API key [ec-api-keys]
1625

17-
1. Log in to the [Elasticsearch Service Console](https://cloud.elastic.co?page=docs&placement=docs-body).
26+
1. Log in to the [{{ecloud}} Console](https://cloud.elastic.co?page=docs&placement=docs-body).
1827
2. Go to your avatar in the upper right corner and choose **Organization**.
1928
3. On the API keys tab of the **Organization** page, click **Create API Key**.
20-
21-
::::{note}
22-
This key provides access to the API that enables you to manage your deployments. It does not provide access to {{es}}. To access {{es}} with an API key, create a key [in {{kib}}](elasticsearch-api-keys.md) or [using the {{es}} API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key).
23-
::::
24-
2529
4. From the **Create API Key** page, you can configure your new key by adding a name, set expiration, or assign [roles](../users-roles/cloud-organization/user-roles.md).
2630

2731
By default, API keys expire after three months. You can set the expiration to a different preset value or to a specific date, up to one year. If you need the key to work indefinitely, you can also set its expiration to Never. In this case, the key won’t expire.
@@ -41,7 +45,7 @@ Authorization: ApiKey $EC_API_KEY
4145

4246
## Revoke an API key [ec_revoke_an_api_key]
4347

44-
1. Log in to the [Elasticsearch Service Console](https://cloud.elastic.co?page=docs&placement=docs-body).
48+
1. Log in to the [{{ecloud}} Console](https://cloud.elastic.co?page=docs&placement=docs-body).
4549
2. Go to your avatar in the upper right corner and choose **Organization**.
4650

4751
The keys currently associated with your organization are listed under the API keys tab of the **Organization** page.

deploy-manage/api-keys/elastic-cloud-enterprise-api-keys.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
---
2+
applies_to:
3+
deployment:
4+
ece: ga
25
mapped_pages:
36
- https://www.elastic.co/guide/en/cloud-enterprise/current/ece-restful-api-authentication.html
47
---
58

6-
# Elastic Cloud Enterprise API keys [ece-restful-api-authentication]
7-
8-
::::{note}
9-
This documentation applies to the Elastic Cloud Enterprise API only. If you are using [Elasticsearch Service](https://cloud.elastic.co/home), check the [Elastic Cloud API information](https://www.elastic.co/guide/en/cloud/current/ec-restful-api.html) instead.
10-
::::
9+
# {{ece}} API keys [ece-restful-api-authentication]
1110

11+
The {{ece}} RESTful APIs support both key-based and token-based authentication. Key-based is generally the preferred method.
1212

13-
The Elastic Cloud Enterprise RESTful APIs support both key-based and token-based authentication. Key-based is generally the preferred method.
13+
{{ece}} API keys allow you to manage your {{ece}} platform and deployments using the [{{ece}}](https://www.elastic.co/docs/api/doc/cloud-enterprise/) API.
1414

1515

1616
## Authenticate using an API key [ece-api-keys]
1717

18-
For key-based API authentication, you can create an API key through the Elastic Cloud Enterprise UI. Once created, you can specify the key in the header of your API calls to authenticate.
18+
For key-based API authentication, you can create an API key through the {{ece}} UI. Once created, you can specify the key in the header of your API calls to authenticate.
1919

2020
::::{note}
2121
API keys are not available for the built-in users (`admin` and `readonly`). Therefore, the **API Keys** settings page on the UI does not appear for these users.
@@ -37,7 +37,7 @@ To create an API key:
3737

3838
The API key has the same permissions as the API key owner. You may have multiple API keys for different purposes and you can revoke them when you no longer need them.
3939

40-
Currently, API keys cannot be generated for the `admin` and `readonly` users that come pre-configured with your Elastic Cloud Enterprise installation.
40+
Currently, API keys cannot be generated for the `admin` and `readonly` users that come pre-configured with your {{ece}} installation.
4141

4242
To revoke an API key:
4343

@@ -48,7 +48,7 @@ To revoke an API key:
4848

4949
## Authenticate using a bearer token [ece-restful-api-authentication-token]
5050

51-
For token-based API authentication, you can use the same username and password that you use to log into the Cloud UI. If you want to use the credentials that were provided when you installed Elastic Cloud Enterprise on your first host, for example `admin`, you can [retrieve them separately](../users-roles/cloud-enterprise-orchestrator/manage-system-passwords.md#ece-retrieve-passwords).
51+
For token-based API authentication, you can use the same username and password that you use to log into the Cloud UI. If you want to use the credentials that were provided when you installed {{ece}} on your first host, for example `admin`, you can [retrieve them separately](../users-roles/cloud-enterprise-orchestrator/manage-system-passwords.md#ece-retrieve-passwords).
5252

5353
For operations that only read information, but don’t create, update or delete, you can authenticate with a user that has restricted permissions, such as the `readonly` user.
5454

deploy-manage/api-keys/elasticsearch-api-keys.md

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
11
---
2+
applies_to:
3+
stack: ga
24
mapped_pages:
35
- https://www.elastic.co/guide/en/kibana/current/api-keys.html
46
---
57

6-
# Elasticsearch API keys [api-keys]
8+
# {{es}} API keys [api-keys]
79

8-
API keys are security mechanisms used to authenticate and authorize access to {{es}} resources. They ensure that only authorized users or applications interact with {{es}}.
10+
Several types of {{es}} API keys exist:
911

10-
For example, if you extract data from an {{es}} cluster on a daily basis, you might create an API key tied to your credentials, configure it with minimum access, and then put the API credentials into a cron job. Or you might create API keys to automate ingestion of new data from remote sources, without a live user interaction.
12+
* **Personal/User** API key: allows external services to access the Elastic Stack on behalf of a user.
13+
* **Cross-cluster** API key: allows other clusters to connect to this cluster.
14+
* **Managed** API key: created and managed by Kibana to run background tasks.
1115

12-
You can use {{kib}} to manage your different API keys:
13-
14-
* User API key: allows external services to access the Elastic Stack on behalf of a user.
15-
* Cross-cluster API key: allows other clusters to connect to this cluster.
16-
* Managed API key: created and managed by Kibana to run background tasks.
17-
18-
To manage API keys, go to the **API Keys** management page using the navigation menu or the [global search field](../../explore-analyze/find-and-organize/find-apps-and-objects.md).
16+
To manage API keys in {{kib}}, go to the **API Keys** management page using the navigation menu or the [global search field](../../explore-analyze/find-and-organize/find-apps-and-objects.md).
1917

2018
![API Keys UI](../../images/kibana-api-keys.png "")
2119

@@ -37,18 +35,18 @@ To create an API key, go to the **API Keys** management page using the navigatio
3735

3836
![Create API Key UI](../../images/kibana-create-ccr-api-key.png "")
3937

40-
Refer to the [create API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key) documentation to learn more about creating user API keys.
38+
Refer to the [Create API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key) documentation to learn more about creating user API keys.
4139

42-
Refer to the [create cross-cluster API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-cross-cluster-api-key) documentation to learn more about creating cross-cluster API keys.
40+
Refer to the [Create cross-cluster API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-cross-cluster-api-key) documentation to learn more about creating cross-cluster API keys.
4341

4442

4543
## Update an API key [udpate-api-key]
4644

4745
To update an API key, go to the **API Keys** management page using the navigation menu or the [global search field](../../explore-analyze/find-and-organize/find-apps-and-objects.md), and then click on the name of the key. You cannot update the name or the type of API key.
4846

49-
Refer to the [update API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-api-key) documentation to learn more about updating user API keys.
47+
Refer to the [Update API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-api-key) documentation to learn more about updating user API keys.
5048

51-
Refer to the [update cross-cluster API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-cross-cluster-api-key) documentation to learn more about updating cross-cluster API keys.
49+
Refer to the [Update cross-cluster API key](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-cross-cluster-api-key) documentation to learn more about updating cross-cluster API keys.
5250

5351

5452
## View and delete API keys [view-api-keys]

deploy-manage/api-keys/serverless-project-api-keys.md

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
11
---
2+
applies_to:
3+
serverless: ga
24
mapped_pages:
35
- https://www.elastic.co/guide/en/serverless/current/api-keys.html
46
---
57

68
# Serverless project API keys [api-keys]
79

8-
This content applies to: [![Elasticsearch](../../images/serverless-es-badge.svg "")](../../solutions/search.md) [![Observability](../../images/serverless-obs-badge.svg "")](../../solutions/observability.md) [![Security](../../images/serverless-sec-badge.svg "")](../../solutions/security/elastic-security-serverless.md)
10+
In serverless projects, the following types of API keys exist:
911

10-
API keys are security mechanisms used to authenticate and authorize access to {{stack}} resources, and ensure that only authorized users or applications are able to interact with the {{stack}}.
11-
12-
For example, if you extract data from an {{es}} cluster on a daily basis, you might create an API key tied to your credentials, configure it with minimum access, and then put the API credentials into a cron job. Or, you might create API keys to automate ingestion of new data from remote sources, without a live user interaction.
12+
- **Personal** API keys, that you can create to allow external services to access your serverless project on behalf of a user.
13+
- **Managed** API keys, created and managed by {{kib}} to correctly run background tasks.
1314

1415
You can manage your keys in **{{project-settings}} → {{manage-app}} → {{api-keys-app}}**:
1516

@@ -18,10 +19,6 @@ You can manage your keys in **{{project-settings}} → {{manage-app}} → {{api-
1819
:class: screenshot
1920
:::
2021

21-
A *personal API key* allows external services to access the {{stack}} on behalf of a user.
22-
23-
A *managed API key* is created and managed by {{kib}} to correctly run background tasks.
24-
2522

2623
## Create an API key [api-keys-create-an-api-key]
2724

@@ -30,6 +27,7 @@ In **{{api-keys-app}}**, click **Create API key**:
3027
:::{image} ../../images/serverless-create-personal-api-key.png
3128
:alt: Create API key UI
3229
:class: screenshot
30+
:width: 50%
3331
:::
3432

3533
Once created, you can copy the encoded API key and use it to send requests to the {{es}} HTTP API. For example:
@@ -72,7 +70,7 @@ For example, the following `role_descriptors` object defines a `books-read-only`
7270
}
7371
```
7472

75-
For the `role_descriptors` object schema, check out the [`/_security/api_key` endpoint](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key) docs. For supported privileges, check [Security privileges](../users-roles/cluster-or-deployment-auth/elasticsearch-privileges.md#privileges-list-indices).
73+
For the `role_descriptors` object schema, check out the [`/_security/api_key` endpoint](https://www.elastic.co/docs/api/doc/elasticsearch-serverless/operation/operation-security-create-api-key) docs. For supported privileges, check [Security privileges](../users-roles/cluster-or-deployment-auth/elasticsearch-privileges.md#privileges-list-indices).
7674

7775

7876
## Update an API key [api-keys-update-an-api-key]

0 commit comments

Comments
 (0)