in src/Endpoints/Snapshot.php [490:510]
public function status(?array $params = null)
{
$params = $params ?? [];
if (isset($params['repository']) && isset($params['snapshot'])) {
$url = '/_snapshot/' . $this->encode($params['repository']) . '/' . $this->encode($this->convertValue($params['snapshot'])) . '/_status';
$method = 'GET';
} elseif (isset($params['repository'])) {
$url = '/_snapshot/' . $this->encode($params['repository']) . '/_status';
$method = 'GET';
} else {
$url = '/_snapshot/_status';
$method = 'GET';
}
$url = $this->addQueryString($url, $params, ['master_timeout','ignore_unavailable','pretty','human','error_trace','source','filter_path']);
$headers = [
'Accept' => 'application/json',
];
$request = $this->createRequest($method, $url, $headers, $params['body'] ?? null);
$request = $this->addOtelAttributes($params, ['repository', 'snapshot'], $request, 'snapshot.status');
return $this->client->sendRequest($request);
}