import requests
url = "https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling \
--header 'Authorization: Bearer <token>'{
"enabled": true,
"group_name": "<string>",
"max_count": 123,
"min_count": 123,
"message": "<string>",
"node_count": 123,
"operation_id": "<string>",
"target_count": 123
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": "Cluster not found"
}Read node-group autoscaling
Returns the node group’s autoscaling settings: whether autoscaling is enabled and its min and max counts. A group with no workers answers 409. The Cluster Autoscaler cannot drive Proxmox VE node groups, so autoscaling reads as disabled unless a row was written before that refusal existed.
import requests
url = "https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://platform.ankra.app/api/v1/clusters/proxmox/{cluster_id}/node-groups/{group_name}/autoscaling \
--header 'Authorization: Bearer <token>'{
"enabled": true,
"group_name": "<string>",
"max_count": 123,
"min_count": 123,
"message": "<string>",
"node_count": 123,
"operation_id": "<string>",
"target_count": 123
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": "Cluster not found"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}{
"detail": "Cluster not found"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Response
Successful response
PUT only. What the write does to the group's node count, in words.
PUT only. The group's node count when the write was made.
PUT only. The operation applying the write; absent when none was created now (a stopped cluster, an operation already working on the cluster, or nothing to apply).
PUT only. The node count the write moves the group to: max_count when the group had more nodes, min_count when it had fewer (while autoscaling is enabled), node_count otherwise. A group above max_count scales down through the guarded removal of its least busy nodes, each drained once the pipeline steps on it finish.