get_namespaces
Retrieve a list of all Kubernetes namespaces in your cluster, showing name, status, and age for each namespace.
Instructions
Return a summary of the namespaces for this Kubernetes cluster, similar to that
returned by kubectl get namespace.
Parameters
----------
None
This function does not take any parameters.
Returns
-------
list of NamespaceSummary
List of namespace summary objects. Each NamespaceSummary has the following fields:
name : str
Name of the namespace.
status : str
Status phase of the namespace.
age : datetime.timedelta
Age of the namespace (current time minus creation timestamp).
Raises
------
K8sConfigError
If unable to initialize the K8S API.
K8sApiError
If the API call to list namespaces fails.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |