# Clusters

Cluster management

## List clusters

> Lists all clusters

```json
{"openapi":"3.0.3","info":{"title":"OpenStack Block Storage API (Cinder)","version":"3.71"},"tags":[{"name":"clusters","description":"Cluster management"}],"servers":[{"url":"https://example.com/v3","description":"Block Storage API v3 endpoint"}],"security":[{"ApiKeyAuth":[]},{"BearerAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","description":"OpenStack authentication token","name":"X-Auth-Token","in":"header"},"BearerAuth":{"scheme":"bearer","type":"http","description":"OpenStack authentication token as Bearer token"}},"parameters":{"LimitQuery":{"name":"limit","description":"Requests a page size of items","schema":{"minimum":1,"type":"integer"},"in":"query"},"MarkerQuery":{"name":"marker","description":"The ID of the last-seen item","schema":{"type":"string"},"in":"query"},"SortQuery":{"name":"sort","description":"Comma-separated list of sort keys and optional sort directions","schema":{"type":"string"},"in":"query"},"SortKeyQuery":{"name":"sort_key","description":"Sorts by an attribute","schema":{"type":"string"},"in":"query"},"SortDirQuery":{"name":"sort_dir","description":"Sorts by direction (asc or desc)","schema":{"enum":["asc","desc"],"type":"string"},"in":"query"}},"schemas":{"Clusters":{"type":"object","properties":{"clusters":{"type":"array","items":{"$ref":"#/components/schemas/ClusterSimple"}}}},"ClusterSimple":{"type":"object","properties":{"name":{"description":"The cluster name","type":"string"},"binary":{"description":"The binary name","type":"string"},"state":{"description":"The cluster state","type":"string"},"status":{"description":"The cluster status","type":"string"}}}}},"paths":{"/v3/clusters":{"get":{"tags":["clusters"],"parameters":[{"name":"name","description":"Filter by cluster name","schema":{"type":"string"},"in":"query"},{"name":"binary","description":"Filter by binary","schema":{"type":"string"},"in":"query"},{"name":"disabled","description":"Filter by disabled status","schema":{"type":"boolean"},"in":"query"},{"name":"num_hosts","description":"Filter by number of hosts","schema":{"type":"integer"},"in":"query"},{"name":"num_down_hosts","description":"Filter by number of down hosts","schema":{"type":"integer"},"in":"query"},{"name":"is_up","description":"Filter by up status","schema":{"type":"boolean"},"in":"query"},{"$ref":"#/components/parameters/LimitQuery"},{"$ref":"#/components/parameters/MarkerQuery"},{"$ref":"#/components/parameters/SortQuery"},{"$ref":"#/components/parameters/SortKeyQuery"},{"$ref":"#/components/parameters/SortDirQuery"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Clusters"}}},"description":"OK"}},"summary":"List clusters","description":"Lists all clusters"}}}}
```

## Update cluster

> Updates a cluster

```json
{"openapi":"3.0.3","info":{"title":"OpenStack Block Storage API (Cinder)","version":"3.71"},"tags":[{"name":"clusters","description":"Cluster management"}],"servers":[{"url":"https://example.com/v3","description":"Block Storage API v3 endpoint"}],"security":[{"ApiKeyAuth":[]},{"BearerAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","description":"OpenStack authentication token","name":"X-Auth-Token","in":"header"},"BearerAuth":{"scheme":"bearer","type":"http","description":"OpenStack authentication token as Bearer token"}},"schemas":{"ClusterUpdateRequest":{"type":"object","properties":{"cluster":{"type":"object","properties":{"disabled":{"description":"Whether to disable the cluster","type":"boolean"},"disabled_reason":{"description":"Reason for disabling","type":"string"}}}}},"ClusterResponse":{"type":"object","properties":{"cluster":{"$ref":"#/components/schemas/Cluster"}}},"Cluster":{"type":"object","properties":{"name":{"description":"The cluster name","type":"string"},"binary":{"description":"The binary name","type":"string"},"state":{"description":"The cluster state","type":"string"},"status":{"description":"The cluster status","type":"string"},"num_hosts":{"description":"Number of hosts in the cluster","type":"integer"},"num_down_hosts":{"description":"Number of down hosts in the cluster","type":"integer"},"last_heartbeat":{"nullable":true,"format":"date-time","description":"Last heartbeat timestamp","type":"string"},"disabled_reason":{"nullable":true,"description":"Reason for disabling cluster","type":"string"},"created_at":{"format":"date-time","description":"The date and time when the resource was created","type":"string"},"updated_at":{"nullable":true,"format":"date-time","description":"The date and time when the resource was updated","type":"string"}}}}},"paths":{"/v3/clusters":{"put":{"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterUpdateRequest"}}},"required":true},"tags":["clusters"],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}},"description":"OK"}},"summary":"Update cluster","description":"Updates a cluster"}}}}
```

## List clusters with details

> Lists all clusters with details

