REST API - list

vcenter namespaces instances: list

Returns the information about all namespaces on this vCenter.

Request:

HTTP request

GET https://{server}/api/vcenter/namespaces/instances

Response:

HTTP Status Code: 200

Response Body Structure:

[
    {
        "cluster""obj-103",
        "stats"{
            "cpu_used"1,
            "memory_used"1,
            "storage_used"1
        },
        "namespace""obj-103",
        "description""string",
        "config_status""CONFIGURING"
    },
    {
        "cluster""obj-103",
        "stats"{
            "cpu_used"1,
            "memory_used"1,
            "storage_used"1
        },
        "namespace""obj-103",
        "description""string",
        "config_status""CONFIGURING"
    }
]

Headers:

None

Type:

Name Type Description
bold = required
- summary[] The list of summary of all namespaces.
-[].namespace string Identifier of the namespace.

When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance.

-[].description string Description of the namespace.

-[].cluster string Identifier for the cluster hosting the namespace.

When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: ClusterComputeResource. When operations return a value of this structure as a result, the field will be an identifier for the resource type: ClusterComputeResource.

-[].config_status string Current setting for config_status.

Describes the status of reaching the desired state configuration for the namespace. Value is one of:
CONFIGURING: The configuration is being applied to the namespace.
REMOVING: The configuration is being removed and namespace is being deleted.
RUNNING: The namespace is configured correctly.
ERROR: Failed to apply the configuration to the namespace, user intervention needed.

-[].stats stats Basic runtime statistics for the namespace.

-[].stats.cpu_used long Overall CPU usage of the namespace, in MHz. This is the sum of CPU usage across all pods in the Kubernetes namespace.

-[].stats.memory_used long Overall memory usage of the namespace (in mebibytes). This is the sum of memory usage across all pods.

-[].stats.storage_used long Overall storage used by the namespace (in mebibytes). This is the sum of storage used by pods across all datastores in the cluster associated with storage policies configured for the namespace.

Errors:

HTTP Status Code Type Description
500 error if the system reports an error while responding to the request.
401 unauthenticated if the user can not be authenticated.
403 unauthorized if the user does not have System.Read privilege.