General
All Cluster Statuses
Returns an array of Cluster Statuses
GET
/
v2.5
/
api
/
k8s
/
cluster_statuses
cURL
curl -sk -X GET "https://<controller>/v2.5/api/k8s/cluster_statuses" \
-H "Authorization: cid <CID>"import requests
url = "https://<controller>/v2.5/api/k8s/cluster_statuses"
headers = {"Authorization": "cid <CID>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://<controller>/v2.5/api/k8s/cluster_statuses", nil)
req.Header.Set("Authorization", "cid <CID>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println(resp.Status)
}[
{
"cluster_id": "arn:aws:eks:us-east-1:123456789012:cluster/cluster1",
"fetcherStatus": "RUNNING",
"resource": {
"account_id": 123456789012,
"account_names": [
"aws_account"
],
"name": "test-cluster",
"network_mode": "OVERLAY",
"platform": "EKS",
"public": true,
"region": "us-east-1",
"tags": [
{
"key": "key",
"value": "value"
},
{
"key": "key",
"value": "value"
}
],
"version": 1.3,
"vpc_id": "vpc-12345678901234567"
},
"resourceTypeStatus": {
"RESOURCE_TYPE_K8S_ENDPOINT_NODE": {
"count": 3
},
"RESOURCE_TYPE_K8S_ENDPOINT_SLICE": {
"count": 4
},
"RESOURCE_TYPE_K8S_NAMESPACE": {
"count": 4
},
"RESOURCE_TYPE_K8S_POD": {
"count": 35
},
"RESOURCE_TYPE_K8S_SERVICE": {
"count": 10,
"lastError": "something went wrong",
"lastErrorTimestamp": "2022-01-01T12:34:56Z"
}
},
"userEnabled": true
}
]{
"message": "<string>"
}Headers
Controller ID in the format: cid .
Example:
"cid <CID>"
Response
Successful operation
Available options:
UNKNOWN, SYNCHRONIZING, RUNNING, STOPPING, STOPPED Show child attributes
Show child attributes
Example:
{
"account_id": "account_id",
"account_name": "account_name",
"compartment": "compartment",
"name": "name",
"network_mode": "OVERLAY",
"platform": "platform",
"project": "project",
"public": true,
"region": "region",
"tags": [
{ "key": "key", "value": "value" },
{ "key": "key", "value": "value" }
],
"version": "version",
"vpc_id": "vpc_id"
}
Show child attributes
Show child attributes
Was this page helpful?
⌘I
cURL
curl -sk -X GET "https://<controller>/v2.5/api/k8s/cluster_statuses" \
-H "Authorization: cid <CID>"import requests
url = "https://<controller>/v2.5/api/k8s/cluster_statuses"
headers = {"Authorization": "cid <CID>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://<controller>/v2.5/api/k8s/cluster_statuses", nil)
req.Header.Set("Authorization", "cid <CID>")
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
fmt.Println(resp.Status)
}[
{
"cluster_id": "arn:aws:eks:us-east-1:123456789012:cluster/cluster1",
"fetcherStatus": "RUNNING",
"resource": {
"account_id": 123456789012,
"account_names": [
"aws_account"
],
"name": "test-cluster",
"network_mode": "OVERLAY",
"platform": "EKS",
"public": true,
"region": "us-east-1",
"tags": [
{
"key": "key",
"value": "value"
},
{
"key": "key",
"value": "value"
}
],
"version": 1.3,
"vpc_id": "vpc-12345678901234567"
},
"resourceTypeStatus": {
"RESOURCE_TYPE_K8S_ENDPOINT_NODE": {
"count": 3
},
"RESOURCE_TYPE_K8S_ENDPOINT_SLICE": {
"count": 4
},
"RESOURCE_TYPE_K8S_NAMESPACE": {
"count": 4
},
"RESOURCE_TYPE_K8S_POD": {
"count": 35
},
"RESOURCE_TYPE_K8S_SERVICE": {
"count": 10,
"lastError": "something went wrong",
"lastErrorTimestamp": "2022-01-01T12:34:56Z"
}
},
"userEnabled": true
}
]{
"message": "<string>"
}