Bases: vmware.vapi.bindings.stub.VapiInterface
Monitoring class provides methods Get and list monitoring data for requested item.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.enum.Enum
Monitoring.FunctionType class Defines aggregation function
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the FunctionType instance. |
---|
Aggregation takes average per period
Aggregation takes count per period (sum)
Aggregation takes maximums per period
Aggregation takes minimums per period
Bases: vmware.vapi.bindings.enum.Enum
Monitoring.IntervalType class Defines interval between the values in hours and mins, for which aggregation will apply
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the IntervalType instance. |
---|
24 hours interval between values. One year has 365 values.
Two hours interval between values. One month has 360 values.
Six hour interval between values. One quarter is 360 values.
Thirty minutes interval between values. One week is 336 values.
Five minutes interval between values (finest). One day would have 288 values, one week is 2016.
Bases: vmware.vapi.bindings.struct.VapiStruct
Monitoring.MonitoredItem class Structure representing requested monitored item data.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Monitoring.MonitoredItemData class Structure representing monitored item data.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Monitoring.MonitoredItemDataRequest class Structure representing requested monitored item data.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Get monitored item info
Parameters: | stat_id (str) – statistic item id The parameter must be an identifier for the resource type: com.vmware.appliance.monitoring. |
---|---|
Return type: | Monitoring.MonitoredItem |
Returns: | MonitoredItem structure |
Raise: | com.vmware.vapi.std.errors_client.Error Generic error |
Get monitored items list
Return type: | list of Monitoring.MonitoredItem |
---|---|
Returns: | list of names |
Raise: | com.vmware.vapi.std.errors_client.Error Generic error |
Get monitoring data.
Parameters: | item (Monitoring.MonitoredItemDataRequest) – MonitoredItemDataRequest Structure |
---|---|
Return type: | list of Monitoring.MonitoredItemData |
Returns: | list of MonitoredItemData structure |
Raise: | com.vmware.vapi.std.errors_client.Error Generic error |
The com.vmware.cis_client module provides VMware common infrastructure classes such as session and task.
Bases: vmware.vapi.bindings.stub.VapiInterface
The Session class allows API clients to manage session tokens including creating, deleting and obtaining information about sessions.
The call to the Session.create() method is part of the overall authentication process for API clients. For example, the sequence of steps for establishing a session with SAML token is:
See the programming guide and samples for additional information about establishing API sessions.
Execution Context and Security Context
To use session based authentication a client should supply the session token obtained through the Session.create() method. The client should add the session token in the security context when using SDK classes. Clients using the REST API should supply the session token as a HTTP header.
Session Lifetime
A session begins with call to the Session.create() method to exchange a SAML token for a API session token. A session ends under the following circumstances:
When a session ends, the authentication logic will reject any subsequent client requests that specify that session. Any operations in progress will continue to completion.
Error Handling
The Session returns the following exceptions:
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Represents data associated with an API session.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Creates a session with the API. This is the equivalent of login. This method exchanges user credentials supplied in the security context for a session identifier that is to be used for authenticating subsequent calls. To authenticate subsequent calls clients are expected to include the session key.
Return type: | str |
---|---|
Returns: | Newly created session identifier to be used for authenticating further requests. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the session creation fails due to request specific issues. Due to the security nature of the API the details of the error are not disclosed. Please check the following preconditions if using a SAML token to authenticate:
|
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if session creation fails due to server specific issues, for example connection to a back end component is failing. Due to the security nature of this API further details will not be disclosed in the exception. Please refer to component health information, administrative logs and product specific documentation for possible causes. |
Terminates the validity of a session token. This is the equivalent of log out.
A session identifier is expected as part of the request.
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the session id is missing from the request or the corresponding session object cannot be found. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if session deletion fails due to server specific issues, for example connection to a back end component is failing. Due to the security nature of this API further details will not be disclosed in the exception. Please refer to component health information, administrative logs and product specific documentation for possible causes. |
Returns information about the current session. This method expects a valid session identifier to be supplied.
A side effect of invoking this method may be a change to the session’s last accessed time to the current time if this is supported by the session implementation. Invoking any other method in the API will also update the session’s last accessed time.
This API is meant to serve the needs of various front end projects that may want to display the name of the user. Examples of this include various web based user interfaces and logging facilities.
Return type: | Session.Info |
---|---|
Returns: | Information about the session. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the session id is missing from the request or the corresponding session object cannot be found. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if session retrieval fails due to server specific issues e.g. connection to back end component is failing. Due to the security nature of this API further details will not be disclosed in the error. Please refer to component health information, administrative logs and product specific documentation for possible causes. |
The Content module provides classes and classes for configuring global settings and permissions, and for managing libraries in the Content Library Service.
Bases: vmware.vapi.bindings.stub.VapiInterface
The Configuration class provides methods to configure the global settings of the Content Library Service.
The configuration settings are used by the Content Library Service to control the behavior of various operations.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Retrieves the current configuration values.
Return type: | |
---|---|
Returns: | The ConfigurationModel instance representing the configuration of the Content Library Service. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Updates the configuration. The update is incremental. Any attribute in the ConfigurationModel class that is None will not be modified. Note that this update method doesn’t guarantee an atomic change of all the properties. In the case of a system crash or failure, some of the properties could be left unchanged while others may be updated.
Parameters: | model (ConfigurationModel) – The ConfigurationModel specifying the settings to update. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if one of the configuration properties is not within the proper range. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Bases: vmware.vapi.bindings.struct.VapiStruct
The ConfigurationModel class defines the global settings of the Content Library Service.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.stub.VapiInterface
The Library class provides methods to manage and find LibraryModel entities.
The Library class provides support for generic functionality which can be applied equally to all types of libraries. The functionality provided by this class will not affect the properties specific to the type of library. See also LocalLibrary and SubscribedLibrary.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Specifies the properties that can be used as a filter to find libraries. When multiple attributes are specified, all properties of the library must match the specification.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Resource type for library.
Returns a list of all the visible (as determined by authorization policy) libraries matching the requested Library.FindSpec.
Parameters: | spec (Library.FindSpec) – Specification describing what properties to filter on. |
---|---|
Return type: | list of str |
Returns: | The list of identifiers of all the visible libraries matching the given spec. The return value will contain identifiers for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if no properties are specified in the spec. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns a given LibraryModel.
Parameters: | library_id (str) – Identifier of the library to return. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Return type: | |
Returns: | The LibraryModel instance with the specified library_id. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the specified library does not exist. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns the identifiers of all libraries of any type in the Content Library.
Return type: | list of str |
---|---|
Returns: | The list of all identifiers of all libraries in the Content Library. The return value will contain identifiers for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Updates the properties of a library.
This is an incremental update to the library. Any attribute in the LibraryModel class that is None will not be modified.
This method will only update the common properties for all library types. This will not, for example, update the LibraryModel.publish_info of a local library, nor the LibraryModel.subscription_info of a subscribed library. Specific properties are updated in LocalLibrary.update() and SubscribedLibrary.update().
Parameters: |
|
---|---|
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library associated with library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the update_spec is not valid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the LibraryModel.version of update_spec is not equal to the current version of the library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Bases: vmware.vapi.bindings.struct.VapiStruct
The LibraryModel class represents a Content Library resource model.
A LibraryModel is a container for a set of items which represent a usable set of files. The Content Library Service allows for multiple libraries to be created with separate authorization and sharing policies.
Each LibraryModel is a container for a set of com.vmware.content.library_client.ItemModel instances. Each item is a logical object in a library, which may have multiple files.
A LibraryModel may be local or subscribed. A local library has its source of truth about items within this Content Library Service. Items may be added to or removed from the library. A local library may also be private or published. When published, the library is exposed by a network endpoint and can be used by another Content Library Service for synchronization. A private local library cannot be used for synchronization.
A subscribed library is a library which gets its source of truth from another library that may be across a network in another Content Library Service. A subscribed library may have a different name and metadata from the library to which it subscribes, but the set of library items is always the same as those in the source library. Library items cannot be manually added to a subscribed library – they can only be added by adding new items to the source library.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The LibraryModel.LibraryType class defines the type of a LibraryModel.
The type of a library can be used to determine which additional services can be performed with a library.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the LibraryType instance. |
---|
The library contents are defined and stored by the local Content Library Service installation.
A local library can be retrieved and managed via the LocalLibrary.
The library synchronizes its items and content from another published library.
A subscribed library can be retrieved and managed via the SubscribedLibrary.
Bases: vmware.vapi.bindings.stub.VapiInterface
The LocalLibrary class manages local libraries.
The LocalLibrary class provides support for creating and maintaining local library instances. A local library may also use the Library class to manage general library functionality.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Creates a new local library.
Parameters: |
|
---|---|
Return type: | str |
Returns: | Identifier of the newly created LibraryModel. The return value will be an identifier for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the create_spec is not valid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the client_token does not conform to the UUID format. |
Raise: | com.vmware.vapi.std.errors_client.Unsupported if using multiple storage backings. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Deletes the specified local library.
Deleting a local library will remove the entry immediately and begin an asynchronous task to remove all cached content for the library. If the asynchronous task fails, file content may remain on the storage backing. This content will require manual removal.
Parameters: | library_id (str) – Identifier of the local library to delete. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a local library. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns a given local library.
Parameters: | library_id (str) – Identifier of the local library to return. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Return type: | |
Returns: | The LibraryModel instance associated with library_id. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a local library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns the identifiers of all local libraries in the Content Library.
Return type: | list of str |
---|---|
Returns: | The list of identifiers of all local libraries in the Content Library. The return value will contain identifiers for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Updates the properties of a local library.
This is an incremental update to the local library. Attributes that are None in the update specification will be left unchanged.
Parameters: |
|
---|---|
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a local library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the update_spec is not valid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the LibraryModel.version of update_spec is not equal to the current version of the library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Bases: vmware.vapi.bindings.stub.VapiInterface
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The SubscribedLibrary.ProbeResult class defines the subscription information probe result. This describes whether using a given subscription URL is successful or if there are access problems, such as SSL errors.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The SubscribedLibrary.ProbeResult.Status class defines the error status constants for the probe result.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the Status instance. |
---|
Indicates that the provided server certificate thumbprint in com.vmware.content.library_client.SubscriptionInfo.ssl_thumbprint is invalid. In this case, the returned null should be set in com.vmware.content.library_client.SubscriptionInfo.ssl_thumbprint.
Indicates that the host in the URL could not be found.
Indicates that the connection was rejected due to invalid credentials.
Indicates that the supplied URL was not valid.
Indicates that the given resource at the URL was not found.
Indicates that the probe was successful.
Indicates that the probe timed out while attempting to connect to the URL.
Indicates an unspecified error different from the other error cases defined in SubscribedLibrary.ProbeResult.Status.
Creates a new subscribed library.
Once created, the subscribed library will be empty. If the LibraryModel.subscription_info property is set, the Content Library Service will attempt to synchronize to the remote source. This is an asynchronous operation so the content of the published library may not immediately appear.
Parameters: |
|
---|---|
Return type: | str |
Returns: | Identifier of the newly created subscribed library. The return value will be an identifier for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the create_spec is not valid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the client_token does not conform to the UUID format. |
Raise: | com.vmware.vapi.std.errors_client.Unsupported if using multiple storage backings. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if subscribing to a published library which cannot be accessed. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Deletes the specified subscribed library.
Deleting a subscribed library will remove the entry immediately and begin an asynchronous task to remove all cached content for the library. If the asynchronous task fails, file content may remain on the storage backing. This content will require manual removal.
Parameters: | library_id (str) – Identifier of the subscribed library to delete. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library referenced by library_id is not a subscribed library. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library referenced by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Evicts the cached content of an on-demand subscribed library.
This method allows the cached content of a subscribed library to be removed to free up storage capacity. This method will only work when a subscribed library is synchronized on-demand.
Parameters: | library_id (str) – Identifier of the subscribed library whose content should be evicted. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a subscribed library. |
Raise: | com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the library specified by library_id does not synchronize on-demand. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns a given subscribed library.
Parameters: | library_id (str) – Identifier of the subscribed library to return. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Return type: | |
Returns: | The LibraryModel instance that corresponds to library_id. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library associated with library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library associated with library_id is not a subscribed library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Returns the identifiers of all subscribed libraries in the Content Library.
Return type: | list of str |
---|---|
Returns: | The list of identifiers of all subscribed libraries in the Content Library. The return value will contain identifiers for the resource type: com.vmware.content.Library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Probes remote library subscription information, including URL, SSL certificate and password. The resulting SubscribedLibrary.ProbeResult class describes whether or not the subscription configuration is successful.
Parameters: | subscription_info (com.vmware.content.library_client.SubscriptionInfo) – The subscription info to be probed. |
---|---|
Return type: | |
Returns: | The subscription info probe result. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Forces the synchronization of the subscribed library.
Synchronizing a subscribed library forcefully with this method will perform the same synchronization behavior as would run periodically for the library. The com.vmware.content.library_client.SubscriptionInfo.on_demand setting is respected. Calling this method on a library that is already in the process of synchronizing will have no effect.
Parameters: | library_id (str) – Identifier of the subscribed library to synchronize. The parameter must be an identifier for the resource type: com.vmware.content.Library. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a subscribed library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if some parameter in the subscribed library subscription info is invalid. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if the published library cannot be contacted or found. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Updates the properties of a subscribed library.
This is an incremental update to the subscribed library. Attributes that are None in the update specification will be left unchanged.
Parameters: |
|
---|---|
Raise: | com.vmware.vapi.std.errors_client.NotFound if the library specified by library_id does not exist. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the library specified by library_id is not a subscribed library. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the update_spec is not valid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the LibraryModel.version of update_spec is not equal to the current version of the library. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if the subscription info is being updated but the published library cannot be contacted or found. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
Bases: vmware.vapi.bindings.stub.VapiInterface
The Type class exposes the com.vmware.content.library_client.ItemModel types that this Content Library Service supports.
A library item has an optional type which can be specified with the com.vmware.content.library_client.ItemModel.type attribute. For items with a type that is supported by a plugin, the Content Library Service may understand the files which are part of the library item and can produce metadata for the item.
In other cases, uploads may require a process in which one upload implies subsequent uploads. For example, an Open Virtualization Format (OVF) package is composed of an OVF descriptor file and the associated virtual disk files. Uploading an OVF descriptor can enable the Content Library Service to understand that the complete OVF package requires additional disk files, and it can set up the transfers for the disks automatically by adding the file entries for the disks when the OVF descriptor is uploaded.
When a type is not supported by a plugin, or the type is not specified, the Content Library Service can handle a library item in a default way, without adding metadata to the item or guiding the upload process.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Type.Info class describes support for a specific type of data in an com.vmware.content.library_client.ItemModel. The Type.Info can be queried through the Type class. Type support describes plugins in the Content Library which can provide metadata on library items and help manage the transfer process by adding dependent files when a current file is added.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Returns a list of Type.Info instances which describe the type support plugins in this Content Library.
Return type: | |
---|---|
Returns: | The list of Type.Info instances which describe the type support plugins in this Content Library. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:
|
The com.vmware.vcenter_client module provides classes for managing VMware vSphere environments. The module is available starting in vSphere 6.5.
Bases: vmware.vapi.bindings.stub.VapiInterface
The Cluster class provides methods to manage clusters in the vCenter Server.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Cluster.FilterSpec class contains attributes used to filter the results when listing clusters (see Cluster.list()). If multiple attributes are specified, only clusters matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Cluster.Info class contains information about a cluster in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter Cluster
Bases: vmware.vapi.bindings.struct.VapiStruct
The Cluster.Summary class contains commonly used information about a cluster in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Retrieves information about the cluster corresponding to cluster.
Parameters: | cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource. |
---|---|
Return type: | Cluster.Info |
Returns: | The Cluster.Info instances that corresponds to the cluster. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no cluster associated with cluster in the system. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the session id is missing from the request or the corresponding session object cannot be found. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t not have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) clusters in vCenter matching the Cluster.FilterSpec.
Parameters: | filter (Cluster.FilterSpec or None) – Specification of matching clusters for which information should be returned. If None, the behavior is equivalent to a Cluster.FilterSpec with all attributes None which means all clusters match the filter. |
---|---|
Return type: | list of Cluster.Summary |
Returns: | Commonly used information about the clusters matching the Cluster.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 clusters match the Cluster.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The Datacenter class provides methods to manage datacenters in the vCenter Server.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datacenter.CreateSpec class defines the information used to create a datacenter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datacenter.FilterSpec class contains attributes used to filter the results when listing datacenters (see Datacenter.list()). If multiple attributes are specified, only datacenters matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datacenter.Info class contains information about a datacenter in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter Datacenter
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datacenter.Summary class contains commonly used information about a datacenter in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Create a new datacenter in the vCenter inventory
Parameters: | spec (Datacenter.CreateSpec) – Specification for the new datacenter to be created. |
---|---|
Return type: | str |
Returns: | The identifier of the newly created datacenter The return value will be an identifier for the resource type: Datacenter. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.AlreadyExists if the datacenter with the same name is already present. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the datacenter name is empty or invalid as per the underlying implementation. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the folder is not specified and the system cannot choose a suitable one. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the datacenter folder cannot be found. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Delete an empty datacenter from the vCenter Server
Parameters: |
|
---|---|
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no datacenter associated with datacenter in the system. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInUse if the datacenter associated with datacenter is not empty. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Retrieves information about the datacenter corresponding to datacenter.
Parameters: | datacenter (str) – Identifier of the datacenter. The parameter must be an identifier for the resource type: Datacenter. |
---|---|
Return type: | Datacenter.Info |
Returns: | The Datacenter.Info instances that corresponds to the datacenter. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no datacenter associated with datacenter in the system. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) datacenters in vCenter matching the Datacenter.FilterSpec.
Parameters: | filter (Datacenter.FilterSpec or None) – Specification of matching datacenters for which information should be returned. If None, the behavior is equivalent to a Datacenter.FilterSpec with all attributes None which means all datacenters match the filter. |
---|---|
Return type: | list of Datacenter.Summary |
Returns: | Commonly used information about the datacenters matching the Datacenter.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 datacenters match the Datacenter.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The Datastore class provides methods for manipulating a datastore.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datastore.FilterSpec class contains attributes used to filter the results when listing datastores (see Datastore.list()). If multiple attributes are specified, only datastores matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datastore.Info class contains information about a datastore.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter datastore
Bases: vmware.vapi.bindings.struct.VapiStruct
The Datastore.Summary class contains commonly used information about a datastore.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The Datastore.Type class defines the supported types of vCenter datastores.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the Type instance. |
---|
Common Internet File System.
Network file system v3 (linux & esx servers only).
Network file system v4.1 (linux & esx servers only).
Flash Read Cache (ESX Server only).
VMware File System (ESX Server only).
Virtual SAN (ESX Server only).
vSphere Virtual Volume (ESX Server only).
Retrieves information about the datastore indicated by datastore.
Parameters: | datastore (str) – Identifier of the datastore for which information should be retrieved. The parameter must be an identifier for the resource type: Datastore. |
---|---|
Return type: | Datastore.Info |
Returns: | information about the datastore. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the datastore indicated by datastore does not exist. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) datastores in vCenter matching the Datastore.FilterSpec.
Parameters: | filter (Datastore.FilterSpec or None) – Specification of matching datastores for which information should be returned. If None, the behavior is equivalent to a Datastore.FilterSpec with all attributes None which means all datastores match the filter. |
---|---|
Return type: | list of Datastore.Summary |
Returns: | Commonly used information about the datastores matching the Datastore.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the Datastore.FilterSpec.types attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the Datastore.FilterSpec.types attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 datastores match the Datastore.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The Folder class provides methods for manipulating a vCenter Server folder.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Folder.FilterSpec class contains attributes used to filter the results when listing folders (see Folder.list()). If multiple attributes are specified, only folders matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter folder
Bases: vmware.vapi.bindings.struct.VapiStruct
The Folder.Summary class contains commonly used information about a folder.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The Folder.Type class 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.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the Type instance. |
---|
A folder that can contain datacenters.
A folder that can contain datastores.
A folder that can contain compute resources (hosts and clusters).
A folder that can contain networkds.
A folder that can contain virtual machines.
Returns information about at most 1000 visible (subject to permission checks) folders in vCenter matching the Folder.FilterSpec.
Parameters: | filter (Folder.FilterSpec or None) – Specification of matching folders for which information should be returned. If None, the behavior is equivalent to a Folder.FilterSpec with all attributes None which means all folders match the filter. |
---|---|
Return type: | list of Folder.Summary |
Returns: | Commonly used information about the folders matching the Folder.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the Folder.FilterSpec.type attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 folders match the Folder.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The Host class provides methods to manage hosts in the vCenter Server.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.enum.Enum
The Host.ConnectionState class defines the connection status of a host.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the ConnectionState instance. |
---|
Host is connected to the vCenter Server
Host is disconnected from the vCenter Server
VirtualCenter is not receiving heartbeats from the server. The state automatically changes to connected once heartbeats are received again.
Bases: vmware.vapi.bindings.struct.VapiStruct
The Host.CreateSpec class defines the information used to create a host.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The Host.CreateSpec.ThumbprintVerification class defines the thumbprint verification schemes for a host’s SSL certificate.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the ThumbprintVerification instance. |
---|
Accept the host’s thumbprint without verifying it.
Host’s SSL certificate verified by checking its thumbprint against the specified thumbprint.
Bases: vmware.vapi.bindings.struct.VapiStruct
The Host.FilterSpec class contains attributes used to filter the results when listing hosts (see Host.list()). If multiple attributes are specified, only hosts matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The Host.PowerState class defines the power states of a host.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the PowerState instance. |
---|
The host was specifically powered off by the user through vCenter server. This state is not a cetain state, because after vCenter server issues the command to power off the host, the host might crash, or kill all the processes but fail to power off.
The host is powered on. A host that is entering standby mode is also in this state.
The host was specifically put in standby mode, either explicitly by the user, or automatically by DPM. This state is not a cetain state, because after VirtualCenter issues the command to put the host in standby state, the host might crash, or kill all the processes but fail to enter standby mode. A host that is exiting standby mode is also in this state.
The resource type for the vCenter Host.
Bases: vmware.vapi.bindings.struct.VapiStruct
The Host.Summary class contains commonly used information about a host in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Connect to the host corresponding to host previously added to the vCenter server.
Parameters: | host (str) – Identifier of the host to be reconnected. The parameter must be an identifier for the resource type: HostSystem. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.AlreadyInDesiredState if the host associated with host is already connected. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no host associated with host in the system. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Add a new standalone host in the vCenter inventory. The newly connected host will be in connected state. The vCenter Server will verify the SSL certificate before adding the host to its inventory. In the case where the SSL certificate cannot be verified because the Certificate Authority is not recognized or the certificate is self signed, the vCenter Server will fall back to thumbprint verification mode as defined by Host.CreateSpec.ThumbprintVerification.
Parameters: | spec (Host.CreateSpec) – Specification for the new host to be created. |
---|---|
Return type: | str |
Returns: | The newly created identifier of the host in vCenter. The return value will be an identifier for the resource type: HostSystem. |
Raise: | com.vmware.vapi.std.errors_client.AlreadyExists if the host with the same name is already present. |
Raise: | com.vmware.vapi.std.errors_client.Error if installation of VirtualCenter agent on a host fails. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the host name is invalid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the host folder is invalid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the SSL thumbprint specified is invalid. |
Raise: | com.vmware.vapi.std.errors_client.InvalidElementType if the host folder id does not support vSphere compute resource as its children type. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInUse if the host is already being managed by another vCenter Server |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if there are not enough licenses to add the host. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user name or password for the administration account on the host are invalid. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unsupported if the software version on the host is not supported. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Remove a standalone host from the vCenter Server.
Parameters: | host (str) – Identifier of the host to be deleted. The parameter must be an identifier for the resource type: HostSystem. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no host associated with host in the system. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInUse if the host associated with host is in a vCenter cluster |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Disconnect the host corresponding to host from the vCenter server
Parameters: | host (str) – Identifier of the host to be disconnected. The parameter must be an identifier for the resource type: HostSystem. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.AlreadyInDesiredState if the host associated with host is already disconnected. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if there is no host associated with host in the system. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) hosts in vCenter matching the Host.FilterSpec.
Parameters: | filter (Host.FilterSpec or None) – Specification of matching hosts for which information should be returned. If None, the behavior is equivalent to a Host.FilterSpec with all attributes None which means all hosts match the filter. |
---|---|
Return type: | list of Host.Summary |
Returns: | Commonly used information about the hosts matching the Host.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the Host.FilterSpec.connection_states attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 hosts match the Host.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The Network class provides methods for manipulating a vCenter Server network.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The Network.FilterSpec class contains attributes used to filter the results when listing networks (see Network.list()). If multiple attributes are specified, only networks matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter network
Bases: vmware.vapi.bindings.struct.VapiStruct
The Network.Summary class contains commonly used information about a network.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.enum.Enum
The Network.Type class defines the type of a vCenter Server network. The type of a network can be used to determine what features it supports and which APIs can be used to find more information about the network or change its configuration.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
Parameters: | string (str) – String value for the Type instance. |
---|
XXX: vCenter based (create and managed through vCenter)
A network for whose configuration is managed outside of vSphere. The identifer and name of the network is made available through vSphere so that host and virtual machine virtual ethernet devices can connect to them.
XXX: ESX based (created and managed on ESX)
Returns information about at most 1000 visible (subject to permission checks) networks in vCenter matching the Network.FilterSpec.
Parameters: | filter (Network.FilterSpec or None) – Specification of matching networks for which information should be returned. If None, the behavior is equivalent to a Network.FilterSpec with all attributes None which means all networks match the filter. |
---|---|
Return type: | list of Network.Summary |
Returns: | Commonly used information about the networks matching the Network.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the Network.FilterSpec.types attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 networks match the Network.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The ResourcePool class provides methods for manipulating a vCenter Server resource pool.
This class does not include virtual appliances in the inventory of resource pools even though part of the behavior of a virtual appliance is to act like a resource pool.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The ResourcePool.FilterSpec class contains attributes used to filter the results when listing resource pools (see ResourcePool.list()). If multiple attributes are specified, only resource pools matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The ResourcePool.Info class contains information about a resource pool.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
The resource type for the vCenter resource pool
Bases: vmware.vapi.bindings.struct.VapiStruct
The ResourcePool.Summary class contains commonly used information about a resource pool in vCenter Server.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Retrieves information about the resource pool indicated by resource_pool.
Parameters: | resource_pool (str) – Identifier of the resource pool for which information should be retrieved. The parameter must be an identifier for the resource type: ResourcePool. |
---|---|
Return type: | ResourcePool.Info |
Returns: | information about the resource pool. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the resource pool indicated by resource_pool does not exist. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) resource pools in vCenter matching the ResourcePool.FilterSpec.
Parameters: | filter (ResourcePool.FilterSpec or None) – Specification of matching resource pools for which information should be returned. If None, the behavior is equivalent to a ResourcePool.FilterSpec with all attributes None which means all resource pools match the filter. |
---|---|
Return type: | list of ResourcePool.Summary |
Returns: | Commonly used information about the resource pools matching the ResourcePool.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 resource pools match the ResourcePool.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Bases: vmware.vapi.bindings.stub.VapiInterface
The VM class provides methods for managing the lifecycle of a virtual machine.
Parameters: | config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub. |
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Document-based creation spec.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The VM.FilterSpec class contains attributes used to filter the results when listing virtual machines (see VM.list()). If multiple attributes are specified, only virtual machines matching all of the attributes match the filter.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
Document-based info.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The VM.PlacementSpec class contains information used to place a virtual machine onto resources within the vCenter inventory.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Bases: vmware.vapi.bindings.struct.VapiStruct
The VM.Summary class contains commonly used information about a virtual machine.
Tip
The arguments are used to initialize data attributes with the same names.
Parameters: |
|
---|
Creates a virtual machine.
Parameters: | spec (VM.CreateSpec) – Virtual machine specification. |
---|---|
Return type: | str |
Returns: | ID of newly-created virtual machine. The return value will be an identifier for the resource type: VirtualMachine. |
Raise: | com.vmware.vapi.std.errors_client.AlreadyExists if a virtual machine with the specified name already exists. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if any of the specified parameters are invalid. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if any of the resources specified in spec could not be found |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if a specified resource (eg. host) is not accessible. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInUse if any of the specified storage addresses (eg. IDE, SATA, SCSI) result in a storage address conflict. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if any of the resources needed to create the virtual machine could not be allocated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Raise: | com.vmware.vapi.std.errors_client.Unsupported if guestOS is not supported for the requested virtual hardware version and spec includes None attributes that default to guest-specific values. |
Deletes a virtual machine.
Parameters: | vm (str) – Virtual machine identifier. The parameter must be an identifier for the resource type: VirtualMachine. |
---|---|
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the virtual machine is not found. |
Raise: | com.vmware.vapi.std.errors_client.ResourceBusy if the virtual machine is busy performing another operation. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if the virtual machine’s configuration state cannot be accessed. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about a virtual machine.
Parameters: | vm (str) – Virtual machine identifier. The parameter must be an identifier for the resource type: VirtualMachine. |
---|---|
Return type: | VM.Info |
Returns: | Information about the specified virtual machine. |
Raise: | com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request. |
Raise: | com.vmware.vapi.std.errors_client.NotFound if the virtual machine is not found. |
Raise: | com.vmware.vapi.std.errors_client.ResourceInaccessible if the virtual machine’s configuration state cannot be accessed. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |
Returns information about at most 1000 visible (subject to permission checks) virtual machines in vCenter matching the VM.FilterSpec.
Parameters: | filter (VM.FilterSpec or None) – Specification of matching virtual machines for which information should be returned. If None, the behavior is equivalent to a VM.FilterSpec with all attributes None which means all virtual machines match the filter. |
---|---|
Return type: | list of VM.Summary |
Returns: | Commonly used information about the virtual machines matching the VM.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.InvalidArgument if the VM.FilterSpec.power_states attribute contains a value that is not supported by the server. |
Raise: | com.vmware.vapi.std.errors_client.UnableToAllocateResource if more than 1000 virtual machines match the VM.FilterSpec. |
Raise: | com.vmware.vapi.std.errors_client.ServiceUnavailable if the system is unable to communicate with a service to complete the request. |
Raise: | com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated. |
Raise: | com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the required privileges. |