Remove a Kubernetes node pool
Delete a node pool. The node pool is returned as deleting, with a node_count of 0. We then move the pods off the node pool's workers and remove the workers. Once deleted, the node pool stays available as destroyed. Pods get up to 5 minutes to move off a worker. A worker can be removed before every pod has left.
The ID of the Kubernetes cluster.
The ID of the Kubernetes node pool to remove.
Bearer $TOKEN
{
"id": "example",
"name": "Example Kubernetes node pool",
"server_type": "AM2",
"node_count": 1,
"labels": {
"example": "value"
},
"taints": [
{
"key": "example",
"value": "example",
"effect": "NoSchedule"
}
],
"status": "active",
"status_message": "example",
"nodes_ready": 1,
"scaling": {
"from": 1,
"to": 1,
"started_at": "2026-07-01T12:00:00.000Z",
"estimated_ready_at": "2026-07-01T12:00:00.000Z"
},
"nodes": [
{
"id": "example",
"name": "Example",
"server_id": "123456789",
"status": "queued",
"version": "1.4.2",
"last_seen_at": "2026-07-01T12:00:00.000Z"
}
]
}
{
"error": {
"message": "Malformed JSON body.",
"code": "bad_request"
}
}
{
"error": {
"message": "Missing or invalid token.",
"code": "unauthorized"
}
}
{
"error": {
"message": "We require at least one successful credit card transaction before allowing billable actions via the API. This significantly helps us to prevent fraud. Once your first transaction is processed, you will be able to use the API unrestricted. Please add credit to your account at https://betterstack.com/settings/billing/card/new?credits=10&activate_api=true. Need help? We're here for you at hello@betterstack.com.",
"code": "payment_required"
}
}
{
"error": {
"message": "This token is read-only and cannot be used for write operations.",
"code": "read_only_token"
}
}
{
"error": {
"message": "Resource not found.",
"code": "not_found"
}
}
{
"error": {
"message": "The request could not be completed right now. Please try again in a few moments.",
"code": "internal_error"
}
}
Returns the Kubernetes node pool.
The body isn't valid JSON.
The API token is missing or invalid.
The organization hasn't made its first payment yet, and the request creates a resource we charge for. The code is payment_required. A request that creates a server, load balancer, object cache, database, reserved IP or volume can also return first_purchase. The url in first_purchase opens a page where you make the payment. The resource is created after the payment. The page works until expires_at, 24 hours after the response.
The request would go over a quota, with the code quota_exceeded. Or a read-only token tried to make a change, with the code read_only_token. Or a rule of the resource forbids it.
The resource doesn't exist, it's in another zone, or your token can't access it.
The resource's state doesn't allow the request, such as starting a running server or removing a placement group that still has servers.
We've locked the resource, with the code locked. Every change to a locked resource is refused, and so is a change that involves one.
Too many requests, with the code rate_limited. We limit requests per client IP and per organization, and some costly endpoints have a stricter limit. Wait as long as the Retry-After header says.
An unexpected, temporary error on our side, with the code internal_error. Try again.
The zone has no capacity, with the code no_capacity. Or we couldn't set up or change the resource, with the code orchestration_failed. Or the organization is creating too many resources at the same time, with the code concurrent_create_limit. Try again after a short wait.
The node pool's ID, a UUID.
The node pool's name, unique among the cluster's node pools.
The server type of the workers.
How many workers the node pool should have, from 0 to 100. The node pools of a cluster can have 100 workers in total. nodes lists the workers the node pool has now.
The Kubernetes labels of the workers, as string pairs, or an empty object when there are none.
The Kubernetes taints of the workers, or an empty list when there are none.
The taint's key.
The taint's value, or null when the taint has none.
What the taint does to pods that don't tolerate it, as in Kubernetes. Possible values: NoSchedule, PreferNoSchedule, NoExecute.
The node pool's state. The node pool is ready when the cluster is running and every worker of the node pool is ready.
Valid values:active: The node pool isn't changing size. The node pool's workers can still be joining or being replaced.scaling: We're adding or removing workers to reach node_count. Scaling happens after you change node_count, or when the node pool has more or fewer workers than node_count.deleting: We're removing the node pool.destroyed: The node pool is deleted.
Why the node pool has fewer workers than node_count, such as a quota limit, no capacity for the server type in the zone, or a server we couldn't create. Is null again once the node pool reaches node_count.
How many workers of the node pool are ready.
How a change of size is going while status is scaling, or null otherwise.
The number of workers before the change.
The node_count to reach.
When the change started. In ISO 8601 format, such as 2026-07-01T12:00:00Z.
When we expect the change to be done. When workers are added, it's based on the usual time a worker of the server type needs to be ready in this zone. When workers are removed, it's the latest time every removed worker is gone. In ISO 8601 format, such as 2026-07-01T12:00:00Z.
The node pool's workers, sorted by name. New workers show up at once as queued, then go through provisioning and joining to ready.
The worker's ID. Use it to recycle the worker.
The worker's name in Kubernetes.
The ID of the server that runs the worker, or null while the worker is queued.
The worker's state.
Valid values:queued: We'll create the worker.provisioning: We're creating the worker's server.joining: The worker is joining the cluster.ready: The worker is ready in Kubernetes.not_ready: The worker joined, but Kubernetes reports it as not ready.draining: We're moving pods off the worker before we remove it.replacing: We're creating a new worker to replace this one.destroyed: The worker is removed.
The Kubernetes version the worker reports.
When we last saw the worker ready. In ISO 8601 format, such as 2026-07-01T12:00:00Z.