---
type: api
title: Get Watcher index settings
description: Get settings for the Watcher internal index (`.watches`).
url: https://www.elastic.co/elastic/docs-builder/docs/4493/api/doc/elasticsearch/v9/operation/operation-watcher-get-settings
resource: https://www.elastic.co/elastic/docs-builder/docs/4493/api/doc/elasticsearch/v9/operation/operation-watcher-get-settings
products:
  - Elasticsearch
---

# Get Watcher index settings

## Paths

- `GET` `/_watcher/settings`

## Description

Get settings for the Watcher internal index (`.watches`).
Only a subset of settings are shown, for example `index.auto_expand_replicas` and `index.number_of_replicas`.

## Authentication

- Api key: `Authorization: <value>`
  Elasticsearch APIs support key-based authentication.
  You must create an API key and use the encoded value in the request header.
  For example:
  
  
  ```
  curl -X GET "${ES_URL}/_cat/indices?v=true" \
    -H "Authorization: ApiKey ${API_KEY}"
  ```
  
  To get API keys, use the `/_security/api_key` APIs.
- Basic: `Authorization: Basic <credentials>`
- Bearer: `Authorization: Bearer <token>`
  Elasticsearch APIs support the use of bearer tokens in the `Authorization` HTTP header to authenticate with the API.
  For examples, refer to [Token-based authentication services](https://www.elastic.co/docs/deploy-manage/users-roles/cluster-or-deployment-auth/token-based-authentication-services)

## 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.

## Response

`application/json`

- `index` (object)
## Code examples

#### Console

```console
GET /_watcher/settings
```

#### JavaScript

```javascript
const response = await client.watcher.getSettings();
```

#### Python

```python
resp = client.watcher.get_settings()
```

#### curl

```curl
curl -X GET "$ELASTICSEARCH_URL/_watcher/settings" \
  -H "Authorization: ApiKey $ELASTIC_API_KEY"
```

#### Java

```java
client.watcher().getSettings(g -> g);
```

#### PHP

```php
$resp = $client->watcher()->getSettings();
```

#### Ruby

```ruby
response = client.watcher.get_settings
```

## Response examples

#### Watcher get settings response example1

A successful response with two index settings.

```json
{
  "index": {
    "auto_expand_replicas": "0-4",
    "number_of_replicas": 0
  }
}
```

