List Folder
Returns information about at most 1000 visible (subject to permission checks) folders in vCenter matching the Folder.FilterSpec.
Request
URLURL
Query Parameters
Query Parameters
Datacenters that must contain the folder for the folder to match the filter. If unset or empty, folder in any datacenter match the filter. When clients pass a value of this structure as a parameter, the field must contain identifiers for the resource type: Datacenter. When operations return a value of this structure as a result, the field will contain identifiers for the resource type: Datacenter.
Identifiers of folders that can match the filter. If unset or empty, folders with any identifier match the filter. When clients pass a value of this structure as a parameter, the field must contain identifiers for the resource type: Folder. When operations return a value of this structure as a result, the field will contain identifiers for the resource type: Folder.
Names that folders must have to match the filter (see Folder.Summary.name). If unset or empty, folders with any name match the filter.
Folders that must contain the folder for the folder to match the filter. If unset or empty, folder in any folder match the filter. When clients pass a value of this structure as a parameter, the field must contain identifiers for the resource type: Folder. When operations return a value of this structure as a result, the field will contain identifiers for the resource type: Folder.
Type that folders must have to match the filter (see Folder.Summary.type). If unset, folders with any type match the filter.
Header Parameters
Header Parameters
Required session ID, acquired from Create Session API under CIS product
vmware-api-session-id example
"b00db39f948d13ea1e59b4d6fce56389"
Authentication
Response
Response BodyResponse Body
array
of
FolderSummary
of type application/json
Commonly used information about the folders matching the Folder.FilterSpec.
[
{
"folder": "string",
"name": "string",
"type": "DATACENTER"
}
]
Identifier of the folder. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: Folder. When operations return a value of this structure as a result, the field will be an identifier for the resource type: Folder.
Name of the vCenter Server folder.
The Folder.Type enumerated type defines the type of a vCenter Server folder. The type of a folder determines what what kinds of children can be contained in the folder.
DATACENTER : A folder that can contain datacenters.
DATASTORE : A folder that can contain datastores.
HOST : A folder that can contain compute resources (hosts and clusters).
NETWORK : A folder that can contain networkds.
VIRTUAL_MACHINE : A folder that can contain virtual machines.
Possible values are: DATACENTER , DATASTORE , HOST , NETWORK , VIRTUAL_MACHINE
Errors
com.vmware.vapi.std.errors.invalid_argument : if the Folder.FilterSpec.type field contains a value that is not supported by the server.
com.vmware.vapi.std.errors.unauthorized : if the user doesn’t have the required privileges.
com.vmware.vapi.std.errors.unable_to_allocate_resource : if more than 1000 folders match the Folder.FilterSpec.
com.vmware.vapi.std.errors.service_unavailable : if the system is unable to communicate with a service to complete the request.
‘Default’ means this response is used for all HTTP codes that are not covered individually for this operation.
Code Samples
PowerCLI Client SDK Example
cURL Command
Vendor Extensions
x-vmw-doc-deprecated-method: get
x-vmw-doc-deprecated-path: /rest/vcenter/folder
x-vmw-doc-operation: list