跳到正文
本页尚未翻译成中文,以下为英文原文。 查看英文版

Get snapshot repository. ​

Introduced 1.0

Retrieves information about a snapshot repository.

To learn more about repositories, see Register repository.

NOTE

You can also get details about a snapshot during and after snapshot creation. See Get snapshot status.

Path parameters ​

ParameterData typeDescription
repositoryStringA comma-separated list of snapshot repository names to retrieve. Wildcard (*) expressions are supported including combining wildcards with exclude patterns starting with -.

Query parameters ​

ParameterData typeDescription
localBooleanWhether to get information from the local node. Optional, defaults to false.
cluster_manager_timeoutTimeAmount of time to wait for a connection to the master node. Optional, defaults to 30 seconds.

Example request ​

The following request retrieves information for the my-opensearch-repo repository:

json
GET /_snapshot/my-opensearch-repo

Example response ​

Upon success, the response returns repositry information. This sample is for an s3 repository type.

json
{
  "my-opensearch-repo" : {
    "type" : "s3",
    "settings" : {
      "bucket" : "my-open-search-bucket",
      "base_path" : "snapshots"
    }
  }
}

Response fields ​

FieldData typeDescription
typestringBucket type: fs (file system) or s3 (s3 bucket)
bucketstringS3 bucket name.
base_pathstringFolder within the bucket where snapshots are stored.