import requests
url = "https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace"
payload = { "size": "<string>" }
headers = {
"cookie": "ankra_session=",
"X-Ankra-CSRF": "<x-ankra-csrf>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
cookie: 'ankra_session=',
'X-Ankra-CSRF': '<x-ankra-csrf>',
'Content-Type': 'application/json'
},
body: JSON.stringify({size: '<string>'})
};
fetch('https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace \
--header 'Content-Type: application/json' \
--header 'X-Ankra-CSRF: <x-ankra-csrf>' \
--cookie ankra_session= \
--data '
{
"size": "<string>"
}
'{
"operation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"new_size": "<string>",
"node_pool_name": "<string>",
"old_size": "<string>",
"replacement_pool_name": "<string>"
}{
"detail": "Cluster not found"
}{
"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"
}Replace a managed node pool with a new size (browser session)
Browser session authentication; RBAC permission clusters.write. Requests a blue/green replacement of the node pool with a new instance size: a scheduler job creates a replacement pool with the requested size (same count, labels, taints, zone, and autoscaling), waits for it to become ready, deletes the replaced pool, and rebinds the stored definition to the replacement pool’s deterministic name. No managed provider supports in-place pool resizing, so the 202 answer only accepts the intent.
import requests
url = "https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace"
payload = { "size": "<string>" }
headers = {
"cookie": "ankra_session=",
"X-Ankra-CSRF": "<x-ankra-csrf>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
cookie: 'ankra_session=',
'X-Ankra-CSRF': '<x-ankra-csrf>',
'Content-Type': 'application/json'
},
body: JSON.stringify({size: '<string>'})
};
fetch('https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/org/clusters/managed/{provider}/{cluster_id}/node-pools/{node_pool_name}/replace \
--header 'Content-Type: application/json' \
--header 'X-Ankra-CSRF: <x-ankra-csrf>' \
--cookie ankra_session= \
--data '
{
"size": "<string>"
}
'{
"operation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"new_size": "<string>",
"node_pool_name": "<string>",
"old_size": "<string>",
"replacement_pool_name": "<string>"
}{
"detail": "Cluster not found"
}{
"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
Browser session. Mutations also require X-Ankra-CSRF.
Headers
Must match the ankra_csrf browser cookie.
Path Parameters
doks, uks, gke, ovh_mks, aks, eks, kapsule, ankracloud_k8s "kapsule"
Body
1Response
Replacement accepted
The platform operation that creates the replacement pool, waits for it to be ready and deletes the replaced one; poll it for the outcome.