curl --request GET \
--url https://api.astronomer.io/v1/organizations/{organizationId}/clusters \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.astronomer.io/v1/organizations/{organizationId}/clusters"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.astronomer.io/v1/organizations/{organizationId}/clusters', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.astronomer.io/v1/organizations/{organizationId}/clusters",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.astronomer.io/v1/organizations/{organizationId}/clusters"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.astronomer.io/v1/organizations/{organizationId}/clusters")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.astronomer.io/v1/organizations/{organizationId}/clusters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"clusters": [
{
"cloudProvider": "AWS",
"createdAt": "2022-11-22T04:37:12Z",
"dbInstanceType": "db.t3.medium",
"drRegion": "us-east-1",
"id": "clm7k8tgw000008jz97i37y81",
"isDrEnabled": true,
"name": "my cluster",
"organizationId": "clm88r8hi000008jwhzxu5crg",
"region": "us-east-1",
"status": "CREATED",
"type": "DEDICATED",
"updatedAt": "2022-11-22T04:37:12Z",
"vpcSubnetRange": "172.20.0.0/22",
"drPodSubnetRange": "172.21.0.0/19",
"drSecondaryVpcCidr": "<string>",
"drServicePeeringRange": "172.23.0.0/20",
"drServiceSubnetRange": "172.22.0.0/22",
"drVpcSubnetRange": "<string>",
"enableReplicationTimeControl": true,
"failoverInProgress": true,
"healthStatus": {
"value": "HEALTHY",
"details": [
{
"code": "<string>",
"description": "<string>",
"severity": "<string>",
"component": "<string>"
}
]
},
"isFailedOver": true,
"isLimited": false,
"isPrivateNetworkEgressEnabled": true,
"metadata": {
"externalIPs": [
"35.100.100.1"
],
"kubeDnsIp": "10.100.100.0",
"oidcIssuerUrl": "https://westus2.oic.prod-aks.azure.com/b84efac8-cfae-467a-b223-23b9aea1486d/3075f79e-abc2-4602-a691-28117197e83d/"
},
"nodePools": [
{
"cloudProvider": "AWS",
"clusterId": "clm891jb6000308jrc3vjdtde",
"createdAt": "2022-11-22T04:37:12Z",
"id": "clm890zhe000208jr39dd0ubs",
"isDefault": true,
"maxNodeCount": 1,
"name": "default",
"nodeInstanceType": "t3.medium",
"updatedAt": "2022-11-22T04:37:12Z",
"supportedAstroMachines": [
"A5",
"A10"
]
}
],
"podSubnetRange": "172.21.0.0/19",
"providerAccount": "provider-account",
"secondaryVpcCidr": "<string>",
"servicePeeringRange": "172.23.0.0/20",
"serviceSubnetRange": "172.22.0.0/22",
"tags": [
{
"key": "key1",
"value": "value1"
}
],
"tenantId": "your-tenant-id",
"workspaceIds": [
"clm88rddl000108jwgeka2div"
]
}
],
"limit": 10,
"offset": 0,
"totalCount": 100
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}List clusters
List clusters in an Organization.
curl --request GET \
--url https://api.astronomer.io/v1/organizations/{organizationId}/clusters \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.astronomer.io/v1/organizations/{organizationId}/clusters"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.astronomer.io/v1/organizations/{organizationId}/clusters', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.astronomer.io/v1/organizations/{organizationId}/clusters",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.astronomer.io/v1/organizations/{organizationId}/clusters"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.astronomer.io/v1/organizations/{organizationId}/clusters")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.astronomer.io/v1/organizations/{organizationId}/clusters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"clusters": [
{
"cloudProvider": "AWS",
"createdAt": "2022-11-22T04:37:12Z",
"dbInstanceType": "db.t3.medium",
"drRegion": "us-east-1",
"id": "clm7k8tgw000008jz97i37y81",
"isDrEnabled": true,
"name": "my cluster",
"organizationId": "clm88r8hi000008jwhzxu5crg",
"region": "us-east-1",
"status": "CREATED",
"type": "DEDICATED",
"updatedAt": "2022-11-22T04:37:12Z",
"vpcSubnetRange": "172.20.0.0/22",
"drPodSubnetRange": "172.21.0.0/19",
"drSecondaryVpcCidr": "<string>",
"drServicePeeringRange": "172.23.0.0/20",
"drServiceSubnetRange": "172.22.0.0/22",
"drVpcSubnetRange": "<string>",
"enableReplicationTimeControl": true,
"failoverInProgress": true,
"healthStatus": {
"value": "HEALTHY",
"details": [
{
"code": "<string>",
"description": "<string>",
"severity": "<string>",
"component": "<string>"
}
]
},
"isFailedOver": true,
"isLimited": false,
"isPrivateNetworkEgressEnabled": true,
"metadata": {
"externalIPs": [
"35.100.100.1"
],
"kubeDnsIp": "10.100.100.0",
"oidcIssuerUrl": "https://westus2.oic.prod-aks.azure.com/b84efac8-cfae-467a-b223-23b9aea1486d/3075f79e-abc2-4602-a691-28117197e83d/"
},
"nodePools": [
{
"cloudProvider": "AWS",
"clusterId": "clm891jb6000308jrc3vjdtde",
"createdAt": "2022-11-22T04:37:12Z",
"id": "clm890zhe000208jr39dd0ubs",
"isDefault": true,
"maxNodeCount": 1,
"name": "default",
"nodeInstanceType": "t3.medium",
"updatedAt": "2022-11-22T04:37:12Z",
"supportedAstroMachines": [
"A5",
"A10"
]
}
],
"podSubnetRange": "172.21.0.0/19",
"providerAccount": "provider-account",
"secondaryVpcCidr": "<string>",
"servicePeeringRange": "172.23.0.0/20",
"serviceSubnetRange": "172.22.0.0/22",
"tags": [
{
"key": "key1",
"value": "value1"
}
],
"tenantId": "your-tenant-id",
"workspaceIds": [
"clm88rddl000108jwgeka2div"
]
}
],
"limit": 10,
"offset": 0,
"totalCount": 100
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}{
"message": "<string>",
"requestId": "<string>",
"statusCode": 500,
"fieldErrors": [
{
"code": "<string>",
"field": "<string>",
"message": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The Organization's unique ID.
Query Parameters
A list of names for Clusters to filter by. The API returns details only for the specified Clusters.
The cloud provider to list clusters for. Clusters from other providers will be filtered out of the results.
AWS, AZURE, GCP The number of results to skip before returning values.
x >= 0The maximum number of results to return.
0 <= x <= 1000A list of field names to sort by, and whether to show results as ascending or descending. Formatted as <fieldName>:asc or <fieldName>:desc.
name:asc, name:desc, createdAt:asc, createdAt:desc, updatedAt:asc, updatedAt:desc Response
OK
The list of clusters in the current page.
Show child attributes
Show child attributes
The maximum number of clusters in one page.
10
The offset of the current page of clusters.
0
The total number of clusters.
100
Was this page helpful?