---
title: "Exposing your logs to third-party tools via the OpenSearch API"
description: "Leverage any software that can use the OpenSearch API by using aliases."
url: https://docs.ovhcloud.com/de/guides/manage-and-operate/observability/logs-data-platform/integration-opensearch
lang: de
lastUpdated: 2025-12-17
---
# Exposing your logs to third-party tools via the OpenSearch API

## Objective

As explained in our [introductory documentation](/de/guides/manage-and-operate/observability/logs-data-platform/introduction.md), Logs Data Platform heavily relies on [OpenSearch](https://github.com/opensearch-project/OpenSearch) to work. OpenSearch has a rich ecosystem and allows very complex queries.

**This documentation explains how to use third‑party softwares that integrate with OpenSearch by using aliases.**

## Requirements

- Access to the <ManagerLink to="/">OVHcloud Control Panel</ManagerLink>
- A [Logs Data Platform account](https://www.ovhcloud.com/de/identity-security-operations/logs-data-platform/)

## Instructions

### What is a Logs Data Platform alias?

As explained in the documentation mentioned above, a Logs Data Platform _alias_ is a virtual OpenSearch _index_. You can attach multiple _indices_ **or** multiple log _streams_ to an _alias_ (but not a mix of _indices_ and _streams_). In both cases, _aliases_ are read‑only.

### Alias configuration

When attached to _streams_ or _indices_, an _alias_ allows you to expose the content of your _streams_ exactly as if they were stored in a single OpenSearch _index_. This feature can be used only for read/query purposes.

:::info
If you want to ingest logs to a _stream_ using the OpenSearch API, we provide a shared input that works as a special _index_ pre‑configured for this purpose and accessible to any Logs Data Platform user.
You can follow [this documentation](/de/guides/manage-and-operate/observability/logs-data-platform/ldp-index.md) to use it.

:::

#### Creating an alias

To create an _alias_
 in the management interface, go to the `Alias
` section of your Logs Data Platform account as shown in this picture:
![Logs Data Platform homepage alias button location](/images/manage-and-operate/observability/logs-data-platform/integration-opensearch-api/ldp-homepage-circled.png)
It should look like this:

![Logs Data Platform alias section](/images/manage-and-operate/observability/logs-data-platform/integration-opensearch-api/alias-homepage-circled.png)
In this section, you can:

- Create a new alias by clicking on the <code className="action">Add an alias</code> button.

![Logs Data Platform homepage alias creation](/images/manage-and-operate/observability/logs-data-platform/integration-opensearch-api/alias-create-blurred.png)
- Once created, you can edit the description, access the alias via the OpenSearch web UI or delete the alias via the <code className="action">...</code> button.

#### Attach an alias to a stream

- Attach and detach _streams_ and/or _indices_ to an alias by clicking the <code className="action">...</code> button and then on the <code className="action">Attach content to the alias</code> button.
- Then you choose the stream you want to attach to the alias.

![Logs Data Platform alias content attachment](/images/manage-and-operate/observability/logs-data-platform/integration-opensearch-api/alias-attach-blurred.png)
#### Attach an alias to an index

If you use the [managed OpenSearch index as a service feature](/de/guides/manage-and-operate/observability/logs-data-platform/index-as-a-service.md), you can also attach multiple _indices_ to an _alias_. In that case, attach the alias and configure it as described below.

- Attach and detach _streams_ and/or _indices_ to an alias by clicking  the <code className="action">...</code> button and then on the <code className="action">Attach content to the alias</code> button.
- Then you choose the indices tab you want to attach to the alias.
- Finally you select the indices you want to attach to the alias.

#### Retrieving credentials

**IAM‑enabled accounts**

[IAM enabled accounts](/de/guides/manage-and-operate/observability/logs-data-platform/overview.md) have two ways to obtain credentials for both OVHcloud APIs and Logs Data Platform data planes APIs:

- **Personal Access Token (PAT)** for a local user: [generate a token](/de/guides/manage-and-operate/observability/logs-data-platform/tokens.md) via the IAM console or API.
- **Service account token**: obtained by first creating a [service account](/de/guides/manage-and-operate/api/manage-service-account.md) and using the OAuth2 client‑credentials flow.

Both tokens can be used as a **bearer token** or with a **basic authentication scheme** by using `pat_jwt_<your_suffix>` as a username. Replace `<your_suffix>` with any ASCII string of your choosing.

**Legacy (non‑IAM) accounts**

- Use the traditional `<username>` and `<password>` or a legacy token generated from the Logs Data Platform UI.

### Alias access management

Like all features of Logs Data Platform, with IAM enabled, aliases can be shared with other OVHcloud identities. If you are not familiar with IAM, we encourage you to read the [IAM documentation](/de/guides/account-and-service-management/account-information/iam-policy-ui.md) and the specific Logs Data Platform [IAM access management](/de/guides/manage-and-operate/observability/logs-data-platform/overview.md).

The rights relative to the management of OpenSearch aliases through the **OVHcloud APIs** are:

| Rights                                           | LDP product types | Description                                                              |
| ------------------------------------------------ | ----------------- | ------------------------------------------------------------------------ |
| ldp:apiovh:url/get                               | service           | Get Logs Data Platform service useful urls                               |
| ldp:apiovh:output/opensearch/alias/create        | service           | Create a new OpenSearch alias over OVHcloud API                          |
| ldp:apiovh:output/opensearch/alias/url/get       | alias             | Get urls of an OpenSearch alias over OVHcloud API                        |
| ldp:apiovh:output/opensearch/alias/get           | alias             | Get OpenSearch aliases over OVHcloud API                                 |
| ldp:apiovh:output/opensearch/alias/edit          | alias             | Update an OpenSearch alias over OVHcloud API                             |
| ldp:apiovh:output/opensearch/alias/index/get     | alias             | Get OpenSearch indexes attached to an OpenSearch alias over OVHcloud API |
| ldp:apiovh:output/opensearch/alias/index/attach  | alias             | Attach an OpenSearch index to an OpenSearch alias over OVHcloud API      |
| ldp:apiovh:output/opensearch/alias/index/detach  | alias             | Detach an OpenSearch index from an OpenSearch alias over OVHcloud API    |
| ldp:apiovh:output/opensearch/alias/stream/get    | alias             | Get streams attached to an OpenSearch alias over OVHcloud API            |
| ldp:apiovh:output/opensearch/alias/stream/attach | alias             | Attach a stream to an OpenSearch alias over OVHcloud API                 |
| ldp:apiovh:output/opensearch/alias/stream/detach | alias             | Detach a stream from an OpenSearch alias over OVHcloud API               |
| ldp:apiovh:output/opensearch/alias/delete        | alias             | Delete an OpenSearch alias over OVHcloud API                             |

The rights relative to the management of OpenSearch aliases through the **OpenSearch API** are:

| Rights                      | LDP product types | Description                                  |
| --------------------------- | ----------------- | -------------------------------------------- |
| ldp:opensearch:alias/delete | alias             | Delete an alias over OpenSearch API          |
| ldp:opensearch:alias/create | alias             | Create an alias over OpenSearch API          |
| ldp:opensearch:alias/read   | alias             | Read an alias's contents over OpenSearch API |

There is no write related right because aliases are **read-only**.

Legacy users can use [this documentation](/de/guides/manage-and-operate/observability/logs-data-platform/getting-started-roles-permission.md).

### Quick recap guide to configure alias access

1\. **Create a local user**

To create a local user, go to the Identities
 page. Complete the required fields and click `Confirm
` to create the user.
Navigate to the [dedicated documentation](/de/guides/account-and-service-management/account-information/ovhcloud-users-management.md) for more information about users.

2\. **Generate a PAT**

A [Personal Access Token](/de/guides/manage-and-operate/observability/logs-data-platform/tokens.md) is needed to interact with the Logs Data Platform or OVHcloud API when using a local user. As said in the corresponding guide, you can create one by using the API:


🇪🇺EU▾

[POST/me/identity/user/{user}/token](https://eu.api.ovh.com/console/?section=/me&branch=v1#post-/me/identity/user/-user-/token)

The response contains an `access_token` field which is your PAT.

3\. **Create the IAM Policy**

[IAM policies](/de/guides/manage-and-operate/observability/logs-data-platform/overview.md) allow an identity to interact with Logs Data Platform resources. Create or modify an existing policy and add the corresponding rights for your local user.

Read the guide or the IAM documentation for detailed information on this feature. Don't forget to add your new alias as a resource managed by this IAM policy.

Make sure to separate service rights and specific aliases rights in different policies if needed since all aliases inherit the rights put on a Logs Data Service (ie: putting `ldp:opensearch:alias/read` on a service policy gives read rights to **all aliases of this service**).

4\. **Query the alias** using the bearer token:

```bash
curl -H "Authorization: Bearer <access_token>" \
    "https://<your_cluster>.logs.ovh.com:9200/`<service_name>`-a-<alias>/_search?pretty"
```

Or alternatively use the hybrid authentication mechanism:

```bash
curl -u "pat_jwt_<any_suffix>:<access_token>" \
    "https://<your_cluster>.logs.ovh.com:9200/`<service_name>`-a-<alias>/_search?pretty"
```

**Legacy user example (for reference only)**

```bash
curl -u logs-ab-12345:<password> \
     "https://<your_cluster>.logs.ovh.com:9200/`<username>`-a-<alias>/_search?pretty"
```

### Third-party tool configuration

To connect to your alias as if it were an OpenSearch index, third-party tools usually require some information:

- A URL/Port: this is your cluster's URL, found on your Logs Data Platform account homepage under the "Access point" name in the "Configuration" section. The port is **9200** for OpenSearch. The resulting URL should be `https://<your_cluster>.logs.ovh.com:9200`.
- An index name. This is your alias name, found on the left column of your alias homepage like in the following picture. It should look like this: `<ldp_service_name>-a-<alias_name>`.

![Logs Data Platform alias name](/images/manage-and-operate/observability/logs-data-platform/integration-opensearch-api/alias-name.png)
- A user: `pat_jwt_<your_suffix>` a string starting with `pat_jwt_` as the username.
- A password: the `access_token` obtained via local users or via OAuth2 flow.

### Use cases

We currently have specific documentation illustrating the usage of _aliases_ in three cases:

- Using our managed OpenSearch Dashboards instances to visualize logs: [here](/de/guides/manage-and-operate/observability/logs-data-platform/opensearch-dashboards.md).
- Using Grafana to visualize logs: [here](/de/guides/manage-and-operate/observability/logs-data-platform/using-grafana-with-logs.md).
- Using ElastAlert to set up alerting on logs: [here](/de/guides/manage-and-operate/observability/logs-data-platform/elastalert.md).

## Go further

- [Introduction to Logs Data Platform](/de/guides/manage-and-operate/observability/logs-data-platform/introduction.md)
- [Getting Started with Logs Data Platform](/de/guides/manage-and-operate/observability/logs-data-platform/getting-started-quick-start.md)
- [Our documentation](/de/guides/manage-and-operate/observability/logs-data-platform/overview.md)
- Community hub: [community of users](https://community.ovhcloud.com/)
- Create an account: [Try it!](https://www.ovhcloud.com/de/identity-security-operations/logs-data-platform/)
