---
type: api
title: Disable a named stream
description: Turn off the named stream feature for this cluster.
url: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/elasticsearch/operation/operation-streams-logs-disable
resource: https://www.elastic.co/elastic/docs-builder/docs/4641/api/doc/elasticsearch/operation/operation-streams-logs-disable
products:
  - Elasticsearch
---

# Disable a named stream

Authentication: required

Availability: Experimental since 9.1

## Paths

- `POST` `/_streams/{name}/_disable`

#### Path parameters

- `name` (enum) — required
  The stream type to disable.

Supported values include:
  - `logs`: The logs stream type.
  - `logs.otel`: The logs.otel stream type, meant for OTel-formatted data.
  - `logs.ecs`: The logs.ecs stream type, meant for ECS-formatted data.
  Values: `logs`, `logs.otel`, `logs.ecs`

## Description

Turn off the named stream feature for this cluster.

## Required authorization

- Cluster privileges: `manage`

## Query string parameters

- `master_timeout` (string · default: 30s) — optional
  The period to wait for a connection to the master node.
If no response is received before the timeout expires, the request fails and returns an error.
- `timeout` (string · default: 30s) — optional
  The period to wait for a response.
If no response is received before the timeout expires, the request fails and returns an error.

## Response

`application/json`

- `acknowledged` (boolean)
  For a successful response, this value is always true. On failure, an exception is returned instead.
## Code examples

#### Console

```console
POST _streams/logs.otel/_disable
```

#### JavaScript

```javascript
const response = await client.streams.logsDisable({
  name: "logs.otel",
});
```

#### Python

```python
resp = client.streams.logs_disable(
    name="logs.otel",
)
```

#### curl

```curl
curl -X POST "$ELASTICSEARCH_URL/_streams/logs.otel/_disable" \
  -H "Authorization: ApiKey $ELASTIC_API_KEY"
```

#### Java

```java
client.streams().logsDisable(l -> l);
```

#### C#

```c#
var response = await client.Streams.LogsDisableAsync(name: StreamType.LogsOtel);
```

#### PHP

```php
$resp = $client->streams()->logsDisable([
    "name" => "logs.otel",
]);
```

#### Ruby

```ruby
response = client.streams.logs_disable(
  name: "logs.otel"
)
```

## Response examples

#### Disable logs.otel streams

`application/json`

A successful response from `POST _streams/logs.otel/_disable` endpoint

```json
{
  "acknowledged": true
}
```