```json
{"openapi":"3.0.3","info":{"title":"OpenStack Block Storage API (Cinder)","version":"3.71"},"tags":[{"name":"clusters","description":"Cluster management"}],"servers":[{"url":"https://example.com/v3","description":"Block Storage API v3 endpoint"}],"security":[{"ApiKeyAuth":[]},{"BearerAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","description":"OpenStack authentication token","name":"X-Auth-Token","in":"header"},"BearerAuth":{"scheme":"bearer","type":"http","description":"OpenStack authentication token as Bearer token"}},"parameters":{"LimitQuery":{"name":"limit","description":"Requests a page size of items","schema":{"minimum":1,"type":"integer"},"in":"query"},"MarkerQuery":{"name":"marker","description":"The ID of the last-seen item","schema":{"type":"string"},"in":"query"},"SortQuery":{"name":"sort","description":"Comma-separated list of sort keys and optional sort directions","schema":{"type":"string"},"in":"query"},"SortKeyQuery":{"name":"sort_key","description":"Sorts by an attribute","schema":{"type":"string"},"in":"query"},"SortDirQuery":{"name":"sort_dir","description":"Sorts by direction (asc or desc)","schema":{"enum":["asc","desc"],"type":"string"},"in":"query"}},"schemas":{"ClustersDetail":{"type":"object","properties":{"clusters":{"type":"array","items":{"$ref":"#/components/schemas/Cluster"}}}},"Cluster":{"type":"object","properties":{"name":{"description":"The cluster name","type":"string"},"binary":{"description":"The binary name","type":"string"},"state":{"description":"The cluster state","type":"string"},"status":{"description":"The cluster status","type":"string"},"num_hosts":{"description":"Number of hosts in the cluster","type":"integer"},"num_down_hosts":{"description":"Number of down hosts in the cluster","type":"integer"},"last_heartbeat":{"nullable":true,"format":"date-time","description":"Last heartbeat timestamp","type":"string"},"disabled_reason":{"nullable":true,"description":"Reason for disabling cluster","type":"string"},"created_at":{"format":"date-time","description":"The date and time when the resource was created","type":"string"},"updated_at":{"nullable":true,"format":"date-time","description":"The date and time when the resource was updated","type":"string"}}}}},"paths":{"/v3/clusters/detail":{"get":{"tags":["clusters"],"parameters":[{"name":"name","description":"Filter by cluster name","schema":{"type":"string"},"in":"query"},{"name":"binary","description":"Filter by binary","schema":{"type":"string"},"in":"query"},{"name":"disabled","description":"Filter by disabled status","schema":{"type":"boolean"},"in":"query"},{"name":"num_hosts","description":"Filter by number of hosts","schema":{"type":"integer"},"in":"query"},{"name":"num_down_hosts","description":"Filter by number of down hosts","schema":{"type":"integer"},"in":"query"},{"name":"is_up","description":"Filter by up status","schema":{"type":"boolean"},"in":"query"},{"$ref":"#/components/parameters/LimitQuery"},{"$ref":"#/components/parameters/MarkerQuery"},{"$ref":"#/components/parameters/SortQuery"},{"$ref":"#/components/parameters/SortKeyQuery"},{"$ref":"#/components/parameters/SortDirQuery"}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClustersDetail"}}},"description":"OK"}},"summary":"List clusters with details","description":"Lists all clusters with details"}}}}
```

## Show cluster details

> Shows details for a cluster

```json
{"openapi":"3.0.3","info":{"title":"OpenStack Block Storage API (Cinder)","version":"3.71"},"tags":[{"name":"clusters","description":"Cluster management"}],"servers":[{"url":"https://example.com/v3","description":"Block Storage API v3 endpoint"}],"security":[{"ApiKeyAuth":[]},{"BearerAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","description":"OpenStack authentication token","name":"X-Auth-Token","in":"header"},"BearerAuth":{"scheme":"bearer","type":"http","description":"OpenStack authentication token as Bearer token"}},"schemas":{"ClusterResponse":{"type":"object","properties":{"cluster":{"$ref":"#/components/schemas/Cluster"}}},"Cluster":{"type":"object","properties":{"name":{"description":"The cluster name","type":"string"},"binary":{"description":"The binary name","type":"string"},"state":{"description":"The cluster state","type":"string"},"status":{"description":"The cluster status","type":"string"},"num_hosts":{"description":"Number of hosts in the cluster","type":"integer"},"num_down_hosts":{"description":"Number of down hosts in the cluster","type":"integer"},"last_heartbeat":{"nullable":true,"format":"date-time","description":"Last heartbeat timestamp","type":"string"},"disabled_reason":{"nullable":true,"description":"Reason for disabling cluster","type":"string"},"created_at":{"format":"date-time","description":"The date and time when the resource was created","type":"string"},"updated_at":{"nullable":true,"format":"date-time","description":"The date and time when the resource was updated","type":"string"}}}}},"paths":{"/v3/clusters/{cluster_id}":{"get":{"tags":["clusters"],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClusterResponse"}}},"description":"OK"}},"summary":"Show cluster details","description":"Shows details for a cluster"}}}}
```
