Get snapshot repository API

Gets information about one or more registered snapshot repositories.

  1. GET /_snapshot/my_repository

Request

GET /_snapshot/<repository>

GET /_snapshot

Path parameters

<repository>

(Required, string) Comma-separated list of snapshot repository names used to limit the request. Wildcard (*) expressions are supported.

To get information about all snapshot repositories registered in the cluster, omit this parameter or use * or _all.

Query parameters

local

(Optional, boolean) If true, the request gets information from the local node only. If false, the request gets information from the master node. Defaults to false.

master_timeout

(Optional, time units) Specifies the period of time 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. Defaults to 30s.

Response body

<repository>

(object) Contains information about the snapshot repository. Key is the name of the snapshot repository.

Properties of <repository>

  1. More repository types are available through these official plugins:
  2. - [repository-s3](https://www.elastic.co/guide/en/elasticsearch/plugins/current/repository-s3.html) for S3 repository support
  3. - [repository-hdfs](https://www.elastic.co/guide/en/elasticsearch/plugins/current/repository-hdfs.html) for HDFS repository support in Hadoop environments
  4. - [repository-azure](https://www.elastic.co/guide/en/elasticsearch/plugins/current/repository-azure.html) for Azure storage repositories
  5. - [repository-gcs](https://www.elastic.co/guide/en/elasticsearch/plugins/current/repository-gcs.html) for Google Cloud Storage repositories
  6. `settings`
  7. (object) Contains settings for the repository. Valid properties for the `settings` object depend on the repository type, set using the [`type`]($dc3b4a817e87b963.md#put-snapshot-repo-api-request-type) parameter.
  8. For properties, see the [put snapshot repository API]($dc3b4a817e87b963.md "Put snapshot repository API")'s [`settings` parameter]($dc3b4a817e87b963.md#put-snapshot-repo-api-settings-param).

Examples

  1. GET /_snapshot/my_repository

The API returns the following response:

  1. {
  2. "my_repository" : {
  3. "type" : "fs",
  4. "settings" : {
  5. "location" : "my_backup_location"
  6. }
  7. }
  8. }