get_statefulset_summaries
Lists StatefulSet summaries for a given namespace or all namespaces, similar to kubectl get statefulsets. Provides replica counts, update strategy, and age.
Instructions
Retrieves a list of StatefulSetSummary objects for StatefulSets in a given
namespace or all namespaces, similar to kubectl get statefulsets.
Parameters
----------
namespace : Optional[str], default=None
The specific namespace to list StatefulSets from. If None, lists from all
namespaces.
Returns
-------
list of StatefulSetSummary
A list of StatefulSetSummary objects, each with the following fields:
name : str
Name of the StatefulSet.
namespace : str
Namespace in which the StatefulSet runs.
total_replicas : int
Desired number of replicas.
ready_replicas : int
Number of replicas currently ready.
current_replicas : int
Number of replicas created by the current revision.
update_strategy : str
Update strategy type (e.g. "RollingUpdate", "OnDelete").
service_name : Optional[str]
Name of the governing (headless) service.
age : datetime.timedelta
Age of the StatefulSet (current time minus creation timestamp).
Raises
------
K8sConfigError
If unable to initialize the K8S API.
K8sApiError
If the API call to list StatefulSets fails.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_statefulset_summaries"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| namespace | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |