com.vmware.esx.settings package

Subpackages

Submodules

com.vmware.esx.settings.clusters_client module

The com.vmware.esx.settings.clusters_client module provides classes to manage desired state configuration and software for a cluster of ESX hosts.

class com.vmware.esx.settings.clusters_client.Configuration(config)

Bases: VapiInterface

The Configuration class provides methods to manage desired configuration of an ESX cluster. This class was added in vSphere API 8.0.1.0.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ApplyResult(status=None, commit=None, software_commit=None, host_info=None, host_status=None, successful_hosts=None, failed_hosts=None, skipped_hosts=None)

Bases: VapiStruct

The Configuration.ApplyResult class contains attributes that describe the result of an Configuration.apply() method. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (com.vmware.esx.settings.clusters.configuration_client.HostStatus or None) – Specifies the aggregated status of the Configuration.apply() method. This attribute was added in vSphere API 8.0.1.0. None if the Configuration.apply() method is in progress.

  • commit (str) – The identifier of the commit used to fetch the desired configuration document to be applied to all hosts within the cluster. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • software_commit (str) – The current commit ID for the software associated with the cluster. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – Information of the hosts in this cluster to which the desired configuration document specified by the Configuration.ApplyResult.commit should be applied to. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • host_status (dict of str and com.vmware.esx.settings.clusters.configuration_client.HostStatus) – Status of the hosts in this cluster to which the desired configuration specified by the Configuration.ApplyResult.commit was applied to. Hosts on which the Configuration.apply() method was successful are specified by Configuration.ApplyResult.successful_hosts. Hosts on which the apply method failed are specified by Configuration.ApplyResult.failed_hosts. Hosts which were skipped by the Configuration.apply() method are specified by Configuration.ApplyResult.skipped_hosts. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • successful_hosts (set of str) – Hosts in this cluster to which the desired configuration specified by the Configuration.ApplyResult.commit has been successfully applied to. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • failed_hosts (set of str) – Hosts in this cluster to which the desired configuration specified by the Configuration.ApplyResult.commit failed to be applied. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • skipped_hosts (set of str) – Hosts in this cluster that were skipped by the Configuration.apply() method. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

class ApplySpec(commit=None, hosts=None, apply_policy_spec=None)

Bases: VapiStruct

The Configuration.ApplySpec class contains attributes that describe the specification to be used for applying the desired configuration to a cluster. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • commit (str or None) – The minimum commit identifier of the desired configuration to be used during the Configuration.apply() method. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the apply method will use the latest commit to fetch the desired configuration.

  • hosts (set of str or None) – The specific hosts within the cluster to be considered during the Configuration.apply() method. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem. if None or empty the Configuration.apply() method will remediate all hosts within the cluster.

  • apply_policy_spec (com.vmware.esx.settings.clusters.policies.apply_client.Effective.EffectivePolicySpec or None) – The parameter can be used to override the default remediation policies for the task. This attribute was added in vSphere API 8.0.1.0. if None the default cluster remediation policies are used.

class ImportSpec(config=None, description=None)

Bases: VapiStruct

The Configuration.ImportSpec class contains the desired configuration for a cluster and an optional short description of this version of the configuration. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • config (str) – The cluster configuration, encoded as JSON. This attribute was added in vSphere API 8.0.1.0.

  • description (str or None) – A description of this version of the configuration. This attribute was added in vSphere API 8.0.1.0.

class Info(metadata=None, host_info=None, config=None)

Bases: VapiStruct

The Configuration.Info class defines the information about configuration commit. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • metadata (Configuration.Metadata) – Metadata about the configuration commit. This attribute was added in vSphere API 8.0.1.0.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – A mapping of BIOS UUIDs for every host in the cluster to information about that host. The host-specific/host-override sections of the configuration use BIOS UUIDs to identify hosts, so this information can be useful to get details about hosts mentioned there. This attribute was added in vSphere API 8.0.1.0.

  • config (str) – Configuration specification associated with the commit, encoded as JSON. This attribute was added in vSphere API 8.0.1.0.

class Metadata(id=None, author=None, creation_time=None)

Bases: VapiStruct

The Configuration.Metadata class defines the metadata information about configuration commit. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • id (str) – The identifier of the commit. This attribute was added in vSphere API 8.0.1.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • author (str) – Author of the configuration commit. This attribute was added in vSphere API 8.0.1.0.

  • creation_time (datetime.datetime) – Creation time of the configuration commit. This attribute was added in vSphere API 8.0.1.0.

apply_task(cluster, spec)

Applies the cluster configuration associated with the cluster on the hosts associated with the cluster. This method was added in vSphere API 8.0.1.0.

Parameters:
  • cluster (str) – Identifier of the cluster The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Configuration.ApplySpec) – The Apply specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.AlreadyInDesiredState If the cluster is already at the specified commit as described in the apply specification.

Raise:

com.vmware.vapi.std.errors_client.Error If there is an unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the Configuration.ApplySpec.commit attribute of spec specifies an invalid commit, or the Configuration.ApplySpec.hosts attribute of spec specifies an invalid host or a host that is not part of the cluster, or the cluster is not managed with a configuration specification. Also thrown if the specified cluster is empty.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster found in the inventory or no Configuration.ApplySpec.commit associated with cluster.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the API timed out before completion.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

check_compliance_task(cluster)

Check all the hosts in the cluster for compliance with the desired document. This method was added in vSphere API 8.0.1.0.

Parameters:

cluster (str) – Identifier of the cluster The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If an internal error occurred. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If API is called on a cluster that is not managed by desired configuration management platform.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the API timed out before completion.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

export_config(cluster)

This API will export the configuration associated with the cluster. This method was added in vSphere API 8.0.1.0.

Parameters:

cluster (str) – Identifier of the cluster on which operation should be performed. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

com.vmware.esx.settings.clusters.configuration_client.ExportResult

Returns:

This output structure of type com.vmware.esx.settings.clusters.Configuration#ExportResult contains the configuration document encoded as JSON.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some other unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If the cluster is not found in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.ClusterConfiguration.Export.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.ClusterConfiguration.Export.

get(cluster, commit=None, doc_structure=None)

Get the cluster configuration and related metadata. The configuration returned by this API only contains the user-visible configuration properties available for a the cluster. This method was added in vSphere API 8.0.1.0.

Parameters:
  • cluster (str) – Identifier of the cluster The parameter must be an identifier for the resource type: ClusterComputeResource.

  • commit (str or None) – Identifier of the commit to get. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • doc_structure (com.vmware.esx.settings.clusters.configuration_client.DocumentStructure or None) –

Return type:

Configuration.Info

Returns:

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster or no commit associated with commit in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.ClusterConfiguration.View.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.ClusterConfiguration.View.

import_config_task(cluster, spec)

This API replaces the existing desired configuration of the cluster with the configuration provided in the input parameter document. The API will internally validate the input configuration against the configuration schema derived from the cluster software specification associated with the cluster. If the input configuration document passes validation, then it will be the desired configuration of the cluster. The result will specify whether the input document was import successfully. The result will also list the validation errors in case the import operation failed. This method was added in vSphere API 8.0.1.0.

Deprecated since version vSphere: API 8.0.2.0 Use com.vmware.esx.settings.clusters.configuration.Drafts#Create instead.

Parameters:
  • cluster (str) – The cluster on which this operation must be performed. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Configuration.ImportSpec) – An Configuration.ImportSpec that contains the new desired configuration for the cluster.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is some other unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If the cluster is not found in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

precheck_task(cluster)

This API will perform precheck of the desired cluster configuration on each of the hosts in the cluster. The API will check against the desired image schema whether the desired configuration has added any requirements for the host to be put in maintenance mode or to be rebooted. The API will also invoke plugins provided by the configuration owner to detect if the host needs to be put in maintenance mode or to be rebooted. If any host needs to be put in maintenance mode or rebooted, prechecks will be performed at the cluster and host level. The result will specify the validation errors if the desired configuration is not valid on the host. If valid, the result will specify host impact of the desired configuration, and list the configurations that will change on applying the desired configuration. If host impact is maintenance mode or reboot, precheck results will also be specified in the result. This method was added in vSphere API 8.0.1.0.

Parameters:

cluster (str) – The cluster on which to perform precheck. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If API is called on a cluster that is not managed by desired configuration management platform.

Raise:

com.vmware.vapi.std.errors_client.NotFound If the cluster is not found in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the API timed out before completion.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

validate_task(cluster)

Check whether the desired cluster configuration is valid. This method was added in vSphere API 8.0.1.0.

Deprecated since version vSphere: API 8.0.2.0 The desired cluster configuration is validated as part of Configuration.check_compliance() Configuration.precheck() APIs.

Parameters:

cluster (str) – Identifier of the cluster The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If an internal error occurred. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If API is called on a cluster that is not managed by desired configuration management platform.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the API timed out before completion.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

class com.vmware.esx.settings.clusters_client.DepotOverrides(config)

Bases: VapiInterface

The DepotOverrides class provides methods to manage software depots overriden for a given cluster. In general ESX servers reach out to vCenter (VUM) to fetch the metadata and payloads required for lifecycle operations. But in ROBO environments ESX clusters can’t (or because of bandwidth requirements shouldn’t) reach out to vCenter to fetch payloads and metadata. This class allows setting cluster level overrides for depots. If any depots are provided for a cluster, then vCenter level depots are not used for that cluster’s remediation. These are not synced periodically at vCenter and are only used by ESXs for lifecycle operations.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class Depot(location=None)

Bases: VapiStruct

The DepotOverrides.Depot class defines the information regarding a particular depot override for a given cluster.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

location (str) – Location of the depot override. This could be a location of zip file or location to an index.xml file.

class Info(depots=None)

Bases: VapiStruct

The DepotOverrides.Info class defines the information regarding depot overrides for a given cluster.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

depots (list of DepotOverrides.Depot) – List of the depot overrides.

add(cluster, depot)

Adds a new depot override to the list of currently configured depot overrides for a given cluster.

Warning: Using HTTP is not secure. Please use HTTPS URLs instead.

Parameters:
  • cluster (str) – Identifier for the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • depot (DepotOverrides.Depot) – Information of a depot override.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If an invalid location is provided.

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.AlreadyExists if depot override with given information already exists.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSettings.Write.

get(cluster)

Returns the information about currently configured depot overrides for a given cluster.

Parameters:

cluster (str) – Identifier for the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

DepotOverrides.Info

Returns:

Information about currently configured depot overrides for a given cluster.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSettings.Read.

remove(cluster, depot)

Removes a depot override from the list of currently configured depot overrides for a given cluster.

Parameters:
  • cluster (str) – Identifier for the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • depot (DepotOverrides.Depot) – Information of the depot override to be removed.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot override with given information or no cluster associated with identifier {param.name cluster} in the system.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSettings.Write.

class com.vmware.esx.settings.clusters_client.InstalledImages(config)

Bases: VapiInterface

The InstalledImages class provides methods to examine the software bundle running on group of ESXi hosts in a cluster. This class was added in vSphere API 8.0.3.0.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ImageCategories(is_highest_and_widely_used_image_equal=None, most_widely_used_image=None, highest_versioned_image=None, host_image_list=None)

Bases: VapiStruct

The InstalledImages.ImageCategories class contains (\@term fields) describing software image categorized on pre-defined criteria. This class was added in vSphere API 8.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • is_highest_and_widely_used_image_equal (bool) – Boolean flag indicating if most widely used image and highest versioned image is same. If this flag is set, it means “mostWidelyUsedImage” and “highestVersionImage” of “imageCategories” will contain same software image as value otherwise it will contain different value. This attribute was added in vSphere API 8.0.3.0.

  • most_widely_used_image (InstalledImages.InstalledImage or None) – This image category contains the software image that is most prevalent among the hosts in the cluster. This attribute was added in vSphere API 8.0.3.0. if None or empty means either there was an error fetching software specification of an ESXi host or the hosts in the cluster are ineligible to transition to vLCM.

  • highest_versioned_image (InstalledImages.InstalledImage or None) – This image category contains the software image which has highest ESXi version in the cluster. This attribute was added in vSphere API 8.0.3.0. if None or empty means either there was an error fetching software specification of an ESXi host or the hosts in the cluster are ineligible to transition to vLCM.

  • host_image_list (list of InstalledImages.InstalledImage or None) – This list will contain software image running on hosts in the cluster excluding “highestVersionedImage” and “mostWidelyUsedImage”. This attribute was added in vSphere API 8.0.3.0. if None or empty means there is no ESXi hosts in the cluster running software specification which is different than the one specified by mostWidelyUsed or highestVersionedImage.

class InstalledImage(software_info=None, host_list=None)

Bases: VapiStruct

The InstalledImages.InstalledImage class contains attributes information about installed software image that is running on the group of hosts. This class was added in vSphere API 8.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • software_info (com.vmware.esx.settings_client.SoftwareInfo) – Software image installed on group of hosts. This attribute was added in vSphere API 8.0.3.0.

  • host_list (set of str) – List of hosts having the same software image. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

class InstalledImageInfo(completion_time=None, uniform_image=None, status=None, successful_hosts=None, failed_hosts=None, unsupported_hosts=None, image_categories=None, host_notifications=None, host_info=None, orphaned_vibs=None, notifications=None)

Bases: VapiStruct

The InstalledImages.InstalledImageInfo class contains attributes describing software image running on hosts underneath the cluster and its relevant metadata. This class was added in vSphere API 8.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • completion_time (datetime.datetime) – Timestamp describing the completion of generate candidate image operation. This attribute was added in vSphere API 8.0.3.0.

  • uniform_image (bool) – If this flag is set, it means all hosts in cluster are running the same software image. In this case, “mostWidelyUsedImage” and “highestVersionImage” of “imageCategories” will contain same software image as value and subsequently “isHighestAndWidelyUsedImageEqual” flag will also be set. If this flag is not set, then depending upon the software image running in hosts “imageCategories” fields will be filled. This attribute was added in vSphere API 8.0.3.0.

  • status (InstalledImages.InstalledImageInfo.Status) – Execution status of the task. If it’s not SUCCESS then the InstalledImages.InstalledImageInfo.notifications attribute of this class can be inspected for more information. This attribute was added in vSphere API 8.0.3.0.

  • successful_hosts (list of str) – List of Hosts for which software image has extracted. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • failed_hosts (list of str) – List of hosts for which no software image has extracted. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • unsupported_hosts (list of str) – List of hosts that were skipped for extracting software image. Host will be skipped when software version is less than the supported version. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • image_categories (InstalledImages.ImageCategories) – Various categories of software image running on hosts in the cluster. This attribute was added in vSphere API 8.0.3.0.

  • host_notifications (dict of str and com.vmware.esx.settings_client.Notifications) – Notifications stating any error or orphaned vibs etc on Hosts. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – Information about the hosts in this cluster for which checks have been requested to be run. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • orphaned_vibs (dict of str and list of str) – Information about the orphaned vibs available on the hosts underlying cluster. Here Key is the orphaned vibs and value is the list of hosts where these orphaned vibs have installed. orphaned vibs formats are orphaned vibs name(version). This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the value in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the value in the attribute dict will be an identifier for the resource type: HostSystem.

  • notifications (dict of InstalledImages.InstalledImageInfo.OperationType and com.vmware.esx.settings_client.Notifications) – Various notifications received and segregated based on operation type while generating the report. If the task’s status is ELIGIBILITY_CHECK_FAILURE then the notifications corresponding to the ELIGIBILITY_CHECK key can be inspected for more informaiton. For any other task status the notifications corresponding to the EXTRACT_INSTALLED_IMAGE key can be inspected. This attribute was added in vSphere API 8.0.3.0.

class OperationType(string)

Bases: Enum

The InstalledImages.InstalledImageInfo.OperationType class will be used to distinguish and categorize the notifications generated by various operations. This enumeration was added in vSphere API 8.0.3.0.

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 OperationType instance.

ELIGIBILITY_CHECK = OperationType(string='ELIGIBILITY_CHECK')

Performs enablement check. This check the possibilities whether a cluster can be managed with single software image. This class attribute was added in vSphere API 8.0.3.0.

EXTRACT_INSTALLED_IMAGE = OperationType(string='EXTRACT_INSTALLED_IMAGE')

Extract Installed image from all the hosts in the cluster. It will check for any unsupported hosts, failed hosts, host having orphaned vibs etc. This class attribute was added in vSphere API 8.0.3.0.

class Status(string)

Bases: Enum

The InstalledImages.InstalledImageInfo.Status class is used to convey the status of the extract installed images task. For example, whether it was successful or whether some issue occurred during its execution. This enumeration was added in vSphere API 8.0.3.0.

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.

ELIGIBILITY_CHECK_FAILURE = Status(string='ELIGIBILITY_CHECK_FAILURE')

Indicates there was either an error during the execution of the eligibility check or the cluster is not eligible for vLCM management. In either case an error will be present in the #notifications field of the InstalledImageInfo class. This class attribute was added in vSphere API 8.0.3.0.

EXTRACT_INSTALLED_IMAGE_FAILURE = Status(string='EXTRACT_INSTALLED_IMAGE_FAILURE')

Indicates there was an error during the execution of the extract installed images task. If this is the case an error will be present in the #notifications attribute of the InstalledImageInfo class. This class attribute was added in vSphere API 8.0.3.0.

SUCCESS = Status(string='SUCCESS')

Indicates the extract installed images task completed without error. This class attribute was added in vSphere API 8.0.3.0.

UNAVAILABLE = Status(string='UNAVAILABLE')

Indicates that the status of the task is unknown. This could be because the task failed before the eligibility check had the chance to run. Another reason could be if the cluster has no hosts or if every host in the cluster is running a base image version < 7.0.2. This class attribute was added in vSphere API 8.0.3.0.

extract_task(cluster)

Extract installed images on all the hosts in the cluster. The API will work irrespective of whether a cluster is managed by single software image or not. If the cluster is not managed by single software image, it will first check the possibility to manage with single software image and if this check is successful then only it will extract the installed images on all the hosts. If the cluster is managed by single software image, it will skip eligibility check and directly extract the installed images on all the hosts. This method was added in vSphere API 8.0.3.0.

Parameters:

cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown error. The accompanying error message will give more details about the failure

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized If the caller is not authorized.

Raise:

com.vmware.vapi.std.errors_client.Unsupported if the host does not meet the vLCM transition eligibility criteria

get(cluster)

Returns the last extracted installed Image info. This method was added in vSphere API 8.0.3.0.

Parameters:

cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

InstalledImages.InstalledImageInfo

Returns:

last extracted installed images for the cluster

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized If the caller is not authorized.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.clusters_client.Software(config)

Bases: VapiInterface

The Software class provides methods to manage desired software specification of an ESX cluster.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ApplyResult(status=None, commit=None, host_info=None, host_status=None, successful_hosts=None, failed_hosts=None, skipped_hosts=None, notifications=None)

Bases: VapiStruct

The Software.ApplyResult class contains attributes that describe the result of an Software.apply() method.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.ApplyStatus or None) – Specifies the aggregated status of the Software.apply() method. None if the Software.apply() method is in progress.

  • commit (str) – The identifier of the commit used to fetch the desired software document to be applied to all hosts within the cluster. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – Information of the hosts in this cluster to which the desired software document specified by the Software.ApplyResult.commit should be applied to. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • host_status (dict of str and Software.ApplyStatus) – Status of the hosts in this cluster to which the desired software document specified by the Software.ApplyResult.commit was applied to. Hosts on which the Software.apply() method was successful are specified by Software.ApplyResult.successful_hosts. Hosts on which the apply method failed are specified by Software.ApplyResult.failed_hosts. Hosts which were skipped by the Software.apply() method are specified by Software.ApplyResult.skipped_hosts. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • successful_hosts (set of str) – Hosts in this cluster to which the desired software document specified by the Software.ApplyResult.commit has been successfully applied to. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • failed_hosts (set of str) – Hosts in this cluster to which the desired software document specified by the Software.ApplyResult.commit failed to be applied to. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • skipped_hosts (set of str) – Hosts in this cluster that were skipped by the Software.apply() method. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications providing additional information for Software.apply() method. These notifications are mutually exclusive with the notifications in Software.ApplyStatus. This attribute was added in vSphere API 7.0.2.1. This attribute is optional because it was added in a newer version than its parent node.

class ApplySpec(commit=None, hosts=None, accept_eula=None)

Bases: VapiStruct

The Software.ApplySpec class contains attributes that describe the specification to be used for applying the desired software document to a cluster.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • commit (str or None) – The minimum commit identifier of the desired software document to be used during the Software.apply() method. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the apply method will use the latest commit to fetch the desired state document.

  • hosts (set of str or None) – The specific hosts within the cluster to be considered during the Software.apply() method. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem. if None or empty the Software.apply() method will remediate all hosts within the cluster.

  • accept_eula (bool or None) – Accept the VMware End User License Agreement (EULA) before starting the Software.apply() method. The VMware EULA is available for download at, https://www.vmware.com/download/eula.html if None the Software.apply() method could fail due to the EULA not being accepted.

class ApplyStatus(status=None, progress=None, start_time=None, end_time=None, notifications=None)

Bases: VapiStruct

The Software.ApplyStatus class contains attributes that describe the status of an Software.apply() method.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
class Status(string)

Bases: Enum

The Software.ApplyStatus.Status class contains the possible different status codes that can be returned while trying to Software.apply() the desired software specification to hosts within the cluster.

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.

ERROR = Status(string='ERROR')

The method encountered an unspecified error.

OK = Status(string='OK')

The method completed successfully.

RETRY_PENDING = Status(string='RETRY_PENDING')

The method is being scheduled for retry. This class attribute was added in vSphere API 7.0.2.1.

RUNNING = Status(string='RUNNING')

The method is in progress. This class attribute was added in vSphere API 7.0.1.0.

SKIPPED = Status(string='SKIPPED')

The method was skipped.

TIMED_OUT = Status(string='TIMED_OUT')

The method timed out.

class CheckInfo(check=None, name=None, description=None, originator=None)

Bases: VapiStruct

The Software.CheckInfo class contains attributes that describe a particular check.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
class CheckIssue(description=None, resolution=None)

Bases: VapiStruct

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (com.vmware.vapi.std_client.LocalizableMessage) – Description of what was the issue containing as much user-relevant context as possible. The user should be able to understand which sub-system failed and why. This attribute was added in vSphere API 7.0.2.0.

  • resolution (com.vmware.vapi.std_client.LocalizableMessage or None) – Possible resolution for the issue. This should contain actionable information that the user can use to resolve the issue. This attribute was added in vSphere API 7.0.2.0. Can be left None if no meaningful resolution exists.

class CheckResult(status=None, start_time=None, end_time=None, commit=None, host_info=None, entity_results=None)

Bases: VapiStruct

The Software.CheckResult class contains attributes that describe aggregated status of all checks performed.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.Status) – Aggregated status from all checks performed.

  • start_time (datetime.datetime) – Time when the operation started.

  • end_time (datetime.datetime) – Time when the operation completed.

  • commit (str) – The identifier of the commit on which checks have been run. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – Information about the hosts in this cluster for which checks have been requested to be run. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • entity_results (list of Software.EntityCheckResult) – List of Software.EntityCheckResult for all entities for which checks have been run.

class CheckSpec(commit=None, hosts=None)

Bases: VapiStruct

The Software.CheckSpec class contains attributes that describe the specification to be used for running checks on the cluster before the Software.apply() method.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • commit (str or None) – The minimum commit identifier of the desired software document to be used during the check method. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the check opertion will use the latest commit to fetch the desired state document.

  • hosts (set of str or None) – The specific hosts for which checks need to be performed When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem. if None or empty checks are run for all hosts within the cluster.

class CheckStatus(check=None, status=None, issues=None, check_issues=None)

Bases: VapiStruct

The Software.CheckStatus class contains attributes that describe a check result.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
class EntityCheckResult(type=None, cluster=None, host=None, status=None, check_statuses=None)

Bases: VapiStruct

The Software.EntityCheckResult class contains attributes that describe aggregated status of all checks performed on a specific entity.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • type (Software.EntityCheckResult.EntityType) – The entity type for which these checks are being run.

  • cluster (str) – If the entity type is CLUSTER then the cluster identifier for which the checks have been run. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: ClusterComputeResource. This attribute is optional and it is only relevant when the value of type is Software.EntityCheckResult.EntityType.CLUSTER.

  • host (str) – If the entity type is HOST then the host identifier for which the checks have been run. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: HostSystem. This attribute is optional and it is only relevant when the value of type is Software.EntityCheckResult.EntityType.HOST.

  • status (Software.Status) – Aggregated status from all checks performed on this entity.

  • check_statuses (list of Software.CheckStatus) – List of Software.CheckStatus for all checks performed.

class EntityType(string)

Bases: Enum

The Software.EntityCheckResult.EntityType class contains the entitites on which checks can be performed.

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 EntityType instance.

CLUSTER = EntityType(string='CLUSTER')

Entity type Cluster

HOST = EntityType(string='HOST')

Entity type Host

class ExportSpec(export_software_spec=None, export_iso_image=None, export_offline_bundle=None)

Bases: VapiStruct

The Software.ExportSpec class contains information describing how a software specification or image should be exported.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • export_software_spec (bool) – Whether to export software specification document.

  • export_iso_image (bool) – Whether to export ISO image.

  • export_offline_bundle (bool) – Whether to export offline bundle.

class ExportType(string)

Bases: Enum

The Software.ExportType class defines the formats in which software specification document or image can be exported.

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 ExportType instance.

ISO_IMAGE = ExportType(string='ISO_IMAGE')

Export ISO image.

OFFLINE_BUNDLE = ExportType(string='OFFLINE_BUNDLE')

Export offline bundle.

SOFTWARE_SPEC = ExportType(string='SOFTWARE_SPEC')

Export software specification document.

class StageResult(status=None, commit=None, host_info=None, host_status=None, successful_hosts=None, failed_hosts=None, skipped_hosts=None, notifications=None)

Bases: VapiStruct

The Software.StageResult class contains attributes that describe the result of a Software.stage() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.StageStatus or None) – Specifies the aggregated status of the Software.stage() method. This attribute was added in vSphere API 8.0.0.1. None if the Software.stage() method is in progress.

  • commit (str) – The identifier of the commit used to fetch the desired software document to be staged to all hosts within the cluster. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (dict of str and com.vmware.esx.settings_client.HostInfo) – Information of the hosts in this cluster to which the desired software document specified by the Software.StageResult.commit should be staged to. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • host_status (dict of str and Software.StageStatus) – Status of the hosts in this cluster to which the desired software document specified by the Software.StageResult.commit was staged to. Hosts on which the Software.stage() method was successful are specified by Software.StageResult.successful_hosts. Hosts on which the stage method failed are specified by Software.StageResult.failed_hosts. Hosts which were skipped by the Software.stage() method are specified by Software.StageResult.skipped_hosts. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: HostSystem.

  • successful_hosts (set of str) – Hosts in this cluster to which the desired software document specified by the Software.StageResult.commit has been successfully staged to. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • failed_hosts (set of str) – Hosts in this cluster to which the desired software document specified by the Software.StageResult.commit failed to be staged to. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • skipped_hosts (set of str) – Hosts in this cluster that were skipped by the Software.stage() method. For example hosts which are compliant, or are previously staged shall be skipped. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem.

  • notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications providing additional information for Software.stage() method. These notifications are mutually exclusive with the notifications in Software.StageStatus. This attribute was added in vSphere API 8.0.0.1.

class StageSpec(commit=None, hosts=None)

Bases: VapiStruct

The Software.StageSpec class contains attributes that describe the specification to be used for staging the desired software document to a cluster. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • commit (str or None) – The minimum commit identifier of the desired software document to be used during the Software.stage() method. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the stage method will use the latest commit to fetch the desired state document.

  • hosts (set of str or None) – The specific hosts within the cluster to be considered during the Software.stage() method. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: HostSystem. if None or empty the Software.stage() method will stage all hosts within the cluster.

class StageStatus(status=None, progress=None, start_time=None, end_time=None, notifications=None)

Bases: VapiStruct

The Software.StageStatus class contains attributes that describe the status of a Software.stage() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.StageStatus.Status) – The status of the method. This attribute was added in vSphere API 8.0.0.1.

  • progress (com.vmware.cis.task_client.Progress or None) – Progress of the operation. This attribute was added in vSphere API 8.0.0.1. None for cluster StageStatus

  • start_time (datetime.datetime) – Time when the method started. This attribute was added in vSphere API 8.0.0.1.

  • end_time (datetime.datetime) – Time when the method completed. This attribute was added in vSphere API 8.0.0.1.

  • notifications (com.vmware.esx.settings_client.Notifications) – Notifications providing additional information about the status of the method. This attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: Enum

The Software.StageStatus.Status class contains the possible different status codes that can be returned while trying to Software.stage() the desired software specification to hosts within the cluster. This enumeration was added in vSphere API 8.0.0.1.

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.

ERROR = Status(string='ERROR')

The method encountered an unspecified error. This class attribute was added in vSphere API 8.0.0.1.

OK = Status(string='OK')

The method completed successfully. This class attribute was added in vSphere API 8.0.0.1.

RETRY_PENDING = Status(string='RETRY_PENDING')

The method is being scheduled for retry. This class attribute was added in vSphere API 8.0.0.1.

RUNNING = Status(string='RUNNING')

The method is in progress. This class attribute was added in vSphere API 8.0.0.1.

SKIPPED = Status(string='SKIPPED')

The method was skipped. This class attribute was added in vSphere API 8.0.0.1.

TIMED_OUT = Status(string='TIMED_OUT')

The method timed out. This class attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: Enum

The Software.Status class defines the status result for a particular check.

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.

ERROR = Status(string='ERROR')

The check indicates an error.

OK = Status(string='OK')

The check indicates a success.

RETRY = Status(string='RETRY')

The check failed because of an intermittent error, for example a service is overloaded. The client can choose to retry the health check before considering the check as failed. This class attribute was added in vSphere API 7.0.2.0.

TIMEOUT = Status(string='TIMEOUT')

The check did not return in a timely manner.

WARNING = Status(string='WARNING')

The check indicates a warning.

apply_task(cluster, spec)

Applies the desired software document associated with the given cluster to hosts within the cluster. If commit attribute is set, it implies the minimum commit that the Software.apply() method should use, however if subsequent commits have been made to the desired state document the apply method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.

Parameters:
  • cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Software.ApplySpec) – Apply specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.AlreadyInDesiredState If the cluster is already at specified commit as described in the apply specification.

Raise:

com.vmware.vapi.std.errors_client.Error If there is an unknown internal error or if the EULA has not been accepted. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit, or the hosts attribute of spec specifies an invalid host or a host not part of the cluster, or the cluster is not managed with a single software specification.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

check_task(cluster, spec)

Runs checks on the cluster before applying the desired software document across all hosts in the cluster. Checks if all hosts in the cluster are in a good state to be updated with the desired software document. If commit attribute is set it implies the minimum commit that the check method should use, however if subsequent commits have been made to the desired state document the check method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.

Parameters:
  • cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Software.CheckSpec) – Check specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit, or the hosts attribute of spec specifies an invalid host or a host not part of the cluster.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress or if the commit attribute of spec specifies a commit that has already been applied.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

export(cluster, spec)

Exports the desired software specification document and/or image. This API will not export the solution section of the desired software specification.

Parameters:
  • cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Software.ExportSpec) –

Return type:

dict of Software.ExportType and str

Returns:

A map from export type to URL of the exported data for that type.

Raise:

com.vmware.vapi.std.errors_client.Error If there is am unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSoftwareSpecification.Read.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSoftwareSpecification.Read.

get(cluster)

Returns the complete desired software specification. In case of Homogeneous Cluster, the specification will contain Default Image In case of Heterogeneous Cluster, the specification will contain Default Image + Alternative Images

Parameters:

cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

com.vmware.esx.settings_client.SoftwareInfo

Returns:

Cluster software specification.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSoftwareSpecification.Read.

  • The resource ClusterComputeResource referenced by the parameter cluster requires VcIntegrity.lifecycleSoftwareSpecification.Read.

scan_task(cluster)

Scans all the hosts in the cluster against the cluster’s desired state. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.

Parameters:

cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

stage_task(cluster, spec)

Stages the desired software document associated with the given cluster to hosts within the cluster. If commit attribute is set, it implies the minimum commit that the Software.stage() method should use, however if subsequent commits have been made to the desired state document the stage method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation. This method was added in vSphere API 8.0.0.1.

Parameters:
  • cluster (str) – Identifier of the cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Software.StageSpec) – stage specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is an unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit, or the hosts attribute of spec specifies an invalid host or a host not part of the cluster, or the cluster is not managed with a single software specification.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no cluster associated with cluster in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

class com.vmware.esx.settings.clusters_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.esx.settings.defaults_client module

The com.vmware.esx.settings.defaults_client module provides classes to manage defaults that affect management of desired state configuration and software for ESXi clusters and hosts.

class com.vmware.esx.settings.defaults_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.esx.settings.depot_content_client module

The com.vmware.esx.settings.depot_content_client module provides classes to retrieve contents from the depot.

class com.vmware.esx.settings.depot_content_client.AddOns(config)

Bases: VapiInterface

The AddOns class provides methods to get OEM add-ons from the sync’ed and imported depots.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class AddOnVersionSummary(version=None, display_version=None, summary=None, category=None, kb=None, release_date=None)

Bases: VapiStruct

The AddOns.AddOnVersionSummary class defines the summary information regarding a version of an OEM add-on.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the OEM add-on.

  • display_version (str) – Human readable version of the OEM add-on.

  • summary (str) – Summary of the OEM add-on version.

  • category (AddOns.CategoryType) – Category of the OEM add-on version.

  • kb (str) – Link to kb article related to this the OEM add-on version.

  • release_date (datetime.datetime) – Release date of the OEM add-on version.

class CategoryType(string)

Bases: Enum

The AddOns.CategoryType class defines possible values of categories for a OEM add-on.

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 CategoryType instance.

BUGFIX = CategoryType(string='BUGFIX')

Bugfix

ENHANCEMENT = CategoryType(string='ENHANCEMENT')

Enhancement

SECURITY = CategoryType(string='SECURITY')

Security

class FilterSpec(vendors=None, names=None, versions=None, min_version=None)

Bases: VapiStruct

The AddOns.FilterSpec class contains attributes used to filter the results when listing OEM add-ons, see AddOns.list()).

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • vendors (set of str or None) – Vendors that an add-on must have to match the filter. If None or empty, add-ons from any vendor will match the filter.

  • names (set of str or None) – Names that an add-on must have to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: com.vmware.esx.settings.add_on. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: com.vmware.esx.settings.add_on. If None or empty, add-ons with any name will match the filter.

  • versions (set of str or None) – Versions that an add-on must have to match the filter. If None or empty, add-ons with any version will match the filter.

  • min_version (str or None) – Minimum version of an add-on that can match the filter. If set, only OEM add-ons with version greater than or equal to this will be returned.

RESOURCE_TYPE = 'com.vmware.esx.settings.add_on'

Resource type for add-on resource

class Summary(name=None, display_name=None, vendor=None, versions=None)

Bases: VapiStruct

The AddOns.Summary class defines the summary information regarding a OEM add-on.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • name (str) – Name of the OEM add-on. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.add_on. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.add_on.

  • display_name (str) – Display name of the OEM add-on.

  • vendor (str) – Vendor of the OEM add-on.

  • versions (list of AddOns.AddOnVersionSummary) – Summary information about the versions of this addon. These are sorted by the version.

list(filter=None)

Returns a list of currently available OEM add-ons in the depot.

Parameters:

filter (AddOns.FilterSpec or None) – The specification of matching OEM add-ons. If None, the behavior is equivalent to a AddOns.FilterSpec with all attributes None, which means all OEM add-ons match the filter.

Return type:

list of AddOns.Summary

Returns:

List of OEM add-ons in the depot.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.depot_content_client.BaseImages(config)

Bases: VapiInterface

The BaseImages class provides methods to get base images from the sync’ed and imported depots.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class CategoryType(string)

Bases: Enum

The BaseImages.CategoryType class defines possible values of categories for a base image.

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 CategoryType instance.

BUGFIX = CategoryType(string='BUGFIX')

Bugfix

ENHANCEMENT = CategoryType(string='ENHANCEMENT')

Enhancement

SECURITY = CategoryType(string='SECURITY')

Security

class FilterSpec(min_version=None)

Bases: VapiStruct

The BaseImages.FilterSpec class contains attributes used to filter the results when listing base images, see BaseImages.list()).

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

min_version (str or None) – Minimum version of a base image that can match the filter. If set, only base images with version greater than or equal to this version will be returned.

RESOURCE_TYPE = 'com.vmware.esx.settings.base_image'

Resource type for add-on resource

class Summary(display_name=None, version=None, display_version=None, summary=None, category=None, kb=None, release_date=None, quick_patch_compatible_versions=None)

Bases: VapiStruct

The BaseImages.Summary class defines the summary information regarding a base image.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • display_name (str) – Display name of the base image.

  • version (str) – Version of the base image. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.base_image. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.base_image.

  • display_version (str) – Human readable version of the base image.

  • summary (str) – Summary of the base image.

  • category (BaseImages.CategoryType) – Category of the base image.

  • kb (str) – Link to kb article related to this the base image.

  • release_date (datetime.datetime) – Release date of the base image.

  • quick_patch_compatible_versions ((dict of str and str) or None) – For base images this base image can quick patch from, map their full versions to display versions. This attribute was added in vSphere API 8.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.base_image. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.base_image. If None this base image does not support quick patch.

list(filter=None)

Returns a list of currently available base images in the depot.

Parameters:

filter (BaseImages.FilterSpec or None) – The specification of matching base images. If None, the behavior is equivalent to a BaseImages.FilterSpec with all attributes None, which means all base images match the filter.

Return type:

list of BaseImages.Summary

Returns:

List of base images in the depot. These will be sorted by the version of the base image.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.depot_content_client.Components(config)

Bases: VapiInterface

The Components class provides methods to get Components from the sync’ed and imported depots.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class CategoryType(string)

Bases: Enum

The Components.CategoryType class defines possible values of categories for a component.

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 CategoryType instance.

BUGFIX = CategoryType(string='BUGFIX')

Bugfix

ENHANCEMENT = CategoryType(string='ENHANCEMENT')

Enhancement

GENERAL = CategoryType(string='GENERAL')

General

INFO = CategoryType(string='INFO')

Info

MISC = CategoryType(string='MISC')

Misc

RECALL = CategoryType(string='RECALL')

Recall

RECALL_FIX = CategoryType(string='RECALL_FIX')

Recall-fix

SECURITY = CategoryType(string='SECURITY')

Security

class ComponentBundleType(string)

Bases: Enum

The Components.ComponentBundleType class defines possible ways components are bundled.

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 ComponentBundleType instance.

ADD_ON = ComponentBundleType(string='ADD_ON')

Components bundled in add-ons

BASE_IMAGE = ComponentBundleType(string='BASE_IMAGE')

Components bundled in base-images

INDEPENDENT = ComponentBundleType(string='INDEPENDENT')

Components not bundled in base-images or add-ons

class ComponentVersionSummary(version=None, display_version=None, summary=None, category=None, urgency=None, kb=None, release_date=None)

Bases: VapiStruct

The Components.ComponentVersionSummary class defines the summary information regarding a version of a component.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the component.

  • display_version (str) – Human readable version of the component.

  • summary (str) – Summary of the component version.

  • category (Components.CategoryType) – Category of the component version.

  • urgency (Components.UrgencyType) – Urgency of the component version.

  • kb (str) – Link to kb article related to this the component version.

  • release_date (datetime.datetime) – Release date of the component version.

class FilterSpec(vendors=None, names=None, versions=None, min_version=None, bundle_types=None)

Bases: VapiStruct

The Components.FilterSpec class contains attributes used to filter the results when listing components, see Components.list()).

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • vendors (set of str or None) – Vendors that a component must have to match the filter. If None or empty, components with any vendor name match the filter.

  • names (set of str or None) – Names that a component must have to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: com.vmware.esx.settings.component. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: com.vmware.esx.settings.component. If None or empty, components with any name will match the filter.

  • versions (set of str or None) – Versions that a component must have to match the filter. If None or empty, components with any version will match the filter.

  • min_version (str or None) – Minimum version of the component that can match the filter. If set, only components with version greater than or equal to the given version match the filter.

  • bundle_types (set of Components.ComponentBundleType or None) – Component bundle types that a component must have to match the filter. If None or empty, all components will match the filter.

RESOURCE_TYPE = 'com.vmware.esx.settings.component'

Resource type for add-on resource

class Summary(name=None, display_name=None, vendor=None, versions=None)

Bases: VapiStruct

The Components.Summary class defines the summary information regarding a component.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • name (str) – Name of the Component. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.component. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.component.

  • display_name (str) – Display name of the component.

  • vendor (str) – Vendor of the component.

  • versions (list of Components.ComponentVersionSummary) – Summary information about the versions of this component. These are sorted by the version.

class UrgencyType(string)

Bases: Enum

The Components.UrgencyType class defines possible values of urgencies for a component.

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 UrgencyType instance.

CRITICAL = UrgencyType(string='CRITICAL')

Critical

GENERAL = UrgencyType(string='GENERAL')

General

IMPORTANT = UrgencyType(string='IMPORTANT')

Important

LOW = UrgencyType(string='LOW')

Low

MODERATE = UrgencyType(string='MODERATE')

Moderate

list(filter=None)

Returns a list of currently available components in the depot.

Parameters:

filter (Components.FilterSpec or None) – The specification of matching components. If None, the behavior is equivalent to a Components.FilterSpec with all attributes None, which means ALL components match the filter.

Return type:

list of Components.Summary

Returns:

List of components in the depot.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.depot_content_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.esx.settings.depots_client module

The com.vmware.esx.settings.depots_client module provides classes to manage VUM compatible ESX Depots.

class com.vmware.esx.settings.depots_client.AddonSummary(display_name=None, vendor=None, versions=None)

Bases: VapiStruct

The AddonSummary class contains fields that describe the summary of an addon. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • display_name (str) – Human readable name of the addon. This attribute was added in vSphere API 7.0.3.0.

  • vendor (str) – Vendor of the addon. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.depots.vendor. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.depots.vendor.

  • versions (list of AddonVersion) – Different versions of the addon. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.AddonVersion(version=None, display_version=None)

Bases: VapiStruct

The AddonVersion class contains fields that describe a specific version of an addon. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the addon. This attribute was added in vSphere API 7.0.3.0.

  • display_version (str) – Human readable version of the addon. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.AffectedBaselineInfo(baseline=None, id=None, affected_updates=None)

Bases: VapiStruct

The AffectedBaselineInfo class contains the fields that describe which updates (bulletins) in the baseline will be affected by the depot to be deleted or disabled. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • baseline (str) – Name of the baseline affected. This attribute was added in vSphere API 7.0.3.0.

  • id (long) – Identifier of the baseline affected. This attribute was added in vSphere API 7.0.3.0.

  • affected_updates (dict of str and UpdateSummary) – Updates (bulletins) affected. They key is identifier of the update (bulletin). The value is summary of the update (bulletin). This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.depots.bulletin. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.depots.bulletin.

class com.vmware.esx.settings.depots_client.AffectedDesiredStateInfo(cluster_name=None, cluster_id=None, affected_base_image=None, affected_addon=None, affected_solutions=None, affected_hardware_support=None, affected_independent_components=None)

Bases: VapiStruct

The AffectedDesiredStateInfo class contains the fields that describe which release units in the desired state will be affected by the depot to be deleted or disabled. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • cluster_name (str) – Since now we have standalone host, we use entityName/entityId to better describe name/id of either cluster or standalone host. Name of the cluster the affected desired state belongs to. This attribute was added in vSphere API 7.0.3.0.

  • cluster_id (str) – Identified of the cluster the affected desired state belongs to. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: ClusterComputeResource.

  • affected_base_image (BaseImageVersion or None) – Affected base image of the desired state. This attribute was added in vSphere API 7.0.3.0. If None, no base image of the desired state will be affected.

  • affected_addon ((dict of str and AddonSummary) or None) – Affected addon of the desired state. The key is name of addon. Note: there is at most one addon affected. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.add_on. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.add_on. If None, no addon of the desired state will be affected.

  • affected_solutions ((dict of str and SolutionSummary) or None) – Affected solutions of the desired state. The key is name of solution. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.solution. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.solution. If None, no solution of the desired state will be affected.

  • affected_hardware_support ((dict of str and HardwareSupportManagerSummary) or None) – Affected hardware support of the desired state. The key is HSM name. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager. If None, no hadrware support of the desired state will be affected.

  • affected_independent_components ((dict of str and ComponentSummary) or None) – Affected independent components of the desired state. The components belongs to other base images, addons, solutions and hardware support packages are not counted. The key is name of component. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.component. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.component. If None, no independent components of the desired state will be affected.

class com.vmware.esx.settings.depots_client.BaseImageVersion(version=None, display_name=None, display_version=None)

Bases: VapiStruct

The BaseImageVersion class contains fields that describe a specific ESXi base image. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the base image. This attribute was added in vSphere API 7.0.3.0.

  • display_name (str) – Human readable name of the base image. This attribute was added in vSphere API 7.0.3.0.

  • display_version (str) – Human readable version of the base image. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.ComponentSummary(display_name=None, versions=None)

Bases: VapiStruct

The ComponentSummary class contains fields that describe the summary of a component. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • display_name (str) – Human readable name of the component. This attribute was added in vSphere API 7.0.3.0.

  • versions (list of ComponentVersion) – Different versions of the component. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.ComponentVersion(version=None, display_version=None)

Bases: VapiStruct

The ComponentVersion class contains fields that describe a specific version of a component. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the component. This attribute was added in vSphere API 7.0.3.0.

  • display_version (str) – Human readable version of the component. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.HardwareSupportManagerSummary(display_name=None, packages=None)

Bases: VapiStruct

The HardwareSupportManagerSummary class contains fields that describe the summary of a hardware support manager (HSM). This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • display_name (str) – UI label for HSM, derived from HSM extension’s description’s ‘label’ field. This attribute was added in vSphere API 7.0.3.0.

  • packages (dict of str and HardwareSupportPackageSummary) – Different hardware support packages (HSP) published by the HSM. The key is name of HSP. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.setting.hardware_support.package. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.setting.hardware_support.package.

class com.vmware.esx.settings.depots_client.HardwareSupportPackageSummary(versions=None)

Bases: VapiStruct

The HardwareSupportPackageSummary class contains fields that describe the summary of a hardware support package (HSP). This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

versions (list of HardwareSupportPackageVersion) – Different versions of the HSP. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.HardwareSupportPackageVersion(version=None)

Bases: VapiStruct

The HardwareSupportPackageVersion class contains fields that describe a specific version of a hardware support package (HSP). This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

version (str) – Version of the HSP. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.MetadataInfo(file_name=None, base_images=None, addons=None, solutions=None, hardware_support=None, independent_components=None, updates=None)

Bases: VapiStruct

The MetadataInfo class contains fields that show the content of a metadata bundle. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • file_name (str) – File name of the metadata bundle. This attribute was added in vSphere API 7.0.3.0.

  • base_images (list of BaseImageVersion or None) – All the base images contained in the metadata bundle. This attribute was added in vSphere API 7.0.3.0. If None, the metadata bundle contains no base image.

  • addons ((dict of str and AddonSummary) or None) – All the addons contained in the metadata bundle. The key is name of addon. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.add_on. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.add_on. If None, the metadata bundle contains no addon.

  • solutions ((dict of str and SolutionSummary) or None) – All the solutions contained in the metadata bundle. The key is name of solution. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.solution. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.solution. If None, the metadata bundle contains no solution.

  • hardware_support ((dict of str and HardwareSupportManagerSummary) or None) – All the HSMs and their HSPs contained in the metadata bundle. The key is name of HSM. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager. If None, the metadata bundle contains no hardware support manager.

  • independent_components ((dict of str and ComponentSummary) or None) – All the independent components contained in the metadata bundle. The components belongs to other base images, addons, solutions and hardware support packages are not counted. The ksy is name of component. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.component. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.component. If None, the metadata bundle contains no inpendent component.

  • updates ((dict of str and UpdateSummary) or None) – All the updates (bulletins) contained in the metadata bundle. They key is identifier of the update (bulletin). The value is summary of the update (bulletin). This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the key in the attribute dict must be an identifier for the resource type: com.vmware.esx.settings.depots.bulletin. When methods return a value of this class as a return value, the key in the attribute dict will be an identifier for the resource type: com.vmware.esx.settings.depots.bulletin. If None, the metadata bundle contains no update (bulletin).

class com.vmware.esx.settings.depots_client.Offline(config)

Bases: VapiInterface

The Offline class provides methods to manage offline software depots used during ESX lifecycle management.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ConnectionSpec(auth_type=None, host_credential=None, host=None)

Bases: VapiStruct

The Offline.ConnectionSpec class contains attributes that describe the specification to be used for connecting to the host during the Offline.create_from_host() method. This class was added in vSphere API 7.0.2.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • auth_type (Offline.ConnectionSpec.AuthenticationType) – Specifies what type of authentication (USERNAME_PASSWORD, EXISTING) is to be used when connecting with the host. USERNAME_PASSWORD is intended to be used when connecting to a host that is not currently part of the vCenter inventory. EXISTING is intented for hosts that are in vCenter inventory, in which case, HostServiceTicket will be used to connect to the host. This attribute was added in vSphere API 7.0.2.0.

  • host_credential (Offline.HostCredentials) – Specifies the host details to be used during the Offline.create_from_host() method. This attribute was added in vSphere API 7.0.2.0. This attribute is optional and it is only relevant when the value of authType is Offline.ConnectionSpec.AuthenticationType.USERNAME_PASSWORD.

  • host (str) – Specifies the host Managed Object ID to be used during the Offline.create_from_host() method. This attribute was added in vSphere API 7.0.2.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: HostSystem. This attribute is optional and it is only relevant when the value of authType is Offline.ConnectionSpec.AuthenticationType.EXISTING.

class AuthenticationType(string)

Bases: Enum

The Offline.ConnectionSpec.AuthenticationType class defines the possible types of authentication supported when connecting to the host. This enumeration was added in vSphere API 7.0.2.0.

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 AuthenticationType instance.

EXISTING = AuthenticationType(string='EXISTING')

Connect to the host using service ticket. Note: This is supported only for hosts present in the VC inventory. This class attribute was added in vSphere API 7.0.2.0.

USERNAME_PASSWORD = AuthenticationType(string='USERNAME_PASSWORD')

Connect to host using host’s credentials class. This class attribute was added in vSphere API 7.0.2.0.

class CreateResult(depot=None)

Bases: VapiStruct

The Offline.CreateResult class defines the result information for a new offline depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

depot (str) – Identifier of the offline depot. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.depots.offline. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.depots.offline.

class CreateSpec(description=None, source_type=None, location=None, file_id=None, ownerdata=None)

Bases: VapiStruct

The Offline.CreateSpec class defines the information used to create a depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str or None) – Description of the depot. If None, the description will be empty.

  • source_type (Offline.SourceType) – Type of the source from which offline bundle is obtained.

  • location (str) – Location of the depot from which content should be retrieved. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PULL.

  • file_id (str) – File identifier returned by the file upload endpoint after file is uploaded. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PUSH.

  • ownerdata (str or None) – Private data saved by the Offline.Info.owner of the depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. If None, no ownerdata will be saved.

class DeleteResult(notifications=None)

Bases: VapiStruct

The Offline.DeleteResult class contains a field that lists all the errors encountered after starting the task of Offline.delete() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications returned by Offline.delete() method. This attribute was added in vSphere API 7.0.3.0. If None, no notification is returned.

class DepotExtractInfo(notifications=None, software_spec=None, result=None)

Bases: VapiStruct

The Offline.DepotExtractInfo class contains attributes that describe the extracted depot. This class was added in vSphere API 7.0.2.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • notifications (com.vmware.esx.settings_client.Notifications) – Notifications returned by the extractDepot operation. This attribute was added in vSphere API 7.0.2.0.

  • software_spec (com.vmware.esx.settings_client.SoftwareSpec) – Software specification of the extracted depot. This attribute was added in vSphere API 7.0.2.0.

  • result (Offline.CreateResult) – The information about the created offline depot. Empty \@name{result} \@term{string} indicates that the depot contents are already present in VC cache. This attribute was added in vSphere API 7.0.2.0.

class HostCredentials(host_name=None, user_name=None, password=None, port=None, ssl_thumb_print=None)

Bases: VapiStruct

The Offline.HostCredentials class contains attributes that describe the host’s username, password, port number, ssl thumbprint or ssl certificate to be used when connecting to the host using USERNAME_PASSWORD option in the class. This class was added in vSphere API 7.0.2.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • host_name (str) – The IP address or DNS resolvable name of the host. This attribute was added in vSphere API 7.0.2.0.

  • user_name (str) – Specifies the username to be used during the Offline.create_from_host() method. This attribute was added in vSphere API 7.0.2.0.

  • password (str) – Specifies the password to be used during the Offline.create_from_host() method. This attribute was added in vSphere API 7.0.2.0.

  • port (long or None) – Specifies the port number of the host to be used during Offline.create_from_host() method. This attribute was added in vSphere API 7.0.2.0. If None, port number is set to 443.

  • ssl_thumb_print (str or None) – Specifies the sslThumbPrint of the host to be used during Offline.create_from_host() method SHA1 hash of the host’s SSL certificate. This attribute was added in vSphere API 7.0.2.0. If None, Offline.create_from_host() method this operation will throw UnverifiedPeer with the host provided thumbprint as data.

class Info(description=None, source_type=None, location=None, file_id=None, create_time=None, owner=None, ownerdata=None)

Bases: VapiStruct

The Offline.Info class defines the information regarding an offline depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str) – Description of the depot. If not set during import, it will be empty.

  • source_type (Offline.SourceType) – Type of the source from which offline depot is obtained.

  • location (str) – Location of the depot from which content is retrieved. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PULL.

  • file_id (str) – File identifier returned by the file upload endpoint after file is uploaded. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PUSH.

  • create_time (datetime.datetime) – Time when the depot was created.

  • owner (str or None) – Name of the user creating the depot. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

  • ownerdata (str or None) – Private data saved by the owner of depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

class PrecheckResult(affected_baselines=None, affected_desired_states=None)

Bases: VapiStruct

The Offline.PrecheckResult class contains the fields that show the details of affected baselines and desired states found in Offline.delete() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • affected_baselines (list of AffectedBaselineInfo or None) – Baselines affected. This attribute was added in vSphere API 7.0.3.0. If None, no baseline is affected.

  • affected_desired_states (list of AffectedDesiredStateInfo or None) – Desired states affected. This attribute was added in vSphere API 7.0.3.0. If None, no desired state is affected.

RESOURCE_TYPE = 'com.vmware.esx.settings.depots.offline'

Resource type for depots resource

class SourceType(string)

Bases: Enum

The Offline.SourceType class defines possible values of sources for the offline depot.

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 SourceType instance.

PULL = SourceType(string='PULL')

Content is pulled from the URL location. The URL scheme of the value in {\@link CreateSpec#location) can be http, https or file.

PUSH = SourceType(string='PUSH')

Content was previously uploaded using the file upload enpoint present on vCenter appliance. This endpoint is present at https://VCENTERFQDN:9087/vum-fileupload URL.

class Summary(description=None, source_type=None, location=None, file_id=None, owner=None, ownerdata=None)

Bases: VapiStruct

The Offline.Summary class defines the summary information regarding an offline depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str) – Description of the depot. If not set during import, it will be empty.

  • source_type (Offline.SourceType) – Type of the source from which offline depot is obtained.

  • location (str) – Location of the depot from which content is retrieved. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PULL.

  • file_id (str) – File identifier returned by the file upload endpoint after file is uploaded. This attribute is optional and it is only relevant when the value of sourceType is Offline.SourceType.PUSH.

  • owner (str or None) – Name of the user creating the depot. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

  • ownerdata (str or None) – Private data saved by the owner of depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

create_from_host_task(spec)

Extract the current software specification applied to the host and import it into the depot. Returns details about the current software specification applied to the host.

The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.. This method was added in vSphere API 7.0.2.0.

Parameters:

spec (Offline.ConnectionSpec) – ConnectionSpec connection spec for the host.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the Offline.HostCredentials attribute of spec is invalid.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no Offline.HostCredentials.host_name attribute associated with host id in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.UnverifiedPeer If the SSL certificate of the target node cannot be validated by comparing with the thumbprint provided in ConnectionSpec.HostCredentials#sslThumbPrint or the full certificate provided in ConnectionSpec.HostCredentials#sslCertificate.

create_task(spec)

Imports a new offline software depot. This will also import the metadata and payloads from this offline depot. The returned task will fail and no offline depot would be created if there are any issues during import. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.

Warning: Using HTTP is not secure. Please use HTTPS URLs instead.

Parameters:

spec (Offline.CreateSpec) – Specification to import an offline depot.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If an invalid Offline.CreateSpec.location is provided.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.AlreadyExists If the depot content already exists. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be a class that contains existing depot identifier as part of depot attribute defined in Offline.CreateResult.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

delete(depot)

The task-based delete method removes content of an imported offline depot from vLCM completely.

Note: The non task-based delete method has been deprecated. It deletes only the record of depot from the list of imported offline software depots, instead of removing the depot’s content from vLCM.

Parameters:

depot (str) – Identifier of the depot to be removed. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.offline.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the given depot is system-defined. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of depot to be deleted is used in some baseline or desired state. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error. The accompanying error message will give more details about the failure. For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

delete_task(depot)

The task-based delete method removes content of an imported offline depot from vLCM completely.

Note: The non task-based delete method has been deprecated. It deletes only the record of depot from the list of imported offline software depots, instead of removing the depot’s content from vLCM.

Parameters:

depot (str) – Identifier of the depot to be removed. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.offline.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the given depot is system-defined. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of depot to be deleted is used in some baseline or desired state. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error. The accompanying error message will give more details about the failure. For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

get(depot)

Gets the information about an imported offline software depot.

Parameters:

depot (str) – Identifier for the depot. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.offline.

Return type:

Offline.Info

Returns:

Information about the imported offline software depot.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot with given identifier depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

list()

Returns currently imported offline software depots.

Return type:

dict of str and Offline.Summary

Returns:

Map of currently imported offline software depots keyed by their identifier. The key in the return value dict will be an identifier for the resource type: com.vmware.esx.settings.depots.offline.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.depots_client.Online(config)

Bases: VapiInterface

The Online class provides methods to manage online software depots used during ESX lifecycle management.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class CreateSpec(description=None, location=None, enabled=None, ownerdata=None)

Bases: VapiStruct

The Online.CreateSpec class defines the information used to create a depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str or None) – Description of the depot. If None, the description will be empty.

  • location (str) – Location of the depot. It should be the location to the index.xml for the depot.

  • enabled (bool or None) – Flag indicating whether this depot is enabled or not. Disabling the depot doesn’t delete its cached metadata and payloads. It will not be refreshed next time depots are re-synced. If None, the depot will be enabled.

  • ownerdata (str or None) – Private data saved by the Online.Info.owner of the depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. If None, no ownerdata will be saved.

class DeleteResult(notifications=None)

Bases: VapiStruct

The Online.DeleteResult class contains a field that lists all the errors encountered after starting the task of Online.delete() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications returned by Online.delete() method. This attribute was added in vSphere API 7.0.3.0. If None, no notification is returned.

class FlushResult(notifications=None)

Bases: VapiStruct

The Online.FlushResult class contains a field that lists all the errors encountered after starting the task of Online.flush() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications returned by Online.flush() method. This attribute was added in vSphere API 7.0.3.0. If None, no notification is returned.

class Info(description=None, location=None, enabled=None, system_defined=None, owner=None, ownerdata=None)

Bases: VapiStruct

The Online.Info class defines the information regarding a depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str) – Description of the depot. It will be an empty string if no description was provided during create.

  • location (str) – Location of the depot.

  • enabled (bool) – Flag indicating whether this depot is enabled or not.

  • system_defined (bool) – Flag to indicate if the depot is system defined. System defined depot can not be deleted.

  • owner (str or None) – Name of the user creating the depot. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

  • ownerdata (str or None) – Private data saved by the owner of depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

class PrecheckResult(affected_baselines=None, affected_desired_states=None)

Bases: VapiStruct

The Online.PrecheckResult class contains the fields that show the details of affected baselines and desired states found in Online.delete() or Online.flush() operation. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • affected_baselines (list of AffectedBaselineInfo or None) – Baselines affected. This attribute was added in vSphere API 7.0.3.0. If None, no baseline is affected.

  • affected_desired_states (list of AffectedDesiredStateInfo or None) – Desired states affected. This attribute was added in vSphere API 7.0.3.0. If None, no desired state is affected.

RESOURCE_TYPE = 'com.vmware.esx.settings.depots.online'

Resource type for depots resource

class Summary(description=None, location=None, enabled=None, system_defined=None, owner=None, ownerdata=None)

Bases: VapiStruct

The Online.Summary class defines the summary information regarding a depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str) – Description of the depot. It will be an empty string if no description was provided during create.

  • location (str) – Location of the depot.

  • enabled (bool) – Flag indicating whether this depot is enabled or not.

  • system_defined (bool) – Flag to indicate if the depot is system defined. System defined depot can not be deleted.

  • owner (str or None) – Name of the user creating the depot. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

  • ownerdata (str or None) – Private data saved by the owner of depot. It is opaque to vLCM. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

class UpdateSpec(enabled=None, description=None)

Bases: VapiStruct

The Online.UpdateSpec class defines the information used to update the depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • enabled (bool or None) – Flag indicating whether this depot is enabled or not. Disabling the depot doesn’t delete its cached metadata and payloads. It will not be refreshed next time depots are re-synced. If None, enabled flag is not updated.

  • description (str or None) – Description of the depot. If None, description is not updated.

create(spec)

Adds a new online software depot to the list of currently configured online software depots.

Warning: Using HTTP is not secure. Please use HTTPS URLs instead.

Parameters:

spec (Online.CreateSpec) – Depot information.

Return type:

str

Returns:

Identifier of the currently configured online depot. The return value will be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If an invalid location is provided.

Raise:

com.vmware.vapi.std.errors_client.AlreadyExists If depot with given location already exists.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

delete(depot)

The task-based delete method removes content of a user-imported online depot from vLCM completely. As a result, the URL of the user-imported online depot will also be removed.

Note:

1. To remove content of system-defined online depots, use flush method.

2. The non task-based delete method has been deprecated. It only deletes the record of depot from the list of imported online software depots, instead of removing the depot’s content from the system.

Parameters:

depot (str) – Identifier of the depot to be removed. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the given depot is system-defined. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of depot to be deleted is used in some baseline or desired state.

The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states.

This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error.

The accompanying error message will give more details about the failure.

For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

delete_task(depot)

The task-based delete method removes content of a user-imported online depot from vLCM completely. As a result, the URL of the user-imported online depot will also be removed.

Note:

1. To remove content of system-defined online depots, use flush method.

2. The non task-based delete method has been deprecated. It only deletes the record of depot from the list of imported online software depots, instead of removing the depot’s content from the system.

Parameters:

depot (str) – Identifier of the depot to be removed. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the given depot is system-defined. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of depot to be deleted is used in some baseline or desired state.

The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states.

This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error.

The accompanying error message will give more details about the failure.

For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

flush_task(depot)

The task-based flush method removes content of a system-defined online depot from vLCM completely. As a result, the system-defined online depot will be disabled.

Note: To remove content of user-imported online depots, use the task-based delete method.

Parameters:

depot (str) – Identifier of the depot to be removed. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the given depot is NOT system-defined.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of depot to be deleted is used in some baseline or desired state. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error. The accompanying error message will give more details about the failure. flush is a task-based method. Once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the FlushResult class that lists all the errors encountered.

get(depot)

Gets the information about a currently configured online software depot.

Parameters:

depot (str) – Identifier for the depot. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Return type:

Online.Info

Returns:

Information of the currently configured online software depot.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot with given identifier depot in the system.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

list()

Returns a list of currently configured online software depots.

Return type:

dict of str and Online.Summary

Returns:

Map of currently configured online software depots keyed by their identifiers. The key in the return value dict will be an identifier for the resource type: com.vmware.esx.settings.depots.online.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

update(depot, spec)

Updates the configuration of a currently configured online software depot.

Parameters:
  • depot (str) – Identifier of the depot to be updated. The parameter must be an identifier for the resource type: com.vmware.esx.settings.depots.online.

  • spec (Online.UpdateSpec) – Update specification.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If given depot is system defined.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot associated with parameter depot in the system.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

class com.vmware.esx.settings.depots_client.SolutionSummary(display_name=None, versions=None)

Bases: VapiStruct

The SolutionSummary class contains fields that describe the summary of a solution. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • display_name (str) – Human readable name of the solution. This attribute was added in vSphere API 7.0.3.0.

  • versions (list of SolutionVersion) – Different versions of the solution. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.SolutionVersion(version=None, display_version=None)

Bases: VapiStruct

The SolutionVersion class contains fields that describe a specific version of a solution. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • version (str) – Version of the solution. This attribute was added in vSphere API 7.0.3.0.

  • display_version (str) – Human readable version of the solution. This attribute was added in vSphere API 7.0.3.0.

class com.vmware.esx.settings.depots_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

class com.vmware.esx.settings.depots_client.SyncSchedule(config)

Bases: VapiInterface

The SyncSchedule class provides methods to manage Schedule of Online Software Depot sync.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class DayOfWeek(string)

Bases: Enum

The SyncSchedule.DayOfWeek class contains the supported days of the week.

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 DayOfWeek instance.

FRIDAY = DayOfWeek(string='FRIDAY')

Friday.

MONDAY = DayOfWeek(string='MONDAY')

Monday.

SATURDAY = DayOfWeek(string='SATURDAY')

Saturday.

SUNDAY = DayOfWeek(string='SUNDAY')

Sunday.

THURSDAY = DayOfWeek(string='THURSDAY')

Thursday.

TUESDAY = DayOfWeek(string='TUESDAY')

Tuesday.

WEDNESDAY = DayOfWeek(string='WEDNESDAY')

Wednesday.

class Recurrence(string)

Bases: Enum

The SyncSchedule.Recurrence class contains the supported values for how often to sync from online or UMDS depots.

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 Recurrence instance.

DAILY = Recurrence(string='DAILY')

Daily.

HOURLY = Recurrence(string='HOURLY')

Hourly.

MONTHLY_BY_DAY = Recurrence(string='MONTHLY_BY_DAY')

Monthly by day.

WEEKLY = Recurrence(string='WEEKLY')

Weekly.

class Schedule(type=None, skip=None, minute=None, hour=None, day_of_month=None, day_of_week=None)

Bases: VapiStruct

The SyncSchedule.Schedule class defines a schedule.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
class Spec(enabled=None, schedule=None, email_addresses=None)

Bases: VapiStruct

The SyncSchedule.Spec class defines the information regarding the sync schedule.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • enabled (bool) – Flag indicating whether automatic sync is enabled or not

  • schedule (SyncSchedule.Schedule or None) – The schedule to check for new updates. If None the schedule must be disabled.

  • email_addresses (list of str) – Email addresses to which the notification will be sent. If empty, no notification is sent.

get()

Returns the currently configured software depot sync schedule.

Return type:

SyncSchedule.Spec

Returns:

Currently configured sync schedule.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

set(spec=None)

Sets the software depot sync schedule.

Parameters:

spec (SyncSchedule.Spec or None) – Information of the software depot sync schedule. If None, it will be reset to the default schedule, which is daily at a random hour chosen when this API is called.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If SyncSchedule.Spec.schedule is unset while SyncSchedule.Spec.enabled is set to true or if any of the values is not within valid range.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

class com.vmware.esx.settings.depots_client.Umds(config)

Bases: VapiInterface

The Umds class provides methods to manage the VMware vSphere Update Manager Download Service (UMDS) software depot used during ESX lifecycle management. This is the depot downloaded using UMDS. If the UMDS depot is specified, then online depots are ignored and data is downloaded only from the UMDS depot.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class DeleteResult(notifications=None)

Bases: VapiStruct

The Umds.DeleteResult class contains a field that lists all the errors encountered after starting the task of Umds.delete() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications returned by Umds.delete() method. This attribute was added in vSphere API 7.0.3.0. If None, no notification is returned.

class Info(description=None, enabled=None, location=None, owner=None)

Bases: VapiStruct

The Umds.Info class defines the information regarding the UMDS Depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str) – Description of the depot. It will be an empty string if no description was provided during create.

  • enabled (bool) – Flag indicating whether or not this depot is enabled.

  • location (str) – Location of the depot.

  • owner (str or None) – Name of the user creating the depot. This attribute was added in vSphere API 7.0.3.0. This attribute is optional because it was added in a newer version than its parent node.

class PrecheckResult(affected_baselines=None, affected_desired_states=None)

Bases: VapiStruct

The Umds.PrecheckResult class contains the fields that show the details of affected baselines and desired states found in Umds.delete() method. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • affected_baselines (list of AffectedBaselineInfo or None) – Baselines affected. This attribute was added in vSphere API 7.0.3.0. If None, no baseline is affected.

  • affected_desired_states (list of AffectedDesiredStateInfo or None) – Desired states affected. This attribute was added in vSphere API 7.0.3.0. If None, no desired state is affected.

class SetSpec(description=None, enabled=None, location=None)

Bases: VapiStruct

The Umds.SetSpec class defines the information of an UMDS depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (str or None) – Description of the depot. If None, the description will be empty.

  • enabled (bool or None) – Flag indicating whether or not this depot should be enabled. Disabling the depot doesn’t delete its cached metadata and payloads. It will not be refreshed next time depots are re-synced. If None, the depot will be enabled.

  • location (str) – Location of the depot. It should be the location to the index.xml for the depot.

class UpdateSpec(enabled=None, description=None)

Bases: VapiStruct

The Umds.UpdateSpec class defines the information used to update the UMDS depot.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • enabled (bool or None) – Flag indicating whether or not this depot is enabled. Disabling the depot doesn’t delete its cached metadata and payloads. It will not be refreshed next time depots are re-synced. If None, the enabled flag is not updated.

  • description (str or None) – Description of the depot. If None, the description is not updated.

delete()

The task-based delete method removes content of the UMDS depot from vLCM completely. Note: The non task-based delete method has been deprecated. It deletes only the record of UMDS depot from database, instead of removing the content of UMDS depot from vLCM.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no UMDS depot configured in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of UMDS depot to be deleted is used in some baseline or desired state. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error. The accompanying error message will give more details about the failure. For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

delete_task()

The task-based delete method removes content of the UMDS depot from vLCM completely. Note: The non task-based delete method has been deprecated. It deletes only the record of UMDS depot from database, instead of removing the content of UMDS depot from vLCM.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no UMDS depot configured in the system.

Raise:

com.vmware.vapi.std.errors_client.ResourceInUse If the content of UMDS depot to be deleted is used in some baseline or desired state. The value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the PrecheckResult class that lists the information of affected baselines and desired states. This error is applicable to the task-based delete method only.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there some unknown internal error. The accompanying error message will give more details about the failure. For task-based delete method, once the task is started, it does NOT stop if encountering an error. Instead, it will continuously run to completion. In this case, the value of the data attribute of com.vmware.vapi.std.errors_client.Error will be the DeleteResult class that lists all the errors encountered.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleDepots.Delete.

get()

Gets the information about a currently configured UMDS software depot.

Return type:

Umds.Info

Returns:

Information of the currently configured UMDS software depot.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no UMDS software depot set.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

set(spec)

Sets or overwrites information about the UMDS software depot.

Parameters:

spec (Umds.SetSpec) – Specification to set the UMDS depot.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If an invalid location is provided.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

update(spec)

Updates the configuration of a currently configured UMDS software depot.

Parameters:

spec (Umds.UpdateSpec) – Update specification.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no UMDS depot configured.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

class com.vmware.esx.settings.depots_client.UpdateSummary(summary=None)

Bases: VapiStruct

The UpdateSummary class contains a fieldsthat describes the summary of an update (bulletin). This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

summary (str) – Summary of the update (bulletin). This attribute was added in vSphere API 7.0.3.0.

com.vmware.esx.settings.hardware_support_client module

class com.vmware.esx.settings.hardware_support_client.Managers(config)

Bases: VapiInterface

The Managers class provides methods to list Hardware Support Manager (HSM) for a given vCenter.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class HardwareSupportManagerInfo(manager=None, description=None, display_name=None, vendor=None)

Bases: VapiStruct

The Managers.HardwareSupportManagerInfo class contains attributes that describe a particular 3rd party Hardware Support Manager (HSM)

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • manager (str) – Name of the Hardware Support Manager (HSM) (e.g. “Frobozz Hardware Support Manager”) When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.setting.hardware_support.manager.

  • description (str) – User-intelligible description of the HSM (e.g. “Front end for Frobozz so-and-so management system”)

  • display_name (str) – UI label for HSM, derived from HSM extension’s description’s ‘label’ field. (e.g. “Frobozz Free Management System”)

  • vendor (str) – Company providing the Hardware Support Manager (HSM) (e.g. “Frobozz Magic Software Company”)

list()

Returns the list of registered Hardware Support Managers (HSMs) in the system.

Return type:

list of Managers.HardwareSupportManagerInfo

Returns:

List of currently registered Hardware Support Manager (HSMs)

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

class com.vmware.esx.settings.hardware_support_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.esx.settings.hosts_client module

The com.vmware.esx.settings.hosts_client module provides classes to manage desired state configuration and software for a standalone ESX host.

class com.vmware.esx.settings.hosts_client.Configuration(config)

Bases: VapiInterface

The Configuration class provides methods to manage configuration of a ESX host. This class was added in vSphere API 8.0.1.0.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ExtractResult(config=None)

Bases: VapiStruct

The Info class defines the information about configuration extracted from a ESXi host. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

config (str) – ESXi host configuration encoded as JSON. This attribute was added in vSphere API 8.0.1.0.

extract(host)

Extracts a configuration document from the ESXi host,. This method was added in vSphere API 8.0.1.0.

Parameters:

host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

Return type:

Configuration.ExtractResult

Returns:

The result contains the configuration of the ESXi host encoded as JSON.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.ClusterConfiguration.Modify.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.ClusterConfiguration.Modify.

class com.vmware.esx.settings.hosts_client.DepotOverrides(config)

Bases: VapiInterface

The DepotOverrides class provides methods to manage software depots overriden for a given host. In general ESX servers reach out to vCenter (VUM) to fetch the metadata and payloads required for lifecycle operations. But in ROBO environments ESX hosts can’t (or because of bandwidth requirements shouldn’t) reach out to vCenter to fetch payloads and metadata. This class allows setting host level overrides for depots. If any depots are provided for a host, then vCenter level depots are not used for that host’s remediation. These are not synced periodically at vCenter and are only used by ESXs for lifecycle operations. This class was added in vSphere API 8.0.1.0.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class Depot(location=None)

Bases: VapiStruct

The DepotOverrides.Depot class defines the information regarding a particular depot override for a given host. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

location (str) – Location of the depot override. This could be a location of zip file or location to an index.xml file. This attribute was added in vSphere API 8.0.1.0.

class Info(depots=None)

Bases: VapiStruct

The DepotOverrides.Info class defines the information regarding depot overrides for a given host. This class was added in vSphere API 8.0.1.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

depots (list of DepotOverrides.Depot) – List of the depot overrides. This attribute was added in vSphere API 8.0.1.0.

add(host, depot)

Adds a new depot override to the list of currently configured depot overrides for a given host.

Warning: Using HTTP is not secure. Please use HTTPS URLs instead.. This method was added in vSphere API 8.0.1.0.

Parameters:
  • host (str) – Identifier for the host. The parameter must be an identifier for the resource type: HostSystem.

  • depot (DepotOverrides.Depot) – Information of a depot override.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If an invalid location is provided.

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.AlreadyExists if depot override with given information already exists.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.lifecycleSettings.Write.

get(host)

Returns the information about currently configured depot overrides for a given host. This method was added in vSphere API 8.0.1.0.

Parameters:

host (str) – Identifier for the host. The parameter must be an identifier for the resource type: HostSystem.

Return type:

DepotOverrides.Info

Returns:

Information about currently configured depot overrides for a given host.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Read.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.lifecycleSettings.Read.

remove(host, depot)

Removes a depot override from the list of currently configured depot overrides for a given host. This method was added in vSphere API 8.0.1.0.

Parameters:
  • host (str) – Identifier for the host. The parameter must be an identifier for the resource type: HostSystem.

  • depot (DepotOverrides.Depot) – Information of the depot override to be removed.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated if the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no depot override with given information or no host associated with identifier {param.name host} in the system.

Raise:

com.vmware.vapi.std.errors_client.Error If there is some unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSettings.Write.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.lifecycleSettings.Write.

class com.vmware.esx.settings.hosts_client.Software(config)

Bases: VapiInterface

The Software class provides methods to manage desired software specification of a standalone ESX host.

Parameters:

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ApplyResult(status=None, commit=None, host_info=None, notifications=None)

Bases: VapiStruct

The Software.ApplyResult class contains attributes that describe the result of an Software.apply() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.ApplyStatus or None) – Specifies the aggregated status of the Software.apply() method. This attribute was added in vSphere API 8.0.0.1. None if the Software.apply() method is in progress.

  • commit (str) – The identifier of the commit used to fetch the desired software document to be applied to host. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (com.vmware.esx.settings_client.HostInfo) – Information of the host to which the desired software document specified by the Software.ApplyResult.commit was applied. This attribute was added in vSphere API 8.0.0.1.

  • notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications providing additional information for Software.apply() method. These notifications are mutually exclusive with the notifications in Software.ApplyStatus. This attribute was added in vSphere API 8.0.0.1.

class ApplySpec(commit=None, accept_eula=None)

Bases: VapiStruct

The Software.ApplySpec class contains attributes that describe the specification to be used for applying the desired software document to a host. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • commit (str or None) – The minimum commit identifier of the desired software document to be used during the Software.apply() method. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the apply method will use the latest commit to fetch the desired state document.

  • accept_eula (bool or None) – Accept the VMware End User License Agreement (EULA) before starting the Software.apply() method. The VMware EULA is available for download at, https://www.vmware.com/download/eula.html. This attribute was added in vSphere API 8.0.0.1. if None the Software.apply() method could fail due to the EULA not being accepted.

class ApplyStatus(status=None, progress=None, start_time=None, end_time=None, notifications=None)

Bases: VapiStruct

The Software.ApplyStatus class contains attributes that describe the status of an Software.apply() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.ApplyStatus.Status) – The status of the method. This attribute was added in vSphere API 8.0.0.1.

  • progress (com.vmware.cis.task_client.Progress or None) – Progress of the operation. This attribute was added in vSphere API 8.0.0.1. None for host ApplyStatus

  • start_time (datetime.datetime) – Time when the method started. This attribute was added in vSphere API 8.0.0.1.

  • end_time (datetime.datetime) – Time when the method completed. This attribute was added in vSphere API 8.0.0.1.

  • notifications (com.vmware.esx.settings_client.Notifications) – Notifications providing additional information about the status of the method. This attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: Enum

The Software.ApplyStatus.Status class contains the possible different status codes that can be returned while trying to Software.apply() the desired software specification to host. This enumeration was added in vSphere API 8.0.0.1.

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.

ERROR = Status(string='ERROR')

The method encountered an unspecified error. This class attribute was added in vSphere API 8.0.0.1.

OK = Status(string='OK')

The method completed successfully. This class attribute was added in vSphere API 8.0.0.1.

RETRY_PENDING = Status(string='RETRY_PENDING')

The method is being scheduled for retry. This class attribute was added in vSphere API 8.0.0.1.

RUNNING = Status(string='RUNNING')

The method is in progress. This class attribute was added in vSphere API 8.0.0.1.

SKIPPED = Status(string='SKIPPED')

The method was skipped. This class attribute was added in vSphere API 8.0.0.1.

TIMED_OUT = Status(string='TIMED_OUT')

The method timed out. This class attribute was added in vSphere API 8.0.0.1.

class CheckInfo(check=None, name=None, description=None, originator=None)

Bases: VapiStruct

The Software.CheckInfo class contains attributes that describe a particular check. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • check (str) – The check identifier. This attribute was added in vSphere API 8.0.0.1.

  • name (com.vmware.vapi.std_client.LocalizableMessage) – The check name. This attribute was added in vSphere API 8.0.0.1.

  • description (com.vmware.vapi.std_client.LocalizableMessage) – Human-readable check description. This attribute was added in vSphere API 8.0.0.1.

  • originator (str or None) – The service that performed the check. This attribute was added in vSphere API 8.0.0.1. Only set if there is an originator available for this check.

class CheckIssue(description=None, resolution=None)

Bases: VapiStruct

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • description (com.vmware.vapi.std_client.LocalizableMessage) – Description of what was the issue containing as much user-relevant context as possible. The user should be able to understand which sub-system failed and why. This attribute was added in vSphere API 8.0.0.1.

  • resolution (com.vmware.vapi.std_client.LocalizableMessage or None) – Possible resolution for the issue. This should contain actionable information that the user can use to resolve the issue. This attribute was added in vSphere API 8.0.0.1. Can be left None if no meaningful resolution exists.

class CheckResult(status=None, start_time=None, end_time=None, commit=None, host_info=None, entity_result=None)

Bases: VapiStruct

The Software.CheckResult class contains attributes that describe aggregated status of all checks performed. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.Status) – Aggregated status from all checks performed. This attribute was added in vSphere API 8.0.0.1.

  • start_time (datetime.datetime) – Time when the operation started. This attribute was added in vSphere API 8.0.0.1.

  • end_time (datetime.datetime) – Time when the operation completed. This attribute was added in vSphere API 8.0.0.1.

  • commit (str) – The identifier of the commit on which checks have been run. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (com.vmware.esx.settings_client.HostInfo) – Information about the host for which checks have been requested to be run. This attribute was added in vSphere API 8.0.0.1.

  • entity_result (Software.EntityCheckResult) – List of Software.EntityCheckResult for all entities for which checks have been run. This attribute was added in vSphere API 8.0.0.1.

class CheckSpec(commit=None)

Bases: VapiStruct

The Software.CheckSpec class contains attributes that describe the specification to be used for running checks on the host before the Software.apply() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

commit (str or None) – The minimum commit identifier of the desired software document to be used during the check method. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the check opertion will use the latest commit to fetch the desired state document.

class CheckStatus(check=None, status=None, check_issues=None)

Bases: VapiStruct

The Software.CheckStatus class contains attributes that describe a check result. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • check (Software.CheckInfo) – Information about this check. This attribute was added in vSphere API 8.0.0.1.

  • status (Software.Status) – The status of this check. This attribute was added in vSphere API 8.0.0.1.

  • check_issues (list of Software.CheckIssue or None) – List of Software.CheckIssue`s that the check reported. This attribute was added in vSphere API 8.0.0.1. If not :class:`set, the service is still using the {#member issues}.

class EntityCheckResult(type=None, host=None, status=None, check_statuses=None)

Bases: VapiStruct

The Software.EntityCheckResult class contains attributes that describe aggregated status of all checks performed on a specific entity. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • type (Software.EntityCheckResult.EntityType) – The entity type for which these checks are being run. This attribute was added in vSphere API 8.0.0.1.

  • host (str) – If the entity type is HOST then the host identifier for which the checks have been run. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: HostSystem. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: HostSystem. This attribute is optional and it is only relevant when the value of type is Software.EntityCheckResult.EntityType.HOST.

  • status (Software.Status) – Aggregated status from all checks performed on this entity. This attribute was added in vSphere API 8.0.0.1.

  • check_statuses (list of Software.CheckStatus) – List of Software.CheckStatus for all checks performed. This attribute was added in vSphere API 8.0.0.1.

class EntityType(string)

Bases: Enum

The Software.EntityCheckResult.EntityType class contains the entitites on which checks can be performed. This enumeration was added in vSphere API 8.0.0.1.

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 EntityType instance.

HOST = EntityType(string='HOST')

Entity type Host. This class attribute was added in vSphere API 8.0.0.1.

class ExportSpec(export_software_spec=None, export_iso_image=None, export_offline_bundle=None)

Bases: VapiStruct

The Software.ExportSpec class contains information describing how a software specification or image should be exported. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • export_software_spec (bool) – Whether to export software specification document. This attribute was added in vSphere API 8.0.0.1.

  • export_iso_image (bool) – Whether to export ISO image. This attribute was added in vSphere API 8.0.0.1.

  • export_offline_bundle (bool) – Whether to export offline bundle. This attribute was added in vSphere API 8.0.0.1.

class ExportType(string)

Bases: Enum

The Software.ExportType class defines the formats in which software specification document or image can be exported. This enumeration was added in vSphere API 8.0.0.1.

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 ExportType instance.

ISO_IMAGE = ExportType(string='ISO_IMAGE')

Export ISO image. This class attribute was added in vSphere API 8.0.0.1.

OFFLINE_BUNDLE = ExportType(string='OFFLINE_BUNDLE')

Export offline bundle. This class attribute was added in vSphere API 8.0.0.1.

SOFTWARE_SPEC = ExportType(string='SOFTWARE_SPEC')

Export software specification document. This class attribute was added in vSphere API 8.0.0.1.

class StageResult(status=None, commit=None, host_info=None, notifications=None)

Bases: VapiStruct

The Software.StageResult class contains attributes that describe the result of a Software.stage() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.StageStatus or None) – Specifies the status of the Software.stage() method on the specified Software.StageResult.commit of the desired software document. This attribute was added in vSphere API 8.0.0.1. None if the Software.stage() method is in progress.

  • commit (str) – The identifier of the commit used to fetch the desired software document to be staged to a host. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit.

  • host_info (com.vmware.esx.settings_client.HostInfo) – Information of the host to which the desired software document specified by the Software.StageResult.commit was staged. This attribute was added in vSphere API 8.0.0.1.

  • notifications (com.vmware.esx.settings_client.Notifications or None) – Notifications providing additional information for Software.stage() method. These notifications are mutually exclusive with the notifications in Software.StageStatus. This attribute was added in vSphere API 8.0.0.1.

class StageSpec(commit=None)

Bases: VapiStruct

The Software.StageSpec class contains attributes that describe the specification to be used for staging the desired software document to a host. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:

commit (str or None) – The minimum commit identifier of the desired software document to be used during the Software.stage() method. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.esx.settings.commit. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.esx.settings.commit. if None or empty the stage method will use the latest commit to fetch the desired state document.

class StageStatus(status=None, progress=None, start_time=None, end_time=None, notifications=None)

Bases: VapiStruct

The Software.StageStatus class contains attributes that describe the status of a Software.stage() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters:
  • status (Software.StageStatus.Status) – The status of the method. This attribute was added in vSphere API 8.0.0.1.

  • progress (com.vmware.cis.task_client.Progress or None) – Progress of the operation. This attribute was added in vSphere API 8.0.0.1. None for host StageStatus

  • start_time (datetime.datetime) – Time when the method started. This attribute was added in vSphere API 8.0.0.1.

  • end_time (datetime.datetime) – Time when the method completed. This attribute was added in vSphere API 8.0.0.1.

  • notifications (com.vmware.esx.settings_client.Notifications) – Notifications providing additional information about the status of the method. This attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: Enum

The Software.StageStatus.Status class contains the possible different status codes that can be returned while trying to Software.stage() the desired software specification to a host. This enumeration was added in vSphere API 8.0.0.1.

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.

ERROR = Status(string='ERROR')

The method encountered an unspecified error. This class attribute was added in vSphere API 8.0.0.1.

OK = Status(string='OK')

The method completed successfully. This class attribute was added in vSphere API 8.0.0.1.

RETRY_PENDING = Status(string='RETRY_PENDING')

The method is being scheduled for retry. This class attribute was added in vSphere API 8.0.0.1.

RUNNING = Status(string='RUNNING')

The method is in progress. This class attribute was added in vSphere API 8.0.0.1.

SKIPPED = Status(string='SKIPPED')

The method was skipped. This class attribute was added in vSphere API 8.0.0.1.

TIMED_OUT = Status(string='TIMED_OUT')

The method timed out. This class attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: Enum

The Software.Status class defines the status result for a particular check. This enumeration was added in vSphere API 8.0.0.1.

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.

ERROR = Status(string='ERROR')

The check indicates an error. This class attribute was added in vSphere API 8.0.0.1.

OK = Status(string='OK')

The check indicates a success. This class attribute was added in vSphere API 8.0.0.1.

RETRY = Status(string='RETRY')

The check failed because of an intermittent error, for example a service is overloaded. The client can choose to retry the health check before considering the check as failed. This class attribute was added in vSphere API 8.0.0.1.

TIMEOUT = Status(string='TIMEOUT')

The check did not return in a timely manner. This class attribute was added in vSphere API 8.0.0.1.

WARNING = Status(string='WARNING')

The check indicates a warning. This class attribute was added in vSphere API 8.0.0.1.

apply_task(host, spec)

Applies the desired software document associated with the given host. If commit attribute is set, it implies the minimum commit that the Software.apply() method should use, however if subsequent commits have been made to the desired state document the apply method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation. This method was added in vSphere API 8.0.0.1.

Parameters:
  • host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

  • spec (Software.ApplySpec) – Apply specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.AlreadyInDesiredState If the host is already at specified commit as described in the apply specification.

Raise:

com.vmware.vapi.std.errors_client.Error If there is an unknown internal error or if the EULA has not been accepted. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no host associated with host in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

check_task(host, spec)

Runs checks on the host before applying the desired software document. Checks if host is in a good state to be updated with the desired software document. If commit attribute is set it implies the minimum commit that the check method should use, however if subsequent commits have been made to the desired state document the check method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation. This method was added in vSphere API 8.0.0.1.

Parameters:
  • host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

  • spec (Software.CheckSpec) – Check specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress or if the commit attribute of spec specifies a commit that has already been applied.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

export(host, spec)

Exports the desired software specification document and/or image. This API will not export the solution section of the desired software specification. This method was added in vSphere API 8.0.0.1.

Parameters:
  • host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

  • spec (Software.ExportSpec) –

Return type:

dict of Software.ExportType and str

Returns:

A map from export type to URL of the exported data for that type.

Raise:

com.vmware.vapi.std.errors_client.Error If there is am unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no host associated with host in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSoftwareSpecification.Read.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.lifecycleSoftwareSpecification.Read.

get(host)

Returns the complete desired software specification. This method was added in vSphere API 8.0.0.1.

Parameters:

host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

Return type:

com.vmware.esx.settings_client.SoftwareInfo

Returns:

Host software specification.

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

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 service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

Raise:

com.vmware.vapi.std.errors_client.Unauthorized if you do not have all of the privileges described as follows:

  • Method execution requires VcIntegrity.lifecycleSoftwareSpecification.Read.

  • The resource HostSystem referenced by the parameter host requires VcIntegrity.lifecycleSoftwareSpecification.Read.

scan_task(host)

Scans the host against the host’s desired state.. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation.

Parameters:

host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no host associated with host in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host.

stage_task(host, spec)

Stages the desired software document associated with the given host. If commit attribute is set, it implies the minimum commit that the Software.stage() method should use, however if subsequent commits have been made to the desired state document the stage method will use the most recent desired state document. The result of this operation can be queried by calling the cis/tasks/{task-id} where the task-id is the response of this operation. This method was added in vSphere API 8.0.0.1.

Parameters:
  • host (str) – Identifier of the host. The parameter must be an identifier for the resource type: HostSystem.

  • spec (Software.StageSpec) – stage specification.

Return type:

class:

vmware.vapi.stdlib.client.task.Task

Returns:

Task instance

Raise:

com.vmware.vapi.std.errors_client.Error If there is an unknown internal error. The accompanying error message will give more details about the failure.

Raise:

com.vmware.vapi.std.errors_client.InvalidArgument If the commit attribute of spec specifies an invalid commit, or the StageSpec#hosts attribute of spec specifies an invalid host or the host is not managed with a single software specification.

Raise:

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState If there is another operation in progress.

Raise:

com.vmware.vapi.std.errors_client.NotFound If there is no host associated with host in the system or if desired software document is not found.

Raise:

com.vmware.vapi.std.errors_client.ServiceUnavailable If the service is not available.

Raise:

com.vmware.vapi.std.errors_client.TimedOut If the operation times out.

Raise:

com.vmware.vapi.std.errors_client.Unauthenticated If the caller is not authenticated.

Raise:

com.vmware.vapi.std.errors_client.Unsupported If the host is not a vLCM managed standlone host

class com.vmware.esx.settings.hosts_client.StubFactory(stub_config)

Bases: StubFactoryBase

Initialize StubFactoryBase

Parameters:

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance