com.vmware package
Subpackages
- com.vmware.appliance package
- Subpackages
- com.vmware.appliance.networking package
- Submodules
- com.vmware.appliance.networking.dns_client module
- com.vmware.appliance.networking.firewall_client module
- com.vmware.appliance.networking.interfaces_client module
- com.vmware.appliance.recovery package
- Subpackages
- Submodules
- com.vmware.appliance.recovery.backup_client module
Job
LocationSpec
Parts
Schedules
StubFactory
SystemName
- com.vmware.appliance.recovery.reconciliation_client module
- com.vmware.appliance.recovery.restore_client module
- com.vmware.appliance.system package
- com.vmware.appliance.tls package
- com.vmware.appliance.vcenter package
- Subpackages
- com.vmware.appliance.vcenter.settings package
- Subpackages
- Submodules
- com.vmware.appliance.vcenter.settings.v1_client module
ApplyImpact
CheckResult
ComplianceResult
Config
Config.ApplyDesiredStateSpec
Config.ApplyResult
Config.ApplySpec
Config.ApplyStatus
Config.CheckDesiredStateSpec
Config.CheckSpec
Config.CreateSpec
Config.Info
Config.ScanSpec
Config.apply_desired_state_task()
Config.check_desired_state_task()
Config.create()
Config.delete()
Config.get()
Config.scan_desired_state_task()
Config.scan_task()
ConfigCurrent
DesiredState
DiffResult
Impact
Notification
Notifications
ScanResult
StatusType
StubFactory
TaskInfo
- com.vmware.appliance.vcenter.settings package
- Subpackages
- com.vmware.appliance.networking package
- Submodules
- com.vmware.appliance.access_client module
- com.vmware.appliance.health_client module
- com.vmware.appliance.infraprofile_client module
- com.vmware.appliance.local_accounts_client module
- com.vmware.appliance.localaccounts_client module
- com.vmware.appliance.logging_client module
- com.vmware.appliance.monitoring_client module
- com.vmware.appliance.networking_client module
- com.vmware.appliance.ntp_client module
- com.vmware.appliance.recovery_client module
- com.vmware.appliance.shutdown_client module
- com.vmware.appliance.support_bundle_client module
- com.vmware.appliance.supportbundle_client module
- com.vmware.appliance.system_client module
- com.vmware.appliance.tls_client module
- com.vmware.appliance.update_client module
CommonInfo
Pending
Policy
ServiceInfo
Staged
StubFactory
Summary
- com.vmware.appliance.vmon_client module
- Subpackages
- com.vmware.cis package
- Submodules
- com.vmware.cis.tagging_client module
Category
CategoryModel
StubFactory
Tag
TagAssociation
TagAssociation.BatchResult
TagAssociation.ObjectToTags
TagAssociation.TagToObjects
TagAssociation.attach()
TagAssociation.attach_multiple_tags_to_object()
TagAssociation.attach_tag_to_multiple_objects()
TagAssociation.detach()
TagAssociation.detach_multiple_tags_from_object()
TagAssociation.detach_tag_from_multiple_objects()
TagAssociation.list_attachable_tags()
TagAssociation.list_attached_objects()
TagAssociation.list_attached_objects_on_tags()
TagAssociation.list_attached_tags()
TagAssociation.list_attached_tags_on_objects()
TagModel
- com.vmware.cis.tagging_provider module
Category
CategoryModel
CategorySkeleton
Tag
TagAssociation
TagAssociation.BatchResult
TagAssociation.ObjectToTags
TagAssociation.TagToObjects
TagAssociation.attach()
TagAssociation.attach_multiple_tags_to_object()
TagAssociation.attach_tag_to_multiple_objects()
TagAssociation.detach()
TagAssociation.detach_multiple_tags_from_object()
TagAssociation.detach_tag_from_multiple_objects()
TagAssociation.list_attachable_tags()
TagAssociation.list_attached_objects()
TagAssociation.list_attached_objects_on_tags()
TagAssociation.list_attached_tags()
TagAssociation.list_attached_tags_on_objects()
TagAssociationSkeleton
TagModel
TagSkeleton
- com.vmware.cis.task_client module
- com.vmware.content package
- Subpackages
- com.vmware.content.library package
- Subpackages
- Submodules
- com.vmware.content.library.item_client module
- com.vmware.content.type package
- com.vmware.content.library package
- Submodules
- com.vmware.content.library_client module
Item
ItemModel
OptimizationInfo
PublishInfo
SourceInfo
StorageBacking
StubFactory
SubscribedItem
SubscriptionInfo
Subscriptions
Subscriptions.CreateSpec
Subscriptions.CreateSpecNewSubscribedLibrary
Subscriptions.CreateSpecPlacement
Subscriptions.CreateSpecSubscribedLibrary
Subscriptions.CreateSpecVcenter
Subscriptions.Info
Subscriptions.Location
Subscriptions.PlacementInfo
Subscriptions.RESOURCE_TYPE
Subscriptions.Summary
Subscriptions.UpdateSpec
Subscriptions.UpdateSpecPlacement
Subscriptions.UpdateSpecVcenter
Subscriptions.VcenterInfo
Subscriptions.create()
Subscriptions.delete()
Subscriptions.get()
Subscriptions.list()
Subscriptions.update()
- Subpackages
- com.vmware.esx package
- Subpackages
- com.vmware.esx.hcl package
- Submodules
- com.vmware.esx.hcl.hosts_client module
CompatibilityReleases
CompatibilityReport
CompatibilityReport.BiosConstraint
CompatibilityReport.DeviceConstraint
CompatibilityReport.DeviceHclInfo
CompatibilityReport.HclReport
CompatibilityReport.Result
CompatibilityReport.ServerCompatibility
CompatibilityReport.ServerHclInfo
CompatibilityReport.Spec
CompatibilityReport.create_task()
CompatibilityReport.get()
StubFactory
- com.vmware.esx.hosts package
- com.vmware.esx.settings package
- Subpackages
- com.vmware.esx.settings.clusters package
- Subpackages
- com.vmware.esx.settings.clusters.configuration package
- com.vmware.esx.settings.clusters.enablement package
- Submodules
- com.vmware.esx.settings.clusters.enablement.configuration_client module
StubFactory
Transition
Transition.EligibilityResult
Transition.EnableResult
Transition.FileSpec
Transition.Hints
Transition.Info
Transition.ReferenceHost
Transition.Source
Transition.State
Transition.ValidateResult
Transition.cancel()
Transition.check_eligibility_task()
Transition.enable_task()
Transition.export_config()
Transition.export_schema()
Transition.get()
Transition.import_from_file()
Transition.import_from_host_task()
Transition.precheck_task()
Transition.validate_config_task()
- com.vmware.esx.settings.clusters.policies package
- com.vmware.esx.settings.clusters.software package
- Subpackages
- Submodules
- com.vmware.esx.settings.clusters.software.drafts_client module
- com.vmware.esx.settings.clusters.software.reports_client module
ApplyImpact
CheckResult
ComplianceStatus
ComplianceStatusDetail
ComplianceStatusDetail.CERTIFIED
ComplianceStatusDetail.FIRMWARE_VERSION_UNKNOWN
ComplianceStatusDetail.HCL_DATA_UNAVAILABLE
ComplianceStatusDetail.HOSTS_UNAVAILABLE
ComplianceStatusDetail.MUTED
ComplianceStatusDetail.NOT_CERTIFIED
ComplianceStatusDetail.UNKNOWN
ComplianceStatusDetail.USER_FLAGGED
ComplianceStatusDetail.USER_VERIFIED
ComplianceStatusDetail.VENDOR_UPDATE
DriverFirmwareVersion
FirmwareVersionMatchingCriteria
HardwareCompatibility
LastApplyResult
LastCheckResult
PciDevice
PciDeviceCompliance
PciDeviceComplianceInfo
PciDeviceConstraint
Service
StorageDeviceCompatibility
StorageDeviceCompliance
StorageDeviceComplianceInfo
StorageDeviceConstraint
StorageDeviceInfo
StubFactory
- Submodules
- com.vmware.esx.settings.clusters.configuration_client module
AuditRecords
AuditRecords.FilterSpec
AuditRecords.Info
AuditRecords.OperationDetails
AuditRecords.OperationType
AuditRecords.OperationType.CHECK_COMPLIANCE
AuditRecords.OperationType.DRAFT_APPLY
AuditRecords.OperationType.DRAFT_CHECK_COMPLIANCE
AuditRecords.OperationType.DRAFT_CREATE
AuditRecords.OperationType.DRAFT_DELETE
AuditRecords.OperationType.DRAFT_EXPORT_CONFIG
AuditRecords.OperationType.DRAFT_GET
AuditRecords.OperationType.DRAFT_IMPORT_FROM_HOST
AuditRecords.OperationType.DRAFT_LIST
AuditRecords.OperationType.DRAFT_PRECHECK
AuditRecords.OperationType.DRAFT_SHOW_CHANGES
AuditRecords.OperationType.DRAFT_UPDATE
AuditRecords.OperationType.EXPORT
AuditRecords.OperationType.IMPORT
AuditRecords.OperationType.OPERATIONS
AuditRecords.OperationType.PRE_CHECK
AuditRecords.OperationType.REMEDIATE
AuditRecords.OperationType.TRANSITION_ENABLE
AuditRecords.TimePeriod
AuditRecords.list()
ClusterCompliance
ClusterPrecheckResult
ComplianceInfo
ComplianceStatus
ConfigurationSpec
DependencyError
DetailedValidationError
DetailedValidationError.ErrorType
DetailedValidationError.ErrorType.ADDITIONAL_PROPERTY
DetailedValidationError.ErrorType.DUPLICATE_INSTANCE_ID
DetailedValidationError.ErrorType.EMPTY_PROPERTY
DetailedValidationError.ErrorType.GENERIC
DetailedValidationError.ErrorType.HOST_SPECIFIC_IN_PROFILE
DetailedValidationError.ErrorType.HOST_SPECIFIC_KEY_IN_OVERRIDE
DetailedValidationError.ErrorType.INVALID_DELETE_DEFAULT
DetailedValidationError.ErrorType.INVALID_ENUM_OPTION
DetailedValidationError.ErrorType.INVALID_TYPE
DetailedValidationError.ErrorType.INVALID_UNION_TAG
DetailedValidationError.ErrorType.KEY_IN_HOST_OVERRIDE
DetailedValidationError.ErrorType.MAX_ARRAY_LENGTH
DetailedValidationError.ErrorType.MAX_STRING_LENGTH
DetailedValidationError.ErrorType.MAX_VALUE
DetailedValidationError.ErrorType.MIN_ARRAY_LENGTH
DetailedValidationError.ErrorType.MIN_STRING_LENGTH
DetailedValidationError.ErrorType.MIN_VALUE
DetailedValidationError.ErrorType.MISSING_INSTANCE_ID
DetailedValidationError.ErrorType.MISSING_REQUIRED
DetailedValidationError.ErrorType.MISSING_REQUIRED_PROFILE_INSTANCE
DetailedValidationError.ErrorType.MISSING_REQUIRED_PROFILE_KEY
DetailedValidationError.ErrorType.NOT_HOST_SPECIFIC
DetailedValidationError.ErrorType.NULL_VALUE
DetailedValidationError.ErrorType.PATTERN_MISMATCH
DetailedValidationError.ErrorType.PLACEHOLDER_FOUND
DetailedValidationError.ErrorType.PROPERTY_NAME_MISMATCH
DetailedValidationError.ErrorType.SCHEMA_NOT_FOUND
DetailedValidationError.ErrorType.UNION_CASE_WITHOUT_UNION_TAG
DocumentStructure
DraftImportResult
Drafts
Drafts.ApplyResult
Drafts.ApplySpec
Drafts.ChangeDetails
Drafts.ChangedProperty
Drafts.ChangesResult
Drafts.ConflictDetails
Drafts.ConflictPropertyInfo
Drafts.CreateSpec
Drafts.DeletionInfo
Drafts.Info
Drafts.Metadata
Drafts.ModificationInfo
Drafts.RESOURCE_TYPE
Drafts.State
Drafts.UpdateSpec
Drafts.ValidationDetails
Drafts.ValidationErrors
Drafts.apply()
Drafts.check_compliance_task()
Drafts.create()
Drafts.delete()
Drafts.export_config()
Drafts.get()
Drafts.get_schema()
Drafts.import_from_host_task()
Drafts.list()
Drafts.precheck_task()
Drafts.show_changes()
Drafts.update()
ExportResult
HostCompliance
HostPrecheckResult
HostResult
HostStatus
ImpactInfo
ImpactType
ImportResult
ReferenceHostInfo
Schema
SchemaResult
SettingCompliance
StubFactory
ValidationError
ValidationResult
- com.vmware.esx.settings.clusters.enablement_client module
- com.vmware.esx.settings.clusters.policies_client module
- com.vmware.esx.settings.clusters.software_client module
AddOn
BaseImage
Commits
Compliance
Components
Drafts
Drafts.CommitSpec
Drafts.FilterSpec
Drafts.ImportSpec
Drafts.Info
Drafts.Metadata
Drafts.RESOURCE_TYPE
Drafts.SourceType
Drafts.StatusType
Drafts.Summary
Drafts.ValidateResult
Drafts.commit_task()
Drafts.create()
Drafts.delete()
Drafts.get()
Drafts.import_software_spec()
Drafts.list()
Drafts.scan_task()
Drafts.validate_task()
EffectiveComponents
HardwareSupport
Recommendations
RemovedComponents
Solutions
StubFactory
- Subpackages
- com.vmware.esx.settings.defaults package
- Subpackages
- Submodules
- com.vmware.esx.settings.defaults.clusters_client module
- com.vmware.esx.settings.defaults.hosts_client module
- com.vmware.esx.settings.depot_content package
- com.vmware.esx.settings.depots package
- com.vmware.esx.settings.hardware_support package
- com.vmware.esx.settings.hosts package
- Subpackages
- Submodules
- com.vmware.esx.settings.hosts.enablement_client module
- com.vmware.esx.settings.hosts.policies_client module
- com.vmware.esx.settings.hosts.software_client module
AddOn
BaseImage
Commits
Compliance
Components
Drafts
Drafts.CommitSpec
Drafts.FilterSpec
Drafts.ImportSpec
Drafts.Info
Drafts.Metadata
Drafts.RESOURCE_TYPE
Drafts.SourceType
Drafts.StatusType
Drafts.Summary
Drafts.ValidateResult
Drafts.commit_task()
Drafts.create()
Drafts.delete()
Drafts.get()
Drafts.import_software_spec()
Drafts.list()
Drafts.scan_task()
Drafts.validate_task()
EffectiveComponents
Recommendations
RemovedComponents
Solutions
StubFactory
- com.vmware.esx.settings.clusters package
- Submodules
- com.vmware.esx.settings.clusters_client module
Configuration
Configuration.ApplyResult
Configuration.ApplySpec
Configuration.ImportSpec
Configuration.Info
Configuration.Metadata
Configuration.apply_task()
Configuration.check_compliance_task()
Configuration.export_config()
Configuration.get()
Configuration.import_config_task()
Configuration.precheck_task()
Configuration.validate_task()
DepotOverrides
InstalledImages
Software
Software.ApplyResult
Software.ApplySpec
Software.ApplyStatus
Software.CheckInfo
Software.CheckIssue
Software.CheckResult
Software.CheckSpec
Software.CheckStatus
Software.EntityCheckResult
Software.ExportSpec
Software.ExportType
Software.StageResult
Software.StageSpec
Software.StageStatus
Software.Status
Software.apply_task()
Software.check_task()
Software.export()
Software.get()
Software.scan_task()
Software.stage_task()
StubFactory
- com.vmware.esx.settings.defaults_client module
- com.vmware.esx.settings.depot_content_client module
- com.vmware.esx.settings.depots_client module
AddonSummary
AddonVersion
AffectedBaselineInfo
AffectedDesiredStateInfo
BaseImageVersion
ComponentSummary
ComponentVersion
HardwareSupportManagerSummary
HardwareSupportPackageSummary
HardwareSupportPackageVersion
MetadataInfo
Offline
Offline.ConnectionSpec
Offline.CreateResult
Offline.CreateSpec
Offline.DeleteResult
Offline.DepotExtractInfo
Offline.HostCredentials
Offline.Info
Offline.PrecheckResult
Offline.RESOURCE_TYPE
Offline.SourceType
Offline.Summary
Offline.create_from_host_task()
Offline.create_task()
Offline.delete()
Offline.delete_task()
Offline.get()
Offline.list()
Online
SolutionSummary
SolutionVersion
StubFactory
SyncSchedule
Umds
UpdateSummary
- com.vmware.esx.settings.hardware_support_client module
- com.vmware.esx.settings.hosts_client module
Configuration
DepotOverrides
Software
Software.ApplyResult
Software.ApplySpec
Software.ApplyStatus
Software.CheckInfo
Software.CheckIssue
Software.CheckResult
Software.CheckSpec
Software.CheckStatus
Software.EntityCheckResult
Software.ExportSpec
Software.ExportType
Software.StageResult
Software.StageSpec
Software.StageStatus
Software.Status
Software.apply_task()
Software.check_task()
Software.export()
Software.get()
Software.scan_task()
Software.stage_task()
StubFactory
- Subpackages
- com.vmware.esx.hcl package
- Submodules
- com.vmware.esx.hcl_client module
- com.vmware.esx.hostd_client module
- com.vmware.esx.hosts_client module
- com.vmware.esx.settings_client module
AddOnCompliance
AddOnDetails
AddOnInfo
AddOnSpec
BaseImageCompliance
BaseImageDetails
BaseImageInfo
BaseImageSpec
CheckDescription
CheckError
CheckStatus
ClusterCompliance
ComplianceImpact
ComplianceStatus
ComponentCompliance
ComponentDetails
ComponentInfo
ComponentOverrideInfo
ComponentSource
DataProcessingUnitCompliance
DataProcessingUnitInfo
DataProcessingUnitsCompliance
Depots
EffectiveComponentDetails
EffectiveComponentInfo
HardwareModuleClass
HardwareModuleDetails
HardwareModuleFirmwareCompliance
HardwareModuleFirmwareInfo
HardwareSupportInfo
HardwareSupportPackageCompliance
HardwareSupportPackageInfo
HardwareSupportPackageSpec
HardwareSupportSpec
HostCompliance
HostInfo
ImageCustomizationAction
ImpactDetails
MemoryReservation
Notification
Notifications
RemediationAction
RemediationDetails
SoftwareInfo
SoftwareSpec
SolutionCompliance
SolutionComponentDetails
SolutionComponentSpec
SolutionDetails
SolutionInfo
SolutionSpec
StageStatus
Status
StatusInfo
StubFactory
TaskInfo
- Subpackages
- com.vmware.oauth2 package
- com.vmware.snapservice package
- Subpackages
- com.vmware.snapservice.clusters package
- Subpackages
- Submodules
- com.vmware.snapservice.clusters.protection_groups_client module
- com.vmware.snapservice.clusters.virtual_machines_client module
- com.vmware.snapservice.clusters package
- Submodules
- com.vmware.snapservice.clusters_client module
ProtectionGroups
ProtectionGroups.DeleteSpec
ProtectionGroups.FilterSpec
ProtectionGroups.ListItem
ProtectionGroups.ListResult
ProtectionGroups.create_task()
ProtectionGroups.delete_task()
ProtectionGroups.get()
ProtectionGroups.list()
ProtectionGroups.pause_task()
ProtectionGroups.resume_task()
ProtectionGroups.update_task()
StubFactory
VirtualMachines
VirtualMachines.FilterSpec
VirtualMachines.Info
VirtualMachines.LinkedClonePlacementSpec
VirtualMachines.LinkedCloneSpec
VirtualMachines.ListItem
VirtualMachines.ListResult
VirtualMachines.RestorePlacementSpec
VirtualMachines.RestoreSpec
VirtualMachines.RevertSpec
VirtualMachines.get()
VirtualMachines.linked_clone_task()
VirtualMachines.list()
VirtualMachines.restore_task()
VirtualMachines.revert_task()
- com.vmware.snapservice.info_client module
- com.vmware.snapservice.tasks_client module
- Subpackages
- com.vmware.vapi package
- Subpackages
- com.vmware.vapi.metadata package
- Subpackages
- Submodules
- com.vmware.vapi.metadata.authentication_client module
- com.vmware.vapi.metadata.cli_client module
- com.vmware.vapi.metadata.metamodel_client module
Component
ComponentData
ComponentInfo
ConstantInfo
ConstantValue
ElementMap
ElementValue
Enumeration
EnumerationInfo
EnumerationValueInfo
ErrorInfo
FieldInfo
GenericInstantiation
MetadataIdentifier
MetadataIdentifier.CANONICAL_NAME
MetadataIdentifier.COMPONENT
MetadataIdentifier.CREATE
MetadataIdentifier.CRUD
MetadataIdentifier.HAS_FIELDS_OF
MetadataIdentifier.INCLUDABLE
MetadataIdentifier.INCLUDE
MetadataIdentifier.IS_ONE_OF
MetadataIdentifier.MODEL
MetadataIdentifier.READ
MetadataIdentifier.RESOURCE
MetadataIdentifier.UNION_CASE
MetadataIdentifier.UNION_TAG
MetadataIdentifier.UPDATE
OperationInfo
OperationResultInfo
Package
PackageInfo
PrimitiveValue
Resource
Service
ServiceInfo
Structure
StructureInfo
StubFactory
Type
Type.BuiltinType
Type.BuiltinType.ANY_ERROR
Type.BuiltinType.BINARY
Type.BuiltinType.BOOLEAN
Type.BuiltinType.DATE_TIME
Type.BuiltinType.DOUBLE
Type.BuiltinType.DYNAMIC_STRUCTURE
Type.BuiltinType.ID
Type.BuiltinType.LONG
Type.BuiltinType.OPAQUE
Type.BuiltinType.SECRET
Type.BuiltinType.STRING
Type.BuiltinType.URI
Type.BuiltinType.VOID
Type.Category
UserDefinedType
- com.vmware.vapi.metadata.privilege_client module
- com.vmware.vapi.std package
- Submodules
- com.vmware.vapi.std.errors_client module
AlreadyExists
AlreadyInDesiredState
ArgumentLocations
Canceled
ConcurrentChange
Error
Error.Type
Error.Type.ALREADY_EXISTS
Error.Type.ALREADY_IN_DESIRED_STATE
Error.Type.CANCELED
Error.Type.CONCURRENT_CHANGE
Error.Type.ERROR
Error.Type.FEATURE_IN_USE
Error.Type.INTERNAL_SERVER_ERROR
Error.Type.INVALID_ARGUMENT
Error.Type.INVALID_ELEMENT_CONFIGURATION
Error.Type.INVALID_ELEMENT_TYPE
Error.Type.INVALID_REQUEST
Error.Type.NOT_ALLOWED_IN_CURRENT_STATE
Error.Type.NOT_FOUND
Error.Type.OPERATION_NOT_FOUND
Error.Type.RESOURCE_BUSY
Error.Type.RESOURCE_INACCESSIBLE
Error.Type.RESOURCE_IN_USE
Error.Type.SERVICE_UNAVAILABLE
Error.Type.TIMED_OUT
Error.Type.UNABLE_TO_ALLOCATE_RESOURCE
Error.Type.UNAUTHENTICATED
Error.Type.UNAUTHORIZED
Error.Type.UNEXPECTED_INPUT
Error.Type.UNSUPPORTED
Error.Type.UNVERIFIED_PEER
FeatureInUse
FileLocations
InternalServerError
InvalidArgument
InvalidElementConfiguration
InvalidElementType
InvalidRequest
NotAllowedInCurrentState
NotFound
OperationNotFound
ResourceBusy
ResourceInUse
ResourceInaccessible
ServiceUnavailable
StubFactory
TimedOut
TransientIndication
UnableToAllocateResource
Unauthenticated
Unauthorized
UnexpectedInput
Unsupported
UnverifiedPeer
- com.vmware.vapi.metadata package
- Submodules
- com.vmware.vapi.metadata_client module
- com.vmware.vapi.std_client module
AuthenticationScheme
DynamicID
LocalizableMessage
LocalizationParam
LocalizationParam.DateTimeFormat
LocalizationParam.DateTimeFormat.FULL_DATE
LocalizationParam.DateTimeFormat.FULL_DATE_TIME
LocalizationParam.DateTimeFormat.FULL_TIME
LocalizationParam.DateTimeFormat.LONG_DATE
LocalizationParam.DateTimeFormat.LONG_DATE_TIME
LocalizationParam.DateTimeFormat.LONG_TIME
LocalizationParam.DateTimeFormat.MED_DATE
LocalizationParam.DateTimeFormat.MED_DATE_TIME
LocalizationParam.DateTimeFormat.MED_TIME
LocalizationParam.DateTimeFormat.SHORT_DATE
LocalizationParam.DateTimeFormat.SHORT_DATE_TIME
LocalizationParam.DateTimeFormat.SHORT_TIME
NestedLocalizableMessage
StubFactory
- Subpackages
- com.vmware.vcenter package
- Subpackages
- com.vmware.vcenter.authorization package
- com.vmware.vcenter.certificate_management package
- com.vmware.vcenter.compute package
- Subpackages
- com.vmware.vcenter.compute.policies package
- Subpackages
- com.vmware.vcenter.compute.policies.capabilities package
- Subpackages
- Submodules
- com.vmware.vcenter.compute.policies.capabilities.cluster_scale_in_ignore_vm_capabilities_client module
- com.vmware.vcenter.compute.policies.capabilities.disable_drs_vmotion_client module
- com.vmware.vcenter.compute.policies.capabilities.vm_host_affinity_client module
- com.vmware.vcenter.compute.policies.capabilities.vm_host_anti_affinity_client module
- com.vmware.vcenter.compute.policies.capabilities.vm_vm_affinity_client module
- com.vmware.vcenter.compute.policies.capabilities.vm_vm_anti_affinity_client module
- com.vmware.vcenter.compute.policies.capabilities package
- Submodules
- com.vmware.vcenter.compute.policies.capabilities_client module
- Subpackages
- com.vmware.vcenter.compute.policies package
- Submodules
- com.vmware.vcenter.compute.policies_client module
- Subpackages
- com.vmware.vcenter.confidential_computing package
- com.vmware.vcenter.consumption_domains package
- com.vmware.vcenter.content package
- Subpackages
- com.vmware.vcenter.content.registries package
- Submodules
- com.vmware.vcenter.content.registries_client module
- Subpackages
- com.vmware.vcenter.crypto_manager package
- Subpackages
- Submodules
- com.vmware.vcenter.crypto_manager.hosts_client module
- com.vmware.vcenter.crypto_manager.kms_client module
Providers
Providers.Constraints
Providers.ConstraintsSpec
Providers.CreateSpec
Providers.ExportResult
Providers.ExportSpec
Providers.ExportType
Providers.FilterSpec
Providers.Health
Providers.ImportResult
Providers.ImportSpec
Providers.Info
Providers.Location
Providers.NativeProviderCreateSpec
Providers.NativeProviderInfo
Providers.NativeProviderUpdateSpec
Providers.RESOURCE_TYPE
Providers.Summary
Providers.Token
Providers.Type
Providers.UpdateSpec
Providers.create()
Providers.delete()
Providers.export()
Providers.get()
Providers.import_provider()
Providers.list()
Providers.update()
StubFactory
- com.vmware.vcenter.deployment package
- com.vmware.vcenter.host package
- com.vmware.vcenter.hvc package
- com.vmware.vcenter.identity package
- com.vmware.vcenter.lcm package
- Submodules
- com.vmware.vcenter.lcm.discovery_client module
- com.vmware.vcenter.lcm.update_client module
- com.vmware.vcenter.namespace_management package
- Subpackages
- com.vmware.vcenter.namespace_management.networks package
- Subpackages
- Submodules
- com.vmware.vcenter.namespace_management.networks.edges_client module
- com.vmware.vcenter.namespace_management.networks.nsx_client module
- com.vmware.vcenter.namespace_management.networks.service_client module
- com.vmware.vcenter.namespace_management.software package
- com.vmware.vcenter.namespace_management.supervisors package
- Subpackages
- com.vmware.vcenter.namespace_management.supervisors.networks package
- com.vmware.vcenter.namespace_management.supervisors.recovery package
- Submodules
- com.vmware.vcenter.namespace_management.supervisors.identity_client module
- com.vmware.vcenter.namespace_management.supervisors.networks_client module
- com.vmware.vcenter.namespace_management.supervisors.recovery_client module
- Subpackages
- com.vmware.vcenter.namespace_management.networks package
- Submodules
- com.vmware.vcenter.namespace_management.clusters_client module
- com.vmware.vcenter.namespace_management.cns_client module
- com.vmware.vcenter.namespace_management.networks_client module
- com.vmware.vcenter.namespace_management.software_client module
- com.vmware.vcenter.namespace_management.stats_client module
- com.vmware.vcenter.namespace_management.storage_client module
- com.vmware.vcenter.namespace_management.supervisor_services_client module
ClusterSupervisorServices
ClusterSupervisorServices.ConfigStatus
ClusterSupervisorServices.CreateSpec
ClusterSupervisorServices.Info
ClusterSupervisorServices.Message
ClusterSupervisorServices.SetSpec
ClusterSupervisorServices.Summary
ClusterSupervisorServices.create()
ClusterSupervisorServices.delete()
ClusterSupervisorServices.get()
ClusterSupervisorServices.list()
ClusterSupervisorServices.set()
StubFactory
Versions
- com.vmware.vcenter.namespace_management.supervisors_client module
CNSFileConfig
Conditions
ContainerImageRegistries
ContentLibrarySpec
ControlPlane
ImageRegistry
ImageSyncConfig
KubeAPIServerOptions
KubeAPIServerSecurity
SizingHint
StubFactory
Summary
SupervisorServices
Topology
Workloads
WorkloadsStorageConfig
- Subpackages
- com.vmware.vcenter.namespaces package
- com.vmware.vcenter.phm package
- com.vmware.vcenter.storage package
- com.vmware.vcenter.system_config package
- com.vmware.vcenter.trusted_infrastructure package
- Subpackages
- com.vmware.vcenter.trusted_infrastructure.hosts package
- Subpackages
- Submodules
- com.vmware.vcenter.trusted_infrastructure.hosts.hardware_client module
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters package
- Subpackages
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters.attestation package
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters.kms package
- Submodules
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters.attestation_client module
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters.kms_client module
Providers
Providers.CreateSpec
Providers.Health
Providers.Info
Providers.KeyServerCreateSpec
Providers.KeyServerInfo
Providers.KeyServerUpdateSpec
Providers.KmipServerCreateSpec
Providers.KmipServerInfo
Providers.KmipServerUpdateSpec
Providers.RESOURCE_TYPE
Providers.Server
Providers.ServerInfo
Providers.Status
Providers.Summary
Providers.UpdateSpec
Providers.create_task()
Providers.delete_task()
Providers.get_task()
Providers.list_task()
Providers.update_task()
ServiceStatus
StubFactory
- Subpackages
- com.vmware.vcenter.trusted_infrastructure.trusted_clusters package
- Submodules
- com.vmware.vcenter.trusted_infrastructure.trusted_clusters.attestation_client module
Services
ServicesAppliedConfig
StubFactory
- com.vmware.vcenter.trusted_infrastructure.trusted_clusters.kms_client module
Services
ServicesAppliedConfig
StubFactory
- com.vmware.vcenter.trusted_infrastructure.hosts package
- Submodules
- com.vmware.vcenter.trusted_infrastructure.attestation_client module
- com.vmware.vcenter.trusted_infrastructure.hosts_client module
- com.vmware.vcenter.trusted_infrastructure.kms_client module
- com.vmware.vcenter.trusted_infrastructure.trust_authority_clusters_client module
- com.vmware.vcenter.trusted_infrastructure.trust_authority_hosts_client module
- com.vmware.vcenter.trusted_infrastructure.trusted_clusters_client module
- Subpackages
- com.vmware.vcenter.vcha package
- com.vmware.vcenter.vm package
- Subpackages
- com.vmware.vcenter.vm.guest package
- Submodules
- com.vmware.vcenter.vm.guest.filesystem_client module
Directories
ErrorReason
FileErrorDetails
Files
Files.FileAttributesInfo
Files.FileAttributesUpdateSpec
Files.FilesystemFamily
Files.FilterSpec
Files.Info
Files.IterationSpec
Files.LastIterationStatus
Files.ListResult
Files.PosixFileAttributesInfo
Files.PosixFileAttributesUpdateSpec
Files.Summary
Files.Type
Files.WindowsFileAttributesInfo
Files.WindowsFileAttributesUpdateSpec
Files.create_temporary()
Files.delete()
Files.get()
Files.list()
Files.move()
Files.update()
StubFactory
Transfers
- com.vmware.vcenter.vm.guest.networking_client module
- com.vmware.vcenter.vm.hardware package
- com.vmware.vcenter.vm.storage package
- com.vmware.vcenter.vm.guest package
- Submodules
- com.vmware.vcenter.vm.compute_client module
- com.vmware.vcenter.vm.console_client module
- com.vmware.vcenter.vm.data_sets_client module
- com.vmware.vcenter.vm.guest_client module
- com.vmware.vcenter.vm.hardware_client module
Boot
Cdrom
ConnectionCreateSpec
ConnectionInfo
ConnectionState
ConnectionUpdateSpec
Cpu
Disk
Ethernet
Ethernet.BackingInfo
Ethernet.BackingSpec
Ethernet.BackingType
Ethernet.CreateSpec
Ethernet.EmulationType
Ethernet.Info
Ethernet.MacAddressType
Ethernet.RESOURCE_TYPE
Ethernet.Summary
Ethernet.UpdateSpec
Ethernet.connect()
Ethernet.create()
Ethernet.delete()
Ethernet.disconnect()
Ethernet.get()
Ethernet.list()
Ethernet.update()
Floppy
IdeAddressInfo
IdeAddressSpec
Memory
NvmeAddressInfo
NvmeAddressSpec
Parallel
SataAddressInfo
SataAddressSpec
ScsiAddressInfo
ScsiAddressSpec
Serial
StubFactory
- com.vmware.vcenter.vm.storage_client module
- com.vmware.vcenter.vm.tools_client module
- Subpackages
- com.vmware.vcenter.vm_template package
- Submodules
- com.vmware.vcenter.authentication_client module
- com.vmware.vcenter.authorization_client module
- com.vmware.vcenter.certificate_management_client module
- com.vmware.vcenter.compute_client module
- com.vmware.vcenter.consumption_domains_client module
- com.vmware.vcenter.crypto_manager_client module
- com.vmware.vcenter.datastore_client module
- com.vmware.vcenter.deployment_client module
ApplianceSize
ApplianceState
ApplianceType
CheckInfo
CheckStatus
DataMigrationEstimate
DataMigrationInfo
HistoryMigrationOption
HistoryMigrationSpec
ImportHistory
Install
LocationSpec
Migrate
Notification
Notifications
Operation
Question
RemotePscSpec
ReplicatedPscSpec
ReplicatedSpec
SourceInfo
StandalonePscSpec
StandaloneSpec
StubFactory
Upgrade
VerificationMode
- com.vmware.vcenter.environment_browser_client module
- com.vmware.vcenter.guest_client module
AdapterMapping
CloudConfiguration
CloudinitConfiguration
ConfigurationSpec
CustomizationSpec
CustomizationSpecs
CustomizationSpecs.CreateSpec
CustomizationSpecs.FilterSpec
CustomizationSpecs.Format
CustomizationSpecs.Info
CustomizationSpecs.Metadata
CustomizationSpecs.OsType
CustomizationSpecs.RESOURCE_TYPE
CustomizationSpecs.Spec
CustomizationSpecs.Summary
CustomizationSpecs.create()
CustomizationSpecs.delete()
CustomizationSpecs.export()
CustomizationSpecs.get()
CustomizationSpecs.import_specification()
CustomizationSpecs.list()
CustomizationSpecs.set()
Domain
GlobalDNSSettings
GuiUnattended
HostnameGenerator
IPSettings
Ipv4
Ipv6
Ipv6Address
LinuxConfiguration
StubFactory
UserData
WindowsConfiguration
WindowsNetworkAdapterSettings
WindowsSysprep
- com.vmware.vcenter.host_client module
- com.vmware.vcenter.hvc_client module
- com.vmware.vcenter.identity_client module
FederationType
Providers
Providers.ActiveDirectoryOverLdap
Providers.ConfigType
Providers.CreateSpec
Providers.IdmProtocol
Providers.Info
Providers.Oauth2AuthenticationMethod
Providers.Oauth2CreateSpec
Providers.Oauth2Info
Providers.Oauth2Summary
Providers.Oauth2UpdateSpec
Providers.OidcCreateSpec
Providers.OidcInfo
Providers.OidcSummary
Providers.OidcUpdateSpec
Providers.Summary
Providers.UpdateSpec
Providers.create()
Providers.delete()
Providers.get()
Providers.list()
Providers.update()
StubFactory
- com.vmware.vcenter.inventory_client module
- com.vmware.vcenter.iso_client module
- com.vmware.vcenter.lcm_client module
- com.vmware.vcenter.namespace_management_client module
CNSFileConfig
ClusterAvailableVersions
ClusterCompatibility
ClusterSizeInfo
Clusters
Clusters.Condition
Clusters.ConfigStatus
Clusters.ContentLibrarySpec
Clusters.EnableSpec
Clusters.ImageRegistry
Clusters.ImageStorageSpec
Clusters.Info
Clusters.Ipv4Range
Clusters.KubernetesStatus
Clusters.Message
Clusters.NCPClusterNetworkEnableSpec
Clusters.NCPClusterNetworkInfo
Clusters.NCPClusterNetworkSetSpec
Clusters.NCPClusterNetworkUpdateSpec
Clusters.NetworkProvider
Clusters.NetworkSpec
Clusters.SetSpec
Clusters.Stats
Clusters.Summary
Clusters.UpdateSpec
Clusters.WorkloadNetworksEnableSpec
Clusters.WorkloadNetworksInfo
Clusters.disable()
Clusters.enable()
Clusters.get()
Clusters.list()
Clusters.rotate_password()
Clusters.set()
Clusters.update()
DistributedSwitchCompatibility
EdgeClusterCompatibility
HostsConfig
IPRange
Ipv4Cidr
LoadBalancers
LoadBalancers.AviConfigCreateSpec
LoadBalancers.AviConfigSetSpec
LoadBalancers.AviConfigUpdateSpec
LoadBalancers.AviInfo
LoadBalancers.ConfigSpec
LoadBalancers.HAProxyConfigCreateSpec
LoadBalancers.HAProxyConfigSetSpec
LoadBalancers.HAProxyConfigUpdateSpec
LoadBalancers.HAProxyInfo
LoadBalancers.Info
LoadBalancers.Provider
LoadBalancers.Server
LoadBalancers.SetSpec
LoadBalancers.Summary
LoadBalancers.UpdateSpec
LoadBalancers.get()
LoadBalancers.list()
LoadBalancers.set()
LoadBalancers.update()
NSXTier0Gateway
NamespaceResourceOptions
Networks
Networks.CreateSpec
Networks.IPAssignmentMode
Networks.Info
Networks.LoadBalancerSize
Networks.NsxNetworkCreateSpec
Networks.NsxNetworkInfo
Networks.NsxNetworkSetSpec
Networks.NsxNetworkUpdateSpec
Networks.RESOURCE_TYPE
Networks.SetSpec
Networks.UpdateSpec
Networks.VsphereDVPGNetworkCreateSpec
Networks.VsphereDVPGNetworkInfo
Networks.VsphereDVPGNetworkSetSpec
Networks.VsphereDVPGNetworkUpdateSpec
Networks.create()
Networks.delete()
Networks.get()
Networks.list()
Networks.set()
Networks.update()
ProxyConfiguration
ProxySettingsSource
SizingHint
StubFactory
SupervisorServices
SupervisorServices.CarvelAppsCheckResult
SupervisorServices.CarvelCreateSpec
SupervisorServices.CheckResult
SupervisorServices.ContentCheckSpec
SupervisorServices.CreateSpec
SupervisorServices.CustomCreateSpec
SupervisorServices.Info
SupervisorServices.State
SupervisorServices.Summary
SupervisorServices.UpdateSpec
SupervisorServices.ValidationStatus
SupervisorServices.VsphereAppsCheckResult
SupervisorServices.VsphereCreateSpec
SupervisorServices.activate()
SupervisorServices.check_content()
SupervisorServices.create()
SupervisorServices.deactivate()
SupervisorServices.delete()
SupervisorServices.get()
SupervisorServices.list()
SupervisorServices.update()
Supervisors
SupportBundle
VirtualMachineClasses
VirtualMachineClasses.ConfigStatus
VirtualMachineClasses.CreateSpec
VirtualMachineClasses.DynamicDirectPathIODevice
VirtualMachineClasses.Info
VirtualMachineClasses.InstanceStorage
VirtualMachineClasses.InstanceStorageVolume
VirtualMachineClasses.Message
VirtualMachineClasses.RESOURCE_TYPE
VirtualMachineClasses.UpdateSpec
VirtualMachineClasses.VGPUDevice
VirtualMachineClasses.VirtualDevices
VirtualMachineClasses.create()
VirtualMachineClasses.delete()
VirtualMachineClasses.get()
VirtualMachineClasses.list()
VirtualMachineClasses.update()
WorkloadsStorageConfig
- com.vmware.vcenter.namespaces_client module
Access
Instances
Instances.Access
Instances.ConfigStatus
Instances.ContentLibrarySpec
Instances.CreateSpec
Instances.CreateSpecV2
Instances.Info
Instances.InfoV2
Instances.Ipv4Cidr
Instances.LoadBalancerSize
Instances.Message
Instances.NetworkCreateSpec
Instances.NetworkProvider
Instances.NsxNetworkCreateSpec
Instances.Principal
Instances.RESOURCE_TYPE
Instances.RegisterVMSpec
Instances.SetSpec
Instances.Stats
Instances.StorageSpec
Instances.Summary
Instances.SummaryV2
Instances.UpdateSpec
Instances.VMServiceSpec
Instances.create()
Instances.create_v2()
Instances.delete()
Instances.get()
Instances.get_v2()
Instances.list()
Instances.list_v2()
Instances.register_vm()
Instances.set()
Instances.update()
NamespaceSelfService
NamespaceSelfService.ActivateTemplateSpec
NamespaceSelfService.Capability
NamespaceSelfService.Info
NamespaceSelfService.Status
NamespaceSelfService.Summary
NamespaceSelfService.activate()
NamespaceSelfService.activate_with_template()
NamespaceSelfService.deactivate()
NamespaceSelfService.get()
NamespaceSelfService.list()
NamespaceTemplates
NamespaceTemplates.CreateSpec
NamespaceTemplates.Info
NamespaceTemplates.InfoV2
NamespaceTemplates.RESOURCE_TYPE
NamespaceTemplates.Subject
NamespaceTemplates.Summary
NamespaceTemplates.SummaryV2
NamespaceTemplates.UpdateSpec
NamespaceTemplates.create()
NamespaceTemplates.create_v2()
NamespaceTemplates.get()
NamespaceTemplates.get_v2()
NamespaceTemplates.list()
NamespaceTemplates.list_v2()
NamespaceTemplates.update()
NamespaceTemplates.update_v2()
ResourceQuotaOptionsV1
ResourceQuotaOptionsV1Update
StubFactory
- com.vmware.vcenter.ovf_client module
CertificateParams
DeploymentOption
DeploymentOptionParams
DiskProvisioningType
ExportFlag
ExtraConfig
ExtraConfigParams
ImportFlag
IpAllocationParams
LibraryItem
LibraryItem.CreateResult
LibraryItem.CreateSpec
LibraryItem.CreateTarget
LibraryItem.DEPLOYABLE
LibraryItem.DeployableIdentity
LibraryItem.DeploymentResult
LibraryItem.DeploymentTarget
LibraryItem.OvfSummary
LibraryItem.ResourcePoolDeploymentSpec
LibraryItem.ResultInfo
LibraryItem.StorageGroupMapping
LibraryItem.VmConfigSpec
LibraryItem.VmConfigSpecProvider
LibraryItem.create()
LibraryItem.deploy()
LibraryItem.filter()
OvfError
OvfInfo
OvfMessage
OvfParams
OvfWarning
ParseIssue
ParseIssue.Category
ParseIssue.Category.ATTRIBUTE_ILLEGAL
ParseIssue.Category.ATTRIBUTE_REQUIRED
ParseIssue.Category.ELEMENT_ILLEGAL
ParseIssue.Category.ELEMENT_REQUIRED
ParseIssue.Category.ELEMENT_UNKNOWN
ParseIssue.Category.EXPORT_ERROR
ParseIssue.Category.GENERATE_ERROR
ParseIssue.Category.INTERNAL_ERROR
ParseIssue.Category.PARSE_ERROR
ParseIssue.Category.SECTION_RESTRICTION
ParseIssue.Category.SECTION_UNKNOWN
ParseIssue.Category.VALIDATION_ERROR
ParseIssue.Category.VALUE_ILLEGAL
Property
PropertyParams
ScaleOutGroup
ScaleOutParams
SizeParams
StubFactory
UnknownSection
UnknownSectionParams
VcenterExtensionParams
WarningInfo
WarningType
- com.vmware.vcenter.phm_client module
About
HardwareSupportManagers
HardwareSupportManagers.CreateSpec
HardwareSupportManagers.HealthUpdateInfo
HardwareSupportManagers.HealthUpdateInfoComponentCategory
HardwareSupportManagers.HealthUpdateInfoComponentCategory.BOOT
HardwareSupportManagers.HealthUpdateInfoComponentCategory.COMPUTE
HardwareSupportManagers.HealthUpdateInfoComponentCategory.MEMORY
HardwareSupportManagers.HealthUpdateInfoComponentCategory.MISCELLANEOUS
HardwareSupportManagers.HealthUpdateInfoComponentCategory.NETWORK
HardwareSupportManagers.HealthUpdateInfoComponentCategory.STORAGE
HardwareSupportManagers.HealthUpdateInfoConfig
HardwareSupportManagers.HealthUpdateInfoPurpose
HardwareSupportManagers.HealthUpdateInfoPurpose.FAILURE
HardwareSupportManagers.HealthUpdateInfoPurpose.HEALTH_STATISTIC
HardwareSupportManagers.HealthUpdateInfoPurpose.MISCELLANEOUS
HardwareSupportManagers.HealthUpdateInfoPurpose.PREDICTIVE_FAILURE
HardwareSupportManagers.HealthUpdateInfoPurpose.SECURITY_INFORMATION
HardwareSupportManagers.HealthUpdateInfoPurpose.SOFTWARE_INCOMPATIBILITY
HardwareSupportManagers.HealthUpdateInfoSeverity
HardwareSupportManagers.Info
HardwareSupportManagers.ListResult
HardwareSupportManagers.SetSpec
HardwareSupportManagers.create()
HardwareSupportManagers.delete()
HardwareSupportManagers.get()
HardwareSupportManagers.list()
HardwareSupportManagers.set()
StubFactory
- com.vmware.vcenter.services_client module
- com.vmware.vcenter.storage_client module
- com.vmware.vcenter.system_config_client module
- com.vmware.vcenter.tagging_client module
- com.vmware.vcenter.tokenservice_client module
Error
InvalidGrant
InvalidRequest
InvalidScope
StubFactory
TokenExchange
TokenExchange.ACCESS_TOKEN_TYPE
TokenExchange.BEARER_TOKEN_METHOD_TYPE
TokenExchange.ExchangeSpec
TokenExchange.ID_TOKEN_TYPE
TokenExchange.Info
TokenExchange.N_A_TOKEN_METHOD_TYPE
TokenExchange.REFRESH_TOKEN_TYPE
TokenExchange.SAML1_TOKEN_TYPE
TokenExchange.SAML2_TOKEN_TYPE
TokenExchange.TOKEN_EXCHANGE_GRANT
TokenExchange.exchange()
- com.vmware.vcenter.topology_client module
- com.vmware.vcenter.trusted_infrastructure_client module
NetworkAddress
Principal
StsPrincipal
StsPrincipalId
StsPrincipalType
StubFactory
TrustAuthorityClusters
X509CertChain
- com.vmware.vcenter.vcha_client module
CertificateInfo
Cluster
Cluster.ActiveSpec
Cluster.ClusterMode
Cluster.ClusterState
Cluster.ConfigState
Cluster.DeploySpec
Cluster.ErrorCondition
Cluster.Info
Cluster.IpFamily
Cluster.IpInfo
Cluster.Ipv4Info
Cluster.Ipv6Info
Cluster.NodeInfo
Cluster.NodeRole
Cluster.NodeRuntimeInfo
Cluster.NodeState
Cluster.NodeVmInfo
Cluster.PassiveSpec
Cluster.Type
Cluster.UndeploySpec
Cluster.VmInfo
Cluster.WitnessInfo
Cluster.WitnessSpec
Cluster.deploy_task()
Cluster.failover_task()
Cluster.get()
Cluster.undeploy_task()
ConnectionSpec
CredentialsSpec
DiskInfo
DiskSpec
IpFamily
IpSpec
Ipv4Spec
Ipv6Spec
NetworkType
Operations
PlacementInfo
PlacementSpec
StubFactory
- com.vmware.vcenter.vm_client module
DataSets
GuestOS
GuestOS.ALMALINUX_64
GuestOS.AMAZONLINUX2_64
GuestOS.AMAZONLINUX3_64
GuestOS.ASIANUX_3
GuestOS.ASIANUX_3_64
GuestOS.ASIANUX_4
GuestOS.ASIANUX_4_64
GuestOS.ASIANUX_5_64
GuestOS.ASIANUX_7_64
GuestOS.ASIANUX_8_64
GuestOS.ASIANUX_9_64
GuestOS.CENTOS
GuestOS.CENTOS_6
GuestOS.CENTOS_64
GuestOS.CENTOS_6_64
GuestOS.CENTOS_7
GuestOS.CENTOS_7_64
GuestOS.CENTOS_8_64
GuestOS.CENTOS_9_64
GuestOS.COREOS_64
GuestOS.CRXPOD_1
GuestOS.CRXSYS_1
GuestOS.DARWIN
GuestOS.DARWIN_10
GuestOS.DARWIN_10_64
GuestOS.DARWIN_11
GuestOS.DARWIN_11_64
GuestOS.DARWIN_12_64
GuestOS.DARWIN_13_64
GuestOS.DARWIN_14_64
GuestOS.DARWIN_15_64
GuestOS.DARWIN_16_64
GuestOS.DARWIN_17_64
GuestOS.DARWIN_18_64
GuestOS.DARWIN_19_64
GuestOS.DARWIN_20_64
GuestOS.DARWIN_21_64
GuestOS.DARWIN_22_64
GuestOS.DARWIN_23_64
GuestOS.DARWIN_64
GuestOS.DEBIAN_10
GuestOS.DEBIAN_10_64
GuestOS.DEBIAN_11
GuestOS.DEBIAN_11_64
GuestOS.DEBIAN_12
GuestOS.DEBIAN_12_64
GuestOS.DEBIAN_4
GuestOS.DEBIAN_4_64
GuestOS.DEBIAN_5
GuestOS.DEBIAN_5_64
GuestOS.DEBIAN_6
GuestOS.DEBIAN_6_64
GuestOS.DEBIAN_7
GuestOS.DEBIAN_7_64
GuestOS.DEBIAN_8
GuestOS.DEBIAN_8_64
GuestOS.DEBIAN_9
GuestOS.DEBIAN_9_64
GuestOS.DOS
GuestOS.ECOMSTATION
GuestOS.ECOMSTATION_2
GuestOS.FEDORA
GuestOS.FEDORA_64
GuestOS.FREEBSD
GuestOS.FREEBSD_11
GuestOS.FREEBSD_11_64
GuestOS.FREEBSD_12
GuestOS.FREEBSD_12_64
GuestOS.FREEBSD_13
GuestOS.FREEBSD_13_64
GuestOS.FREEBSD_14
GuestOS.FREEBSD_14_64
GuestOS.FREEBSD_64
GuestOS.GENERIC_LINUX
GuestOS.MANDRAKE
GuestOS.MANDRIVA
GuestOS.MANDRIVA_64
GuestOS.NETWARE_4
GuestOS.NETWARE_5
GuestOS.NETWARE_6
GuestOS.NLD_9
GuestOS.OES
GuestOS.OPENSERVER_5
GuestOS.OPENSERVER_6
GuestOS.OPENSUSE
GuestOS.OPENSUSE_64
GuestOS.ORACLE_LINUX
GuestOS.ORACLE_LINUX_6
GuestOS.ORACLE_LINUX_64
GuestOS.ORACLE_LINUX_6_64
GuestOS.ORACLE_LINUX_7
GuestOS.ORACLE_LINUX_7_64
GuestOS.ORACLE_LINUX_8_64
GuestOS.ORACLE_LINUX_9_64
GuestOS.OS2
GuestOS.OTHER
GuestOS.OTHER_24X_LINUX
GuestOS.OTHER_24X_LINUX_64
GuestOS.OTHER_26X_LINUX
GuestOS.OTHER_26X_LINUX_64
GuestOS.OTHER_3X_LINUX
GuestOS.OTHER_3X_LINUX_64
GuestOS.OTHER_4X_LINUX
GuestOS.OTHER_4X_LINUX_64
GuestOS.OTHER_5X_LINUX
GuestOS.OTHER_5X_LINUX_64
GuestOS.OTHER_64
GuestOS.OTHER_6X_LINUX
GuestOS.OTHER_6X_LINUX_64
GuestOS.OTHER_LINUX
GuestOS.OTHER_LINUX_64
GuestOS.REDHAT
GuestOS.RHEL_2
GuestOS.RHEL_3
GuestOS.RHEL_3_64
GuestOS.RHEL_4
GuestOS.RHEL_4_64
GuestOS.RHEL_5
GuestOS.RHEL_5_64
GuestOS.RHEL_6
GuestOS.RHEL_6_64
GuestOS.RHEL_7
GuestOS.RHEL_7_64
GuestOS.RHEL_8_64
GuestOS.RHEL_9_64
GuestOS.ROCKYLINUX_64
GuestOS.SJDS
GuestOS.SLES
GuestOS.SLES_10
GuestOS.SLES_10_64
GuestOS.SLES_11
GuestOS.SLES_11_64
GuestOS.SLES_12
GuestOS.SLES_12_64
GuestOS.SLES_15_64
GuestOS.SLES_16_64
GuestOS.SLES_64
GuestOS.SOLARIS_10
GuestOS.SOLARIS_10_64
GuestOS.SOLARIS_11_64
GuestOS.SOLARIS_6
GuestOS.SOLARIS_7
GuestOS.SOLARIS_8
GuestOS.SOLARIS_9
GuestOS.SUSE
GuestOS.SUSE_64
GuestOS.TURBO_LINUX
GuestOS.TURBO_LINUX_64
GuestOS.UBUNTU
GuestOS.UBUNTU_64
GuestOS.UNIXWARE_7
GuestOS.VMKERNEL
GuestOS.VMKERNEL_5
GuestOS.VMKERNEL_6
GuestOS.VMKERNEL_65
GuestOS.VMKERNEL_7
GuestOS.VMKERNEL_8
GuestOS.VMWARE_PHOTON_64
GuestOS.WINDOWS_11_64
GuestOS.WINDOWS_12_64
GuestOS.WINDOWS_7
GuestOS.WINDOWS_7_64
GuestOS.WINDOWS_7_SERVER_64
GuestOS.WINDOWS_8
GuestOS.WINDOWS_8_64
GuestOS.WINDOWS_8_SERVER_64
GuestOS.WINDOWS_9
GuestOS.WINDOWS_9_64
GuestOS.WINDOWS_9_SERVER_64
GuestOS.WINDOWS_HYPERV
GuestOS.WINDOWS_SERVER_2019
GuestOS.WINDOWS_SERVER_2021
GuestOS.WINDOWS_SERVER_2025
GuestOS.WIN_2000_ADV_SERV
GuestOS.WIN_2000_PRO
GuestOS.WIN_2000_SERV
GuestOS.WIN_31
GuestOS.WIN_95
GuestOS.WIN_98
GuestOS.WIN_LONGHORN
GuestOS.WIN_LONGHORN_64
GuestOS.WIN_ME
GuestOS.WIN_NET_BUSINESS
GuestOS.WIN_NET_DATACENTER
GuestOS.WIN_NET_DATACENTER_64
GuestOS.WIN_NET_ENTERPRISE
GuestOS.WIN_NET_ENTERPRISE_64
GuestOS.WIN_NET_STANDARD
GuestOS.WIN_NET_STANDARD_64
GuestOS.WIN_NET_WEB
GuestOS.WIN_NT
GuestOS.WIN_VISTA
GuestOS.WIN_VISTA_64
GuestOS.WIN_XP_HOME
GuestOS.WIN_XP_PRO
GuestOS.WIN_XP_PRO_64
GuestOSFamily
Hardware
Hardware.Info
Hardware.UpdateSpec
Hardware.UpgradePolicy
Hardware.UpgradeStatus
Hardware.Version
Hardware.Version.VMX_03
Hardware.Version.VMX_04
Hardware.Version.VMX_06
Hardware.Version.VMX_07
Hardware.Version.VMX_08
Hardware.Version.VMX_09
Hardware.Version.VMX_10
Hardware.Version.VMX_11
Hardware.Version.VMX_12
Hardware.Version.VMX_13
Hardware.Version.VMX_14
Hardware.Version.VMX_15
Hardware.Version.VMX_16
Hardware.Version.VMX_17
Hardware.Version.VMX_18
Hardware.Version.VMX_19
Hardware.Version.VMX_20
Hardware.Version.VMX_21
Hardware.get()
Hardware.update()
Hardware.upgrade()
Identity
LibraryItem
Power
StubFactory
Tools
- com.vmware.vcenter.vm_template_client module
LibraryItems
LibraryItems.CpuInfo
LibraryItems.CpuUpdateSpec
LibraryItems.CreatePlacementSpec
LibraryItems.CreateSpec
LibraryItems.CreateSpecDiskStorage
LibraryItems.CreateSpecDiskStoragePolicy
LibraryItems.CreateSpecVmHomeStorage
LibraryItems.CreateSpecVmHomeStoragePolicy
LibraryItems.DeployPlacementSpec
LibraryItems.DeploySpec
LibraryItems.DeploySpecDiskStorage
LibraryItems.DeploySpecDiskStoragePolicy
LibraryItems.DeploySpecVmHomeStorage
LibraryItems.DeploySpecVmHomeStoragePolicy
LibraryItems.DiskInfo
LibraryItems.DiskStorageInfo
LibraryItems.DiskUpdateSpec
LibraryItems.EthernetInfo
LibraryItems.EthernetUpdateSpec
LibraryItems.GuestCustomizationSpec
LibraryItems.HardwareCustomizationSpec
LibraryItems.Info
LibraryItems.MemoryInfo
LibraryItems.MemoryUpdateSpec
LibraryItems.VmHomeStorageInfo
LibraryItems.create()
LibraryItems.deploy()
LibraryItems.get()
StubFactory
- Subpackages
Submodules
com.vmware.appliance_client module
The com.vmware.appliance_client
module provides classes for managing
vCenter Appliance configuration. The module is available starting in vSphere
6.5.
- class com.vmware.appliance_client.Cores(config)
Bases:
VapiInterface
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(name=None, size=None, creation_time=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Identifier of the core file. This attribute was added in vSphere API 8.0.2.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.appliance.supportbundle.cores
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.appliance.supportbundle.cores
.size (
long
) – Size of core file. This attribute was added in vSphere API 8.0.2.0.creation_time (
datetime.datetime
) – Creation time of core file. This attribute was added in vSphere API 8.0.2.0.
- list()
Lists all the core files exists on storage. This method was added in vSphere API 8.0.2.0.
- Return type:
list
ofCores.Info
- Returns:
List of core files details.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- class com.vmware.appliance_client.Health(config)
Bases:
VapiInterface
The
Health
class provides methods to retrieve the appliance health information. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- messages(item)
Get health messages. This method was added in vSphere API 6.7.
- Parameters:
item (
str
) – ID of the data item The parameter must be an identifier for the resource type:com.vmware.appliance.health
.- Return type:
list
ofNotification
- Returns:
List of the health messages
- Raise:
com.vmware.vapi.std.errors_client.NotFound
Unknown health item- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.HealthCheckSettings(config)
Bases:
VapiInterface
The
HealthCheckSettings
class provides methods to enable/disable health check settings in vCenter Server. This class was added in vSphere API 7.0.0.1.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class SettingSpec(db_health_check_state_manual_backup=None, db_health_check_state_scheduled_backup=None)
Bases:
VapiStruct
HealthCheckSettings.SettingSpec
class contains specification of vCenter Server health and its corresponding state. This class was added in vSphere API 7.0.0.1.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
db_health_check_state_manual_backup (
bool
) – Health check state of database during manual backup with this option set, the health status of the particular health check will be reported. This attribute was added in vSphere API 7.0.0.1.db_health_check_state_scheduled_backup (
bool
) – Health check state of database during schedule backup with this option set, the health status of the particular health check will be reported. This attribute was added in vSphere API 7.0.0.1.
- class UpdateSpec(db_health_check_state_manual_backup=None, db_health_check_state_scheduled_backup=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
db_health_check_state_manual_backup (
bool
orNone
) – Health check state of database during manual backup with this option set, the health status of the particular health check will be enabled. This attribute was added in vSphere API 7.0.0.1. If None the current state will remain unchanged.db_health_check_state_scheduled_backup (
bool
orNone
) – Health check state of database during schedule backup with this option set, the health status of the particular health check will be enabled. This attribute was added in vSphere API 7.0.0.1. If None the current state will remain unchanged.
- get()
Get health settings for vCenter Server. This method was added in vSphere API 7.0.0.1.
- Return type:
- Returns:
health settings.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- update(health_settings)
Set health settings based on provided healthSpec. This method was added in vSphere API 7.0.0.1.
- Parameters:
health_settings (
HealthCheckSettings.UpdateSpec
) –- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- class com.vmware.appliance_client.LocalAccounts(config)
Bases:
VapiInterface
The
LocalAccounts
class provides methods to manage local user account. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Config(password=None, old_password=None, full_name=None, email=None, roles=None, enabled=None, password_expires=None, password_expires_at=None, inactive_after_password_expiration=None, days_after_password_expiration=None, min_days_between_password_change=None, max_days_between_password_change=None, warn_days_before_password_expiration=None)
Bases:
VapiStruct
The
LocalAccounts.Config
class defines the information required for the account. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
password (
str
) – Password. This attribute was added in vSphere API 6.7.old_password (
str
orNone
) – Old password of the user (required in case of the password change, not required if superAdmin user changes the password of the other user). This attribute was added in vSphere API 6.7. If None, user may not have password set.full_name (
str
orNone
) – Full name of the user. This attribute was added in vSphere API 6.7. If None, user will have no fullname.email (
str
orNone
) – Email address of the local account. This attribute was added in vSphere API 6.7. If None, user will have no email.roles (
list
ofstr
) – User roles. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.appliance.roles
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.appliance.roles
.enabled (
bool
orNone
) – Flag indicating if the account is enabled. This attribute was added in vSphere API 6.7. If None, defaults to Truepassword_expires (
bool
orNone
) – Flag indicating if the account password expires. This attribute was added in vSphere API 6.7. If None, defaults to True.password_expires_at (
datetime.datetime
orNone
) – Date when the account’s password will expire. This attribute was added in vSphere API 6.7. If None, will be taken from system defaults (see local-accounts/policy).inactive_after_password_expiration (
bool
orNone
) – Flag indicating if the account will be locked after password expiration. This attribute was added in vSphere API 6.7. If None, defaults to True.days_after_password_expiration (
long
orNone
) – Number of days after password expiration before the account will be locked. This attribute was added in vSphere API 6.7. If None, will be taken from system defaults (see local-accounts/policy).min_days_between_password_change (
long
orNone
) – Minimum number of days between password change. This attribute was added in vSphere API 6.7. If None, will be taken from system defaults (see local-accounts/policy).max_days_between_password_change (
long
orNone
) – Maximum number of days between password change. This attribute was added in vSphere API 6.7. If None, will be taken from system defaults (see local-accounts/policy).warn_days_before_password_expiration (
long
orNone
) – Number of days of warning before password expires. This attribute was added in vSphere API 6.7. If None, will be taken from system defaults (see local-accounts/policy).
- class Info(fullname=None, email=None, roles=None, enabled=None, has_password=None, last_password_change=None, password_expires_at=None, inactive_at=None, min_days_between_password_change=None, max_days_between_password_change=None, warn_days_before_password_expiration=None)
Bases:
VapiStruct
The
LocalAccounts.Info
class defines the local account properties. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
fullname (
str
orNone
) – Full name of the user. This attribute was added in vSphere API 6.7. If None, the value was never set.email (
str
orNone
) – Email address of the local account. This attribute was added in vSphere API 6.7. If None, the value was never set.roles (
list
ofstr
) – User roles. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.appliance.roles
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.appliance.roles
.enabled (
bool
) – Flag indicating if the account is enabled. This attribute was added in vSphere API 6.7.has_password (
bool
) – Is the user password set. This attribute was added in vSphere API 6.7.last_password_change (
datetime.datetime
orNone
) – Date and time password was changed. This attribute was added in vSphere API 6.7. If None, the password was never set.password_expires_at (
datetime.datetime
orNone
) – Date when the account’s password will expire. This attribute was added in vSphere API 6.7. If None, the password never expires.inactive_at (
datetime.datetime
orNone
) – Date and time account will be locked after password expiration. This attribute was added in vSphere API 6.7. If None, account will not be locked.min_days_between_password_change (
long
orNone
) – Minimum number of days between password change. This attribute was added in vSphere API 6.7. If None, pasword can be changed any time.max_days_between_password_change (
long
orNone
) – Maximum number of days between password change. This attribute was added in vSphere API 6.7. If None, password never expires.warn_days_before_password_expiration (
long
orNone
) – Number of days of warning before password expires. This attribute was added in vSphere API 6.7. If None, a user is never warned.
- class UpdateConfig(password=None, old_password=None, full_name=None, email=None, roles=None, enabled=None, password_expires=None, password_expires_at=None, inactive_after_password_expiration=None, days_after_password_expiration=None, min_days_between_password_change=None, max_days_between_password_change=None, warn_days_before_password_expiration=None)
Bases:
VapiStruct
The
LocalAccounts.UpdateConfig
class defines the fields that might be updated. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
password (
str
orNone
) – Password. This attribute was added in vSphere API 6.7. If None, value will not be changedold_password (
str
orNone
) – Old password of the user (required in case of the password change, not required if superAdmin user changes the password of the other user). This attribute was added in vSphere API 6.7. If None, user may not have password set.full_name (
str
orNone
) – Full name of the user. This attribute was added in vSphere API 6.7. If None, value will not be changedemail (
str
orNone
) – Email address of the local account. This attribute was added in vSphere API 6.7. If None, value will not be changedroles (
list
ofstr
orNone
) – User roles. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.appliance.roles
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.appliance.roles
. If None, value will not be changedenabled (
bool
orNone
) – Flag indicating if the account is enabled. This attribute was added in vSphere API 6.7. If None, value will not be changedpassword_expires (
bool
orNone
) – Flag indicating if the account password expires. This attribute was added in vSphere API 6.7. If None, value will not be changedpassword_expires_at (
datetime.datetime
orNone
) – Date when the account’s password will expire. This attribute was added in vSphere API 6.7. If None, value will not be changedinactive_after_password_expiration (
bool
orNone
) – Flag indicating if the account will be locked after password expiration. This attribute was added in vSphere API 6.7. If None, value will not be changeddays_after_password_expiration (
long
orNone
) – Number of days after password expiration before the account will be locked. This attribute was added in vSphere API 6.7. If None, value will not be changedmin_days_between_password_change (
long
orNone
) – Minimum number of days between password change. This attribute was added in vSphere API 6.7. If None, value will not be changedmax_days_between_password_change (
long
orNone
) – Maximum number of days between password change. This attribute was added in vSphere API 6.7. If None, value will not be changedwarn_days_before_password_expiration (
long
orNone
) – Number of days of warning before password expires. This attribute was added in vSphere API 6.7. If None, value will not be changed
- create(username, config)
Create a new local user account. This method was added in vSphere API 6.7.
- Parameters:
username (
str
) – User login name The parameter must be an identifier for the resource type:com.vmware.appliance.local_accounts
.config (
LocalAccounts.Config
) – User configuration
- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
If an account already exists- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
If a username is invalid (username is validated against [a-zA-Z0-9][a-zA-Z0-9-.\@]*[a-zA-Z0-9] pattern)- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- delete(username)
Delete a local user account. This method was added in vSphere API 6.7.
- Parameters:
username (
str
) – User login name The parameter must be an identifier for the resource type:com.vmware.appliance.local_accounts
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the account is not found- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- get(username)
Get the local user account information. This method was added in vSphere API 6.7.
- Parameters:
username (
str
) – User login name- Return type:
- Returns:
Local user account information
- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the account is not found- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- list()
Get a list of the local user accounts. This method was added in vSphere API 6.7.
- Return type:
list
ofstr
- Returns:
List of identifiers The return value will contain identifiers for the resource type:
com.vmware.appliance.local_accounts
.- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- set(username, config)
Set local user account properties. This method was added in vSphere API 6.7.
- Parameters:
username (
str
) – User login name The parameter must be an identifier for the resource type:com.vmware.appliance.local_accounts
.config (
LocalAccounts.Config
) – User configuration
- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the account is not found- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- update(username, config)
Update selected fields in local user account properties. This method was added in vSphere API 6.7.
- Parameters:
username (
str
) – User login name The parameter must be an identifier for the resource type:com.vmware.appliance.local_accounts
.config (
LocalAccounts.UpdateConfig
) – User configuration
- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the account is not found- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.Monitoring(config)
Bases:
VapiInterface
Monitoring
class provides methods Get and list monitoring data for requested item.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FunctionType(string)
Bases:
Enum
Monitoring.FunctionType
class Defines aggregation functionNote
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 theFunctionType
instance.
- AVG = FunctionType(string='AVG')
Aggregation takes average per period
- COUNT = FunctionType(string='COUNT')
Aggregation takes count per period (sum)
- MAX = FunctionType(string='MAX')
Aggregation takes maximums per period
- MIN = FunctionType(string='MIN')
Aggregation takes minimums per period
- class IntervalType(string)
Bases:
Enum
Monitoring.IntervalType
class Defines interval between the values in hours and mins, for which aggregation will applyNote
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 theIntervalType
instance.
- DAY1 = IntervalType(string='DAY1')
24 hours interval between values. One year has 365 values.
- HOURS2 = IntervalType(string='HOURS2')
Two hours interval between values. One month has 360 values.
- HOURS6 = IntervalType(string='HOURS6')
Six hour interval between values. One quarter is 360 values.
- MINUTES30 = IntervalType(string='MINUTES30')
Thirty minutes interval between values. One week is 336 values.
- MINUTES5 = IntervalType(string='MINUTES5')
Five minutes interval between values (finest). One day would have 288 values, one week is 2016.
- class MonitoredItem(id=None, name=None, units=None, category=None, instance=None, description=None)
Bases:
VapiStruct
Monitoring.MonitoredItem
class Structure representing requested monitored item data.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – monitored item ID Ex: CPU, MEMORY When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.appliance.monitoring
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.appliance.monitoring
.name (
str
) – monitored item name Ex: “Network write speed”units (
str
) – Y-axis label EX: “Mbps”, “%”category (
str
) – category Ex: network, storage etcinstance (
str
) – instance name Ex: eth0description (
str
) – monitored item description Ex: com.vmware.applmgmt.mon.descr.net.rx.packetRate.eth0
- class MonitoredItemData(name=None, interval=None, function=None, start_time=None, end_time=None, data=None)
Bases:
VapiStruct
Monitoring.MonitoredItemData
class Structure representing monitored item data.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Monitored item IDs Ex: CPU, MEMORY, STORAGE_TOTAL When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.appliance.monitoring
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.appliance.monitoring
.interval (
Monitoring.IntervalType
) – interval between values in hours, minutesfunction (
Monitoring.FunctionType
) – aggregation functionstart_time (
datetime.datetime
) – Start time in UTCend_time (
datetime.datetime
) – End time in UTCdata (
list
ofstr
) – list of values
- class MonitoredItemDataRequest(names=None, interval=None, function=None, start_time=None, end_time=None)
Bases:
VapiStruct
Monitoring.MonitoredItemDataRequest
class Structure representing requested monitored item data.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
names (
list
ofstr
) – monitored item IDs Ex: CPU, MEMORY When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.appliance.monitoring
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.appliance.monitoring
.interval (
Monitoring.IntervalType
) – interval between values in hours, minutesfunction (
Monitoring.FunctionType
) – aggregation functionstart_time (
datetime.datetime
) – Start time in UTCend_time (
datetime.datetime
) – End time in UTC
- get(stat_id)
Get monitored item info
- Parameters:
stat_id (
str
) – statistic item id The parameter must be an identifier for the resource type:com.vmware.appliance.monitoring
.- Return type:
- Returns:
MonitoredItem structure
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- list()
Get monitored items list
- Return type:
- Returns:
list of names
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- query(item)
Get monitoring data.
- Parameters:
item (
Monitoring.MonitoredItemDataRequest
) – MonitoredItemDataRequest Structure- Return type:
- Returns:
list of MonitoredItemData structure
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.Networking(config)
Bases:
VapiInterface
The
Networking
class provides methods Get Network configurations. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ChangeSpec(hostname=None, sso_user=None, sso_password=None, dns=None, ipv4=None, ipv6=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
hostname (
str
) – New hostname to assign to the management network of vCenter appliance. This attribute was added in vSphere API 6.7.3.sso_user (
str
) – vCenter Server SSO administrator username. This attribute was added in vSphere API 6.7.3.sso_password (
str
) – vCenter Server SSO administrator Password. This attribute was added in vSphere API 6.7.3.dns (
com.vmware.appliance.networking.dns_client.Servers.DNSServerConfig
orNone
) – DNS Configuration to set for the machine. This attribute was added in vSphere API 6.7.3. If None DNS settings will not be changedipv4 (
com.vmware.appliance.networking.interfaces_client.Ipv4.Config
orNone
) – IPv4 Configuration to set for the machine. This attribute was added in vSphere API 6.7.3. If None IPv4 settings will not be changedipv6 (
com.vmware.appliance.networking.interfaces_client.Ipv6.Config
orNone
) – IPv6 Configuration to set for the machine. This attribute was added in vSphere API 6.7.3. If None IPv6 settings will not be changed
- class DNSInfo(mode=None, hostname=None, servers=None)
Bases:
VapiStruct
The
Networking.DNSInfo
class contains information about the DNS configuration of a virtual appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
mode (
Networking.DNSInfo.DNSMode
) – DNS mode. This attribute was added in vSphere API 6.7.hostname (
str
) – Hostname. This attribute was added in vSphere API 6.7.servers (
list
ofstr
) – Servers. This attribute was added in vSphere API 6.7.
- class DNSMode(string)
Bases:
Enum
The
Networking.DNSInfo.DNSMode
class describes the source of DNS servers. This enumeration was added in vSphere API 6.7.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 theDNSMode
instance.
- DHCP = DNSMode(string='DHCP')
The DNS servers addresses are obtained from a DHCP server. This class attribute was added in vSphere API 6.7.
- STATIC = DNSMode(string='STATIC')
The DNS servers addresses are specified explicitly. This class attribute was added in vSphere API 6.7.
- class Info(dns=None, interfaces=None)
Bases:
VapiStruct
The
Networking.Info
class contains information about the network configuration of a virtual appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
dns (
Networking.DNSInfo
) – DNS configuration. This attribute was added in vSphere API 6.7.interfaces (
dict
ofstr
andcom.vmware.appliance.networking_client.Interfaces.InterfaceInfo
) – Interface configuration as a key-value map where key is a network interface name, for example, “nic0”. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.appliance.networking.interfaces
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.appliance.networking.interfaces
.
- class UpdateSpec(ipv6_enabled=None)
Bases:
VapiStruct
The
Networking.UpdateSpec
class describes whether to enable or disable ipv6 on interfaces. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
ipv6_enabled (
bool
orNone
) – IPv6 Enabled or not. This attribute was added in vSphere API 6.7. If unspecified, leaves the current state of Ipv6.
- change_task(spec)
Changes the Hostname/IP of the management network of vCenter appliance. The Hostname/IP change invokes the PNID change process which involves LDAP entry modification, updating registry entries, configuration files modification and network configuration changes. vCenter server is expected to be down for few minutes during these changes. This method was added in vSphere API 6.7.3.
- Parameters:
spec (
Networking.ChangeSpec
) – Information required to change the hostname.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if it’s not embedded node- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if passed arguments are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user is not authenticated.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if another change task is in progress
- get()
Get Networking information for all configured interfaces. This method was added in vSphere API 6.7.
- Return type:
- Returns:
The Map of network configuration info for all interfaces.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- reset()
Reset and restarts network configuration on all interfaces, also this will renew the DHCP lease for DHCP IP address. This method was added in vSphere API 6.7.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- update(spec)
Enable or Disable ipv6 on all interfaces. This method was added in vSphere API 6.7.
- Parameters:
spec (
Networking.UpdateSpec
) – update spec with optional boolean value- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- class com.vmware.appliance_client.Notification(id=None, time=None, message=None, resolution=None)
Bases:
VapiStruct
The
Notification
class describes a notification that can be reported by the appliance task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – The notification id. This attribute was added in vSphere API 6.7.time (
datetime.datetime
orNone
) – The time the notification was raised/found. This attribute was added in vSphere API 6.7. Only if the time information is available.message (
com.vmware.vapi.std_client.LocalizableMessage
) – The notification message. This attribute was added in vSphere API 6.7.resolution (
com.vmware.vapi.std_client.LocalizableMessage
orNone
) – The resolution message, if any. This attribute was added in vSphere API 6.7. Onlyset
for warnings and errors.
- class com.vmware.appliance_client.Notifications(info=None, warnings=None, errors=None)
Bases:
VapiStruct
The
Notifications
class contains info/warning/error messages that can be reported be the appliance task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
info (
list
ofNotification
orNone
) – Info notification messages reported. This attribute was added in vSphere API 6.7. Onlyset
if an info was reported by the appliance task.warnings (
list
ofNotification
orNone
) – Warning notification messages reported. This attribute was added in vSphere API 6.7. Onlyset
if an warning was reported by the appliance task.errors (
list
ofNotification
orNone
) – Error notification messages reported. This attribute was added in vSphere API 6.7. Onlyset
if an error was reported by the appliance task.
- class com.vmware.appliance_client.Ntp(config)
Bases:
VapiInterface
Ntp
class provides methods Gets NTP configuration status and tests connection to ntp servers. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class LocalizableMessage(id=None, default_message=None, args=None)
Bases:
VapiStruct
Ntp.LocalizableMessage
class Structure representing message. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – id in message bundle. This attribute was added in vSphere API 6.7.default_message (
str
) – text in english. This attribute was added in vSphere API 6.7.args (
list
ofstr
) – nested data. This attribute was added in vSphere API 6.7.
- class ServerStatus(string)
Bases:
Enum
Ntp.ServerStatus
class Status of server during test. This enumeration was added in vSphere API 6.7.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 theServerStatus
instance.
- SERVER_REACHABLE = ServerStatus(string='SERVER_REACHABLE')
Server is reachable. This class attribute was added in vSphere API 6.7.
- SERVER_UNREACHABLE = ServerStatus(string='SERVER_UNREACHABLE')
Server is unreachable. This class attribute was added in vSphere API 6.7.
- class TestRunStatus(server=None, status=None, message=None)
Bases:
VapiStruct
Ntp.TestRunStatus
class Status of the test. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
server (
str
) – Server name associated with the test run. This attribute was added in vSphere API 6.7.status (
Ntp.ServerStatus
) – Server status. This attribute was added in vSphere API 6.7.message (
Ntp.LocalizableMessage
) – Message associated with status. This attribute was added in vSphere API 6.7.
- get()
Get the NTP configuration status. If you run the ‘timesync.get’ command, you can retrieve the current time synchronization method (NTP- or VMware Tools-based). The ‘ntp’ command always returns the NTP server information, even when the time synchronization mode is not set to NTP. If the time synchronization mode is not NTP-based, the NTP server status is displayed as down. This method was added in vSphere API 6.7.
- Return type:
list
ofstr
- Returns:
List of NTP servers.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- set(servers)
Set NTP servers. This method updates old NTP servers from configuration and sets the input NTP servers in the configuration. If NTP based time synchronization is used internally, the NTP daemon will be restarted to reload given NTP configuration. In case NTP based time synchronization is not used, this method only replaces servers in the NTP configuration. This method was added in vSphere API 6.7.
- Parameters:
servers (
list
ofstr
) – List of host names or ip addresses of ntp servers.- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- test(servers)
Test the connection to a list of ntp servers. This method was added in vSphere API 6.7.
- Parameters:
servers (
list
ofstr
) – List of host names or IP addresses of NTP servers.- Return type:
list
ofNtp.TestRunStatus
- Returns:
List of test run statuses.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.Recovery(config)
Bases:
VapiInterface
The
Recovery
class provides methods to invoke an appliance recovery (backup and restore). This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(supported=None)
Bases:
VapiStruct
The
Recovery.Info
class contains the information about the appliance recovery environment. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
supported (
bool
) – Is recovery supported in this appliance. This attribute was added in vSphere API 6.7.
- get()
Gets the properties of the appliance Recovery subsystem. This method was added in vSphere API 6.7.
- Return type:
- Returns:
Structure containing the properties of the Recovery subsystem.
- Raise:
com.vmware.vapi.std.errors_client.Error
if any error occurs during the execution of the operation.
- class com.vmware.appliance_client.Services(config)
Bases:
VapiInterface
The
Service
class provides methods to manage a single/set of appliance services. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(description=None, state=None)
Bases:
VapiStruct
The
Services.Info
class contains information about a service. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
description (
str
) – Service description. This attribute was added in vSphere API 6.7.state (
Services.State
) – Running State. This attribute was added in vSphere API 6.7.
- class State(string)
Bases:
Enum
The
Services.State
class defines valid Run State for services. This enumeration was added in vSphere API 6.7.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 theState
instance.
- STARTED = State(string='STARTED')
Service Run State is Started, it is fully functional. This class attribute was added in vSphere API 6.7.
- STARTING = State(string='STARTING')
Service Run State is Starting, it is still not functional. This class attribute was added in vSphere API 6.7.
- STOPPED = State(string='STOPPED')
Service Run State is Stopped. This class attribute was added in vSphere API 6.7.
- STOPPING = State(string='STOPPING')
Service Run State is Stopping, it is not functional. This class attribute was added in vSphere API 6.7.
- get(service)
Returns the state of a service. This method was added in vSphere API 6.7.
- Parameters:
service (
str
) – identifier of the service whose state is being queried. The parameter must be an identifier for the resource type:com.vmware.appliance.services
.- Return type:
- Returns:
Service Info structure.
- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the service associated withservice
does not exist.- Raise:
com.vmware.vapi.std.errors_client.Error
if any other error occurs during the execution of the operation.
- list()
Lists details of vCenter services. This method was added in vSphere API 6.7.
- Return type:
dict
ofstr
andServices.Info
- Returns:
Map of service identifiers to service Info structures. The key in the return value
dict
will be an identifier for the resource type:com.vmware.appliance.services
.- Raise:
com.vmware.vapi.std.errors_client.Error
if any error occurs during the execution of the operation.
- restart(service)
Restarts a service. This method was added in vSphere API 6.7.
- Parameters:
service (
str
) – identifier of the service to restart The parameter must be an identifier for the resource type:com.vmware.appliance.services
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the service associated withservice
does not exist.- Raise:
com.vmware.vapi.std.errors_client.TimedOut
if any timeout occurs during the execution of the restart operation.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the operation is denied in the current state of the service. If a stop or start operation is in progress, issuing a restart operation will lead to this error.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if a restart operation is issued on a service which has startup type StartupType#DISABLED- Raise:
com.vmware.vapi.std.errors_client.Error
if any other error occurs during the execution of the operation.
- start(service)
Starts a service. This method was added in vSphere API 6.7.
- Parameters:
service (
str
) – identifier of the service to start The parameter must be an identifier for the resource type:com.vmware.appliance.services
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the service associated withservice
does not exist.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the operation is denied in the current state of the service. If a stop or restart operation is in progress, the start operation will not be allowed.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if start operation is issued on a service which has startup type StartupType#DISABLED.- Raise:
com.vmware.vapi.std.errors_client.TimedOut
if any timeout occurs during the execution of the start operation. Timeout occurs when the service takes longer than StartTimeout to start.- Raise:
com.vmware.vapi.std.errors_client.Error
if any other error occurs during the execution of the operation.
- stop(service)
Stops a service. This method was added in vSphere API 6.7.
- Parameters:
service (
str
) – identifier of the service to stop The parameter must be an identifier for the resource type:com.vmware.appliance.services
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the service associated withservice
does not exist.- Raise:
com.vmware.vapi.std.errors_client.Error
if any other error occurs during the execution of the operation.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the operation is denied in the current state of the service. If a stop operation is in progress, issuing another stop operation will lead to this error.
- class com.vmware.appliance_client.Shutdown(config)
Bases:
VapiInterface
Shutdown
class provides methods Performs reboot/shutdown operations on appliance. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ShutdownConfig(shutdown_time=None, action=None, reason=None)
Bases:
VapiStruct
Shutdown.ShutdownConfig
class Structure that defines shutdown configuration returned by the Shutdown.get operation. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
shutdown_time (
datetime.datetime
orNone
) – Shutdown time. This attribute was added in vSphere API 6.7. shutdownTime Optional value of pending shutdown timeaction (
str
) – The pending shutdown operation. The string values for pending operations can be ‘poweroff’, ‘reboot’ or ‘’. This attribute was added in vSphere API 6.7.reason (
str
) – The reason behind the shutdown action. This attribute was added in vSphere API 6.7.
- cancel()
Cancel pending shutdown action. This method was added in vSphere API 6.7.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- get()
Get details about the pending shutdown action. This method was added in vSphere API 6.7.
- Return type:
- Returns:
Configuration of pending shutdown action.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- poweroff(delay, reason)
Power off the appliance. This method was added in vSphere API 6.7.
- Parameters:
delay (
long
) – Minutes after which poweroff should start. If 0 is specified, poweroff will start immediately.reason (
str
) – Reason for peforming poweroff.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- reboot(delay, reason)
Reboot the appliance. This method was added in vSphere API 6.7.
- Parameters:
delay (
long
) – Minutes after which reboot should start. If 0 is specified, reboot will start immediately.reason (
str
) – Reason for peforming reboot.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.appliance_client.SubtaskInfo(progress=None, result=None, description=None, service=None, operation=None, parent=None, target=None, status=None, cancelable=None, error=None, start_time=None, end_time=None, user=None)
Bases:
VapiStruct
The
SubtaskInfo
class contains information about one of the subtasks that makes up an appliance task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
progress (
com.vmware.cis.task_client.Progress
) – Progress of the operation. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofCommonInfo#status
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.result (
Notifications
orNone
) – Result of the operation. If an operation reports partial results before it completes, this attribute could beset
before thecom.vmware.cis.task_client.CommonInfo.status
has the valuecom.vmware.cis.task_client.Status.SUCCEEDED
. The value could change as the operation progresses. This attribute was added in vSphere API 6.7. This attribute will be None if result is not available at the current step of the operation.description (
com.vmware.vapi.std_client.LocalizableMessage
) – Description of the operation associated with the task.service (
str
) – Identifier of the service containing the operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.service
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.service
.operation (
str
) – Identifier of the operation associated with the task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.operation
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.operation
.parent (
str
orNone
) – Parent of the current task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.cis.task
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.cis.task
. This attribute will be None if the task has no parent.target (
com.vmware.vapi.std_client.DynamicID
orNone
) – Identifier of the target created by the operation or an existing one the operation performed on. This attribute will be None if the operation has no target or multiple targets.status (
com.vmware.cis.task_client.Status
) – Status of the operation associated with the task.cancelable (
bool
) – Flag to indicate whether or not the operation can be cancelled. The value may change as the operation progresses.error (
Exception
orNone
) – Description of the error if the operation status is “FAILED”. If None the description of why the operation failed will be included in the result of the operation (seecom.vmware.cis.task_client.Info.result
).start_time (
datetime.datetime
) – Time when the operation is started. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.end_time (
datetime.datetime
) – Time when the operation is completed. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.SUCCEEDED
orcom.vmware.cis.task_client.Status.FAILED
.user (
str
orNone
) – Name of the user who performed the operation. This attribute will be None if the operation is performed by the system.
- class com.vmware.appliance_client.SupportBundle(config)
Bases:
VapiInterface
The
SupportBundle
class provides methods to create support bundle, list and delete generated support bundle. This class was added in vSphere API 7.0.1.0.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ContentType(string)
Bases:
Enum
The
SupportBundle.ContentType
class defines the content in the support bundle generated. This enumeration was added in vSphere API 8.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 theContentType
instance.
- ALL = ContentType(string='ALL')
Support bundle will contain logs and core files. By default logs and cores are collected. This class attribute was added in vSphere API 8.0.2.0.
- CORES = ContentType(string='CORES')
Support bundle will contain only core files. This class attribute was added in vSphere API 8.0.2.0.
- LOGS = ContentType(string='LOGS')
Support bundle will contain only logs. This class attribute was added in vSphere API 8.0.2.0.
- class CreateSpec(description=None, components=None, content_type=None, partition=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
description (
str
) – Support bundle creation description. This attribute was added in vSphere API 7.0.1.0.components ((
dict
ofstr
andlist
ofstr
) orNone
) – Support bundle components to be included. Map with groupName as key and list of components in that group as the value. This attribute was added in vSphere API 7.0.1.0.content_type (
SupportBundle.ContentType
orNone
) – Describes the content type to be collected in support bundle. This attribute was added in vSphere API 8.0.2.0. If None, both logs and core files will be collected.partition (
str
orNone
) – Partition to be used for saving the support bundle. Available partitions can be retrieved using storage.list API. This attribute was added in vSphere API 7.0.1.0.
- class CreationStatus(string)
Bases:
Enum
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 theCreationStatus
instance.
- CANCELLED = CreationStatus(string='CANCELLED')
Support bundle creation task Cancelled. This class attribute was added in vSphere API 7.0.1.0.
- FAILED = CreationStatus(string='FAILED')
Support bundle creation task Failed. This class attribute was added in vSphere API 7.0.1.0.
- SUCCEEDED = CreationStatus(string='SUCCEEDED')
Support bundle creation task succeeded. This class attribute was added in vSphere API 7.0.1.0.
- class FilterSpec(available=None, creation_status=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
available (
bool
orNone
) – Filter only downloadable details. This attribute was added in vSphere API 7.0.1.0.creation_status (
SupportBundle.CreationStatus
orNone
) – Filter by task status. This attribute was added in vSphere API 7.0.1.0.
- class Info(description=None, status=None, generation_time=None, url=None, expiration_time=None, downloadable=None, size=None, failure_reason=None, checksum_value=None, id=None, content_type=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
description (
str
) – Support bundle creation description. This attribute was added in vSphere API 7.0.1.0.status (
SupportBundle.CreationStatus
) – Status of the task. This attribute was added in vSphere API 7.0.1.0.generation_time (
datetime.datetime
) – Support bundle generation time. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.url (
str
) – Support bundle downlooad URL. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.expiration_time (
datetime.datetime
) – Download expiration time. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.downloadable (
bool
) – Support bundle availability for download. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.size (
long
) – Support bundle file size in KBs. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.failure_reason (
com.vmware.vapi.std_client.LocalizableMessage
orNone
) – Reason for failure. This attribute was added in vSphere API 7.0.1.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.FAILED
.checksum_value (
str
) – Support bundle SHA256 checksum value. This attribute was added in vSphere API 8.0.2.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.id (
str
) – Identifier of the support bundle. This attribute was added in vSphere API 8.0.2.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.appliance.supportbundle
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.appliance.supportbundle
. This attribute is optional because it was added in a newer version than its parent node.content_type (
SupportBundle.ContentType
orNone
) – Describes the content type (LOGS, CORES, ALL) collected in support bundle. This attribute was added in vSphere API 8.0.2.0. This attribute is optional and it is only relevant when the value ofstatus
isSupportBundle.CreationStatus.SUCCEEDED
.
- class IterationSpec(size=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
size (
long
orNone
) – Size specifies the maximum number of results to return. This attribute was added in vSphere API 7.0.1.0. If None defaults to 50.
- class ListResult(supportbundle_operations=None)
Bases:
VapiStruct
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
supportbundle_operations (
list
ofSupportBundle.Info
) – Information about all support bundle requests. This attribute was added in vSphere API 7.0.1.0.
- create_task(spec)
Create a support bundle. This method was added in vSphere API 7.0.1.0.
- Parameters:
spec (
SupportBundle.CreateSpec
) –- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
If already a support bundle task is in progress.- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- delete(id)
Deletes the support bundle. This method was added in vSphere API 8.0.2.0.
- Parameters:
id (
str
) – The parameter must be an identifier for the resource type:com.vmware.appliance.supportbundle
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If support bundle Not Found.- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- list(iteration=None, filter=None)
Get list of support-bundles generated. This method was added in vSphere API 7.0.1.0.
- Parameters:
iteration (
SupportBundle.IterationSpec
orNone
) –filter (
SupportBundle.FilterSpec
orNone
) –
- Return type:
- Returns:
List of support bundle details.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error.
- class com.vmware.appliance_client.TaskInfo(progress=None, subtask_order=None, subtasks=None, description=None, service=None, operation=None, parent=None, target=None, status=None, cancelable=None, error=None, start_time=None, end_time=None, user=None)
Bases:
VapiStruct
The
TaskInfo
class contains information about an appliance task and the subtasks of which it consists. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
progress (
com.vmware.cis.task_client.Progress
) – Progress of the task. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofCommonInfo#status
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.subtask_order (
list
ofstr
) – List of tasks that make up this appliance task in the order they are being run. This attribute was added in vSphere API 6.7.subtasks (
dict
ofstr
andSubtaskInfo
) – Information about the subtasks that this appliance task consists of. This attribute was added in vSphere API 6.7.description (
com.vmware.vapi.std_client.LocalizableMessage
) – Description of the operation associated with the task.service (
str
) – Identifier of the service containing the operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.service
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.service
.operation (
str
) – Identifier of the operation associated with the task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.operation
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.operation
.parent (
str
orNone
) – Parent of the current task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.cis.task
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.cis.task
. This attribute will be None if the task has no parent.target (
com.vmware.vapi.std_client.DynamicID
orNone
) – Identifier of the target created by the operation or an existing one the operation performed on. This attribute will be None if the operation has no target or multiple targets.status (
com.vmware.cis.task_client.Status
) – Status of the operation associated with the task.cancelable (
bool
) – Flag to indicate whether or not the operation can be cancelled. The value may change as the operation progresses.error (
Exception
orNone
) – Description of the error if the operation status is “FAILED”. If None the description of why the operation failed will be included in the result of the operation (seecom.vmware.cis.task_client.Info.result
).start_time (
datetime.datetime
) – Time when the operation is started. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.end_time (
datetime.datetime
) – Time when the operation is completed. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.SUCCEEDED
orcom.vmware.cis.task_client.Status.FAILED
.user (
str
orNone
) – Name of the user who performed the operation. This attribute will be None if the operation is performed by the system.
- class com.vmware.appliance_client.Timesync(config)
Bases:
VapiInterface
Timesync
class provides methods Performs time synchronization configuration. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class TimeSyncMode(string)
Bases:
Enum
The
Timesync.TimeSyncMode
class defines time synchronization modes. This enumeration was added in vSphere API 6.7.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 theTimeSyncMode
instance.
- DISABLED = TimeSyncMode(string='DISABLED')
Time synchronization is disabled. This class attribute was added in vSphere API 6.7.
- HOST = TimeSyncMode(string='HOST')
VMware Tool-based time synchronization. This class attribute was added in vSphere API 6.7.
- NTP = TimeSyncMode(string='NTP')
NTP-based time synchronization. This class attribute was added in vSphere API 6.7.
- get()
Get time synchronization mode. This method was added in vSphere API 6.7.
- Return type:
- Returns:
Time synchronization mode.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- set(mode)
Set time synchronization mode. This method was added in vSphere API 6.7.
- Parameters:
mode (
Timesync.TimeSyncMode
) – Time synchronization mode.- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error
- class com.vmware.appliance_client.Update(config)
Bases:
VapiInterface
The
Update
class provides methods to get the status of the appliance update. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(state=None, task=None, version=None, latest_query_time=None)
Bases:
VapiStruct
The
Update.Info
class describes the state of the appliance update. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
state (
Update.State
) – State of the appliance update. This attribute was added in vSphere API 6.7.task (
TaskInfo
orNone
) – The running or completed update task. This attribute was added in vSphere API 6.7.version (
str
) – Version of base appliance if state is UP_TO_DATE Version of update being staged or installed if state is INSTALL_IN_PROGRESS or STAGE_IN_PROGRESS Version of update staged if state is UPDATES_PENDING Version of update failed if state is INSTALL_FAILED or ROLLBACK_IN_PROGRESS. This attribute was added in vSphere API 6.7.latest_query_time (
datetime.datetime
orNone
) – Timestamp of latest query to update repository. This attribute was added in vSphere API 6.7. If None the update was never queried
- class State(string)
Bases:
Enum
The
Update.State
class defines the various states the appliance update can be in. This enumeration was added in vSphere API 6.7.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 theState
instance.
- INSTALL_FAILED = State(string='INSTALL_FAILED')
The appliance update failed and cannot recover. This class attribute was added in vSphere API 6.7.
- INSTALL_IN_PROGRESS = State(string='INSTALL_IN_PROGRESS')
The appliance update is in progress of installing an update. This class attribute was added in vSphere API 6.7.
- ROLLBACK_IN_PROGRESS = State(string='ROLLBACK_IN_PROGRESS')
The appliance update failed and recovery is in progress. This class attribute was added in vSphere API 6.7.
- STAGE_IN_PROGRESS = State(string='STAGE_IN_PROGRESS')
The appliance update is in progress of downloading an update. This class attribute was added in vSphere API 6.7.
- UPDATES_PENDING = State(string='UPDATES_PENDING')
A new update is available. This class attribute was added in vSphere API 6.7.
- UP_TO_DATE = State(string='UP_TO_DATE')
The appliance is up to date. This class attribute was added in vSphere API 6.7.
- cancel()
Request the cancellation the update operation that is currently in progress. This method was added in vSphere API 6.7.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
Current task is not cancellable- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
session is not authenticated- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
session is not authorized to perform this operation
- get()
Gets the current status of the appliance update. This method was added in vSphere API 6.7.
- Return type:
- Returns:
Info structure containing the status information about the appliance.
- Raise:
com.vmware.vapi.std.errors_client.Error
Generic error- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
session is not authenticated- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
session is not authorized to perform this operation
com.vmware.cis_client module
The com.vmware.cis_client
module provides VMware common infrastructure
classes.
- class com.vmware.cis_client.Session(config)
Bases:
VapiInterface
The
Session
class allows API clients to manage session tokens including creating, deleting and obtaining information about sessions.The
Session.create()
method creates session token in exchange for another authentication token.The
Session.delete()
method invalidates a session token.The
Session.get()
retrieves information about a session token.
The call to the
Session.create()
method is part of the overall authentication process for API clients. For example, the sequence of steps for establishing a session with SAML token is:Connect to lookup service.
Discover the secure token service (STS) endpoint URL.
Connect to the secure token service to obtain a SAML token.
Authenticate to the lookup service using the obtained SAML token.
Discover the API endpoint URL from lookup service.
Call the
Session.create()
method. TheSession.create()
call must include the SAML token.
See the programming guide and samples for additional information about establishing API sessions.
Execution Context and Security Context
To use session based authentication a client should supply the session token obtained through the
Session.create()
method. The client should add the session token in the security context when using SDK classes. Clients using the REST API should supply the session token using thevmware-api-session-id
HTTP header field.Session Lifetime
A session begins with call to the
Session.create()
method to exchange a SAML token for a API session token. A session ends under the following circumstances:Call to the
Session.delete()
method.The session expires. Session expiration may be caused by one of the following situations:
Client inactivity - For a particular session identified by client requests that specify the associated session ID, the lapsed time since the last request exceeds the maximum interval between requests.
Unconditional or absolute session expiration time: At the beginning of the session, the session logic uses the SAML token and the system configuration to calculate absolute expiration time.
When a session ends, the authentication logic will reject any subsequent client requests that specify that session. Any operations in progress will continue to completion.
Error Handling
The
Session
returns the following exceptions:com.vmware.vapi.std.errors_client.Unauthenticated
exception for any exceptions related to the request.com.vmware.vapi.std.errors_client.ServiceUnavailable
exception for all exceptions caused by internal service failure.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(user=None, created_time=None, last_accessed_time=None)
Bases:
VapiStruct
Represents data associated with an API session.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
user (
str
) – Fully qualified name of the end user that created the session, for example Administrator\@vsphere.local. A typical use case for this information is in Graphical User Interfaces (GUI) or logging systems to visualize the identity of the current user.created_time (
datetime.datetime
) – Time when the session was created.last_accessed_time (
datetime.datetime
) – Last time this session was used by passing the session token for invoking an API.
- create()
Creates a session with the API. This is the equivalent of login. This method exchanges user credentials supplied in the security context for a session token that is to be used for authenticating subsequent calls.
To authenticate subsequent calls clients are expected to include the session token. For REST API calls the HTTP
vmware-api-session-id
header field should be used for this.- Return type:
str
- Returns:
Newly created session token to be used for authenticating further requests.
- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the session creation fails due to request specific issues. Due to the security nature of the API the details of the error are not disclosed.Please check the following preconditions if using a SAML token to authenticate:
the supplied token is delegate-able.
the time of client and server system are synchronized.
the token supplied is valid.
if bearer tokens are used check that system configuration allows the API endpoint to accept such tokens.
- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if session creation fails due to server specific issues, for example connection to a back end component is failing. Due to the security nature of this API further details will not be disclosed in the exception. Please refer to component health information, administrative logs and product specific documentation for possible causes.
- delete()
Terminates the validity of a session token. This is the equivalent of log out.
A session token is expected as part of the request.
- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the session id is missing from the request or the corresponding session object cannot be found.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if session deletion fails due to server specific issues, for example connection to a back end component is failing. Due to the security nature of this API further details will not be disclosed in the exception. Please refer to component health information, administrative logs and product specific documentation for possible causes.
- get()
Returns information about the current session. This method expects a valid session token to be supplied.
A side effect of invoking this method may be a change to the session’s last accessed time to the current time if this is supported by the session implementation. Invoking any other method in the API will also update the session’s last accessed time.
This API is meant to serve the needs of various front end projects that may want to display the name of the user. Examples of this include various web based user interfaces and logging facilities.
- Return type:
- Returns:
Information about the session.
- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the session id is missing from the request or the corresponding session object cannot be found.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if session retrieval fails due to server specific issues e.g. connection to back end component is failing. Due to the security nature of this API further details will not be disclosed in the error. Please refer to component health information, administrative logs and product specific documentation for possible causes.
- class com.vmware.cis_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.cis_client.Tasks(config)
Bases:
VapiInterface
The
Tasks
class provides methods for managing the task related to a long running operation. This class was added in vSphere API 6.7.1.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(tasks=None, services=None, operations=None, status=None, targets=None, users=None)
Bases:
VapiStruct
The
Tasks.FilterSpec
class contains attributes used to filter the results when listing tasks (seeTasks.list()
). If multiple attributes are specified, only tasks matching all of the attributes match the filter.Currently at least one of
Tasks.FilterSpec.tasks
orTasks.FilterSpec.services
must be specified and not empty.. This class was added in vSphere API 6.7.1.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
tasks (
set
ofstr
orNone
) – Identifiers of tasks that can match the filter. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.cis.task
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.cis.task
. This attribute may be None ifservices
is specified. Currently all tasks must be from the same provider. If None or empty, tasks with any identifier will match the filter.services (
set
ofstr
orNone
) – Identifiers of services. Tasks created by operations in these services match the filter (seecom.vmware.cis.task_client.CommonInfo.service
). This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vapi.service
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vapi.service
. This attribute may be None iftasks
is specified. Currently all services must be from the same provider. If this attribute is None or empty, tasks for any service will match the filter.operations (
set
ofstr
orNone
) –Identifiers of operations. Tasks created by these operations match the filter (see
com.vmware.cis.task_client.CommonInfo.operation
).Note that an operation identifier by itself is not globally unique. To filter on an operation, the identifier of the service interface containing the operation should also be specified in
services
.. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vapi.operation
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vapi.operation
. If None or empty, tasks associated with any operation will match the filter.status (
set
ofcom.vmware.cis.task_client.Status
orNone
) – Status that a task must have to match the filter (seecom.vmware.cis.task_client.CommonInfo.status
). This attribute was added in vSphere API 6.7.1. If None or empty, tasks with any status match the filter.targets (
list
ofcom.vmware.vapi.std_client.DynamicID
orNone
) – Identifiers of the targets the operation for the associated task created or was performed on (seecom.vmware.cis.task_client.CommonInfo.target
). This attribute was added in vSphere API 6.7.1. If None or empty, tasks associated with operations on any target match the filter.users (
set
ofstr
orNone
) – Users who must have initiated the operation for the associated task to match the filter (seecom.vmware.cis.task_client.CommonInfo.user
). This attribute was added in vSphere API 6.7.1. If None or empty, tasks associated with operations initiated by any user match the filter.
- class GetSpec(return_all=None, exclude_result=None)
Bases:
VapiStruct
The
Tasks.GetSpec
class describes what data should be included when retrieving information about a task. This class was added in vSphere API 6.7.1.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
return_all (
bool
orNone
) – If true, all data, including operation-specific data, will be returned, otherwise only the data described incom.vmware.cis.task_client.Info
will be returned. This attribute was added in vSphere API 6.7.1. If None, only the data described incom.vmware.cis.task_client.Info
will be returned.exclude_result (
bool
orNone
) – If true, the result will not be included in the task information, otherwise it will be included. This attribute was added in vSphere API 6.7.1. If None, the result of the operation will be included in the task information.
- RESOURCE_TYPE = 'com.vmware.cis.task'
Resource type for task. This class attribute was added in vSphere API 6.7.1.
- cancel(task)
Cancel a running operation associated with the task. This is the best effort attempt. Operation may not be cancelled anymore once it reaches certain stage. This method was added in vSphere API 6.7.1.
- Parameters:
task (
str
) – Task identifier. The parameter must be an identifier for the resource type:com.vmware.cis.task
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the task is already canceled or completed.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the task is not found.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the task’s state cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if the task is not cancelable.
- get(task, spec=None)
Returns information about a task. This method was added in vSphere API 6.7.1.
- Parameters:
task (
str
) – Task identifier. The parameter must be an identifier for the resource type:com.vmware.cis.task
.spec (
Tasks.GetSpec
orNone
) – Specification on what to get for a task. If None, the behavior is equivalent to aTasks.GetSpec
with all attributes None which means only the data described incom.vmware.cis.task_client.Info
will be returned and the result of the operation will be return.
- Return type:
- Returns:
Information about the specified task.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the task is not found.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the task’s state cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- list(filter_spec=None, result_spec=None)
Returns information about at most 1000 visible (subject to permission checks) tasks matching the
Tasks.FilterSpec
. All tasks must be in the same provider. This method was added in vSphere API 6.7.1.- Parameters:
filter_spec (
Tasks.FilterSpec
orNone
) – Specification of matching tasks. This is currently required. In the future, if it is None, the behavior is equivalent to aTasks.FilterSpec
with all attributes None which means all tasks match the filter.result_spec (
Tasks.GetSpec
orNone
) – Specification of what to return for a task. If None, the behavior is equivalent to aTasks.GetSpec
with all attributes None which means only the data describe incom.vmware.cis.task_client.Info
will be returned and the result of the operation will be return.
- Return type:
dict
ofstr
andcom.vmware.cis.task_client.Info
- Returns:
Map of task identifier to information about the task. The key in the return value
dict
will be an identifier for the resource type:com.vmware.cis.task
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a task’s state cannot be accessed or over 1000 tasks matching theTasks.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
com.vmware.content_client module
The Content module provides classes and classes for configuring global settings and permissions, and for managing libraries in the Content Library Service.
- class com.vmware.content_client.Configuration(config)
Bases:
VapiInterface
The
Configuration
class provides methods to configure the global settings of the Content Library Service.The configuration settings are used by the Content Library Service to control the behavior of various operations.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- get()
Retrieves the current configuration values.
- Return type:
- Returns:
The
ConfigurationModel
instance representing the configuration of the Content Library Service.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.GetConfiguration
.
- update(model)
Updates the configuration. The update is incremental. Any attribute in the
ConfigurationModel
class that is None will not be modified. Note that this update method doesn’t guarantee an atomic change of all the properties. In the case of a system crash or failure, some of the properties could be left unchanged while others may be updated.- Parameters:
model (
ConfigurationModel
) – TheConfigurationModel
specifying the settings to update.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if one of the configuration properties is not within the proper range.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.UpdateConfiguration
.
- class com.vmware.content_client.ConfigurationModel(automatic_sync_enabled=None, automatic_sync_start_hour=None, automatic_sync_stop_hour=None, maximum_concurrent_item_syncs=None)
Bases:
VapiStruct
The
ConfigurationModel
class defines the global settings of the Content Library Service.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
automatic_sync_enabled (
bool
) –Whether automatic synchronization is enabled.
When automatic synchronization is enabled, the Content Library Service will automatically synchronize all subscribed libraries on a daily basis. Subscribed libraries with the
com.vmware.content.library_client.SubscriptionInfo.automatic_sync_enabled
flag turned on will be synchronized every hour betweenConfigurationModel.automatic_sync_start_hour
andConfigurationModel.automatic_sync_stop_hour
. This attribute is not used for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is optional for theupdate
method.automatic_sync_start_hour (
long
) – The hour at which the automatic synchronization will start. This value is between 0 (midnight) and 23 inclusive. This attribute is not used for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is optional for theupdate
method.automatic_sync_stop_hour (
long
) – The hour at which the automatic synchronization will stop. Any active synchronization operation will continue to run, however no new synchronization operations will be triggered after the stop hour. This value is between 0 (midnight) and 23 inclusive. This attribute is not used for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is optional for theupdate
method.maximum_concurrent_item_syncs (
long
) –The maximum allowed number of library items to synchronize concurrently from remote libraries. This must be a positive number. The service may not be able to guarantee the requested concurrency if there is no available capacity.
This setting is global across all subscribed libraries. This attribute is not used for the
create
method. It will always be present in the return value of theget
orlist
methods. It is optional for theupdate
method.
- class com.vmware.content_client.Library(config)
Bases:
VapiInterface
The
Library
class provides methods to manage and findLibraryModel
entities.The
Library
class provides support for generic functionality which can be applied equally to all types of libraries. The functionality provided by this class will not affect the properties specific to the type of library. See alsoLocalLibrary
andSubscribedLibrary
.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FindSpec(name=None, type=None)
Bases:
VapiStruct
Specifies the properties that can be used as a filter to find libraries. When multiple attributes are specified, all properties of the library must match the specification.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
orNone
) – Name of the library to search. The name is case-insensitive. SeeLibraryModel.name
. If not specified any name will be searched.type (
LibraryModel.LibraryType
orNone
) – Library type to search. SeeLibraryModel.type
. If not specified any library type will be searched.
- RESOURCE_TYPE = 'com.vmware.content.Library'
Resource type for library.
- find(spec)
Returns a list of all the visible (as determined by authorization policy) libraries matching the requested
Library.FindSpec
.- Parameters:
spec (
Library.FindSpec
) – Specification describing what properties to filter on.- Return type:
list
ofstr
- Returns:
The
list
of identifiers of all the visible libraries matching the givenspec
. The return value will contain identifiers for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if no properties are specified in thespec
.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- get(library_id)
Returns a given
LibraryModel
.- Parameters:
library_id (
str
) – Identifier of the library to return. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Return type:
- Returns:
The
LibraryModel
instance with the specifiedlibrary_id
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the specified library does not exist.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresSystem.Read
.
- list()
Returns the identifiers of all libraries of any type in the Content Library.
- Return type:
list
ofstr
- Returns:
The
list
of all identifiers of all libraries in the Content Library. The return value will contain identifiers for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- update(library_id, update_spec)
Updates the properties of a library.
This is an incremental update to the library. Any attribute in the
LibraryModel
class that is None will not be modified.This method will only update the common properties for all library types. This will not, for example, update the
LibraryModel.publish_info
of a local library, nor theLibraryModel.subscription_info
of a subscribed library. Specific properties are updated inLocalLibrary.update()
andSubscribedLibrary.update()
.- Parameters:
library_id (
str
) – Identifier of the library to update. The parameter must be an identifier for the resource type:com.vmware.content.Library
.update_spec (
LibraryModel
) – Specification of the new property values to set on the library.
- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library associated withlibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theupdate_spec
is not valid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theLibraryModel.version
ofupdate_spec
is not equal to the current version of the library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.UpdateLibrary
.
- class com.vmware.content_client.LibraryModel(id=None, creation_time=None, description=None, last_modified_time=None, last_sync_time=None, name=None, storage_backings=None, type=None, optimization_info=None, version=None, publish_info=None, subscription_info=None, server_guid=None, security_policy_id=None, unset_security_policy_id=None)
Bases:
VapiStruct
The
LibraryModel
class represents a Content Library resource model.A
LibraryModel
is a container for a set of items which represent a usable set of files. The Content Library Service allows for multiple libraries to be created with separate authorization and sharing policies.Each
LibraryModel
is a container for a set ofcom.vmware.content.library_client.ItemModel
instances. Each item is a logical object in a library, which may have multiple files.A
LibraryModel
may be local or subscribed. A local library has its source of truth about items within this Content Library Service. Items may be added to or removed from the library. A local library may also be private or published. When published, the library is exposed by a network endpoint and can be used by another Content Library Service for synchronization. A private local library cannot be used for synchronization.A subscribed library is a library which gets its source of truth from another library that may be across a network in another Content Library Service. A subscribed library may have a different name and metadata from the library to which it subscribes, but the set of library items is always the same as those in the source library. Library items cannot be manually added to a subscribed library – they can only be added by adding new items to the source library.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – An identifier which uniquely identifies thisLibraryModel
. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.Library
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.Library
. This attribute is not used for thecreate
method. It will not be present in the return value of theget
orlist
methods. It is not used for theupdate
method.creation_time (
datetime.datetime
) – The date and time when this library was created. This attribute is not used for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is not used for theupdate
method.description (
str
) – A human-readable description for this library. This attribute is optional for thecreate
method. Leaving it None during creation will result in an empty string value. It will always be present in the result of aget
orlist
method. It is optional for theupdate
method. Leaving it None during update indicates that the description should be left unchanged.last_modified_time (
datetime.datetime
) –The date and time when this library was last updated.
This attribute is updated automatically when the library properties are changed. This attribute is not affected by adding, removing, or modifying a library item or its content within the library. Tagging the library or syncing the subscribed library does not alter this attribute. This attribute is not used for the
create
method. It will always be present in the return value of theget
orlist
methods. It is not used for theupdate
method.last_sync_time (
datetime.datetime
) –The date and time when this library was last synchronized.
This attribute applies only to subscribed libraries. It is updated every time a synchronization is triggered on the library. The value is None for a local library. This attribute is not used for the
create
method. It is optional in the return value of theget
orlist
methods. It is not used for theupdate
method.name (
str
) –The name of the library.
A Library is identified by a human-readable name. Library names cannot be undefined or an empty string. Names do not have to be unique. This attribute must be provided for the
create
method. It will always be present in the return value of theget
orlist
methods. It is optional for theupdate
method.storage_backings (
list
ofcom.vmware.content.library_client.StorageBacking
) –The list of default storage backings which are available for this library.
A
com.vmware.content.library_client.StorageBacking
defines a default storage location which can be used to store files for library items in this library. Some library items, for instance, virtual machine template items, support files that may be distributed across various storage backings. One or more item files may or may not be located on the default storage backing.Multiple default storage locations are not currently supported but may become supported in future releases. This attribute must be provided for the
create
method. It will always be present in the return value of theget
orlist
methods. It is not used for theupdate
method.type (
LibraryModel.LibraryType
) –The type (LOCAL, SUBSCRIBED) of this library.
This value can be used to determine what additional services and information can be available for this library. This attribute is not used for the
create
andupdate
methods. It will always be present in the result of aget
method. This attribute is not used for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is not used for theupdate
method.optimization_info (
com.vmware.content.library_client.OptimizationInfo
) – Defines various optimizations and optimization parameters applied to this library. This attribute is optional for thecreate
method. It is optional in the return value of theget
orlist
methods. It is optional for theupdate
method.version (
str
) –A version number which is updated on metadata changes. This value allows clients to detect concurrent updates and prevent accidental clobbering of data.
This value represents a number which is incremented every time library properties, such as name or description, are changed. It is not incremented by changes to a library item within the library, including adding or removing items. It is also not affected by tagging the library. This attribute is not used for the
create
method. It will always be present in the result of aget
orlist
method. It is optional for theupdate
method. Leaving it None during update indicates that you do not need to detect concurrent updates.publish_info (
com.vmware.content.library_client.PublishInfo
) –Defines how this library is published so that it can be subscribed to by a remote subscribed library.
The
com.vmware.content.library_client.PublishInfo
defines where and how the metadata for this local library is accessible. A local library is only published publically ifcom.vmware.content.library_client.PublishInfo.published
istrue
. This attribute is optional for thecreate
andupdate
methods. If not specified during creation, the default is for the library to not be published. If not specified during update, the attribute is left unchanged.subscription_info (
com.vmware.content.library_client.SubscriptionInfo
) –Defines the subscription behavior for this Library.
The
com.vmware.content.library_client.SubscriptionInfo
defines how this subscribed library synchronizes to a remote source. Setting the value will determine the remote source to which the library synchronizes, and how. Changing the subscription will result in synchronizing to a new source. If the new source differs from the old one, the old library items and data will be lost. Settingcom.vmware.content.library_client.SubscriptionInfo.automatic_sync_enabled
to false will halt subscription but will not remove existing cached data. This attribute is optional for thecreate
andupdate
methods. If not specified during creation, a default will be created without an active subscription. If not specified during update, the attribute is left unchanged.server_guid (
str
) – The unique identifier of the vCenter server where the library exists. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.VCenter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.VCenter
. This attribute is optional for thecreate
method. It will always be present in the return value of theget
orlist
methods. It is not used for theupdate
method.security_policy_id (
str
orNone
) –Represents the security policy applied to this library.
Setting the attribute will make the library secure. This field is ignored in
update
method ifLibraryModel.unset_security_policy_id
is set totrue
.. 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.content.Library
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.Library
. This attribute is optional for thecreate
andupdate
methods. If not set increate
method, the library will be insecure. If not specified inupdate
method, the attribute is left unchanged.unset_security_policy_id (
bool
) –This represents the intent of the change to
LibraryModel.security_policy_id
inupdate
method.If this field is set to
true
, any security policy applied to the library will be removed. If this field is set tofalse
, any security policy applied to library will be changed to the value specified inLibraryModel.security_policy_id
, if any.. This attribute was added in vSphere API 7.0.3.0. This attribute is optional for theupdate
method. If None, any existing security policy will be changed to the value specified inLibraryModel.security_policy_id
, if any.
- class LibraryType(string)
Bases:
Enum
The
LibraryModel.LibraryType
class defines the type of aLibraryModel
.The type of a library can be used to determine which additional services can be performed with a library.
Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theLibraryType
instance.
- LOCAL = LibraryType(string='LOCAL')
The library contents are defined and stored by the local Content Library Service installation.
A local library can be retrieved and managed via the
LocalLibrary
.
- SUBSCRIBED = LibraryType(string='SUBSCRIBED')
The library synchronizes its items and content from another published library.
A subscribed library can be retrieved and managed via the
SubscribedLibrary
.
- class com.vmware.content_client.LocalLibrary(config)
Bases:
VapiInterface
The
LocalLibrary
class manages local libraries.The
LocalLibrary
class provides support for creating and maintaining local library instances. A local library may also use theLibrary
class to manage general library functionality.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class DestinationSpec(subscription=None)
Bases:
VapiStruct
The
LocalLibrary.DestinationSpec
class contains information required to publish the library to a specific subscription. This class was added in vSphere API 6.7.2.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
subscription (
str
) – Identifier of the subscription associated with the subscribed library. This attribute was added in vSphere API 6.7.2. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.content.library.Subscriptions
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.library.Subscriptions
.
- create(create_spec, client_token=None)
Creates a new local library.
- Parameters:
client_token (
str
orNone
) – A unique token generated on the client for each creation request. The token should be a universally unique identifier (UUID), for example:b8a2a2e3-2314-43cd-a871-6ede0f429751
. This token can be used to guarantee idempotent creation. If not specified creation is not idempotent.create_spec (
LibraryModel
) – Specification for the new local library.
- Return type:
str
- Returns:
Identifier of the newly created
LibraryModel
. The return value will be an identifier for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if thecreate_spec
is not valid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theclient_token
does not conform to the UUID format.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if using multiple storage backings.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.CreateLocalLibrary
.The resource
Datastore
referenced by the attributecom.vmware.content.library_client.StorageBacking.datastore_id
requiresDatastore.AllocateSpace
.
- delete(library_id)
Deletes the specified local library.
Deleting a local library will remove the entry immediately and begin an asynchronous task to remove all cached content for the library. If the asynchronous task fails, file content may remain on the storage backing. This content will require manual removal.
- Parameters:
library_id (
str
) – Identifier of the local library to delete. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a local library.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the library contains a library item that cannot be deleted in its current state. For example, the library item contains a virtual machine template and a virtual machine is checked out of the library item.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.DeleteLocalLibrary
.
- get(library_id)
Returns a given local library.
- Parameters:
library_id (
str
) – Identifier of the local library to return. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Return type:
- Returns:
The
LibraryModel
instance associated withlibrary_id
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a local library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresSystem.Read
.
- list()
Returns the identifiers of all local libraries in the Content Library.
- Return type:
list
ofstr
- Returns:
The
list
of identifiers of all local libraries in the Content Library. The return value will contain identifiers for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- publish(library_id, subscriptions=None)
Publishes the library to specified subscriptions. If no subscriptions are specified, then publishes the library to all its subscriptions. This method was added in vSphere API 6.7.2.
- Parameters:
library_id (
str
) – Identifier of the published library. The parameter must be an identifier for the resource type:com.vmware.content.Library
.subscriptions (
list
ofLocalLibrary.DestinationSpec
orNone
) – The list of subscriptions to publish this library to.
- Raise:
com.vmware.vapi.std.errors_client.Error
If the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
If one or moresubscriptions
is not valid.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
If the library specified bylibrary_id
is a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
If the library specified bylibrary_id
is not a published library.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user that requested the method cannot be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user that requested the method is not authorized to perform the method.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.PublishLibrary
.
- update(library_id, update_spec)
Updates the properties of a local library.
This is an incremental update to the local library. Attributes that are None in the update specification will be left unchanged.
- Parameters:
library_id (
str
) – Identifier of the local library to update. The parameter must be an identifier for the resource type:com.vmware.content.Library
.update_spec (
LibraryModel
) – Specification of the new property values to set on the local library.
- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the library specified bylibrary_id
is a published library with JSON persistence enabled (seecom.vmware.content.library_client.PublishInfo.persist_json_enabled
) and the content of the library has been deleted from the storage backings (seeLibraryModel.storage_backings
) associated with it.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a local library.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theupdate_spec
is not valid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if thecom.vmware.content.library_client.PublishInfo.current_password
in theupdate_spec
does not match the existing password of the published library.- Raise:
com.vmware.vapi.std.errors_client.ResourceBusy
if theLibraryModel.version
ofupdate_spec
is None and the library is being concurrently updated by another user.- Raise:
com.vmware.vapi.std.errors_client.ConcurrentChange
if theLibraryModel.version
ofupdate_spec
is not equal to the current version of the library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.UpdateLocalLibrary
.
- class com.vmware.content_client.SecurityPolicies(config)
Bases:
VapiInterface
The
SecurityPolicies
class provides methods to manage security policies. A policy can be applied to a content library. This class was added in vSphere API 7.0.3.0.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(policy=None, name=None, item_type_rules=None)
Bases:
VapiStruct
Representation of a security policy. 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:
policy (
str
) – Identifier of the security policy. 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.content.SecurityPolicy
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.SecurityPolicy
.name (
str
) – Name of the security policy. This attribute was added in vSphere API 7.0.3.0.item_type_rules (
dict
ofstr
andSecurityRuleType
) – Map of content library item type and rule types The rules can be associated with a security policy. When the security policy is applied to a content library, these rules will be used to validate specific item type. This attribute was added in vSphere API 7.0.3.0.
- RESOURCE_TYPE = 'com.vmware.content.SecurityPolicy'
Resource type for security policies. This class attribute was added in vSphere API 7.0.3.0.
- list()
Returns the list of security policies. This method was added in vSphere API 7.0.3.0.
- Return type:
- Returns:
List of security policies.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- class com.vmware.content_client.SecurityRuleType(string)
Bases:
Enum
The
SecurityRuleType
class defines the security rules which can be applied to different item types. This enumeration was added in vSphere API 7.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 theSecurityRuleType
instance.
- OVF_STRICT_VERIFICATION = SecurityRuleType(string='OVF_STRICT_VERIFICATION')
This rule indicates that an OVF/OVA item can only be imported or synced to a content library if its certificate is valid and signed by a trusted CA. This class attribute was added in vSphere API 7.0.3.0.
- class com.vmware.content_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.content_client.SubscribedLibrary(config)
Bases:
VapiInterface
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ProbeResult(status=None, ssl_thumbprint=None, error_messages=None)
Bases:
VapiStruct
The
SubscribedLibrary.ProbeResult
class defines the subscription information probe result. This describes whether using a given subscription URL is successful or if there are access problems, such as SSL errors.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
status (
SubscribedLibrary.ProbeResult.Status
) – The status of probe result. This will be one of SUCCESS, INVALID_URL, TIMED_OUT, HOST_NOT_FOUND, RESOURCE_NOT_FOUND, INVALID_CREDENTIALS, CERTIFICATE_ERROR, UNKNOWN_ERROR.ssl_thumbprint (
str
orNone
) – The SSL thumbprint for the remote endpoint. A SSL thumbprint is only returned if the host is secured with SSL/TLS.error_messages (
list
ofcom.vmware.vapi.std_client.LocalizableMessage
) – If the probe result is in an error status, this attribute will contain the detailed error messages.
- class Status(string)
Bases:
Enum
The
SubscribedLibrary.ProbeResult.Status
class defines the error status constants for the probe result.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theStatus
instance.
- CERTIFICATE_ERROR = Status(string='CERTIFICATE_ERROR')
Indicates that the provided server certificate in
com.vmware.content.library_client.SubscriptionInfo.ssl_thumbprint
is invalid. In this case, the returned #sslThumbprint should be set incom.vmware.content.library_client.SubscriptionInfo.ssl_thumbprint
.
- HOST_NOT_FOUND = Status(string='HOST_NOT_FOUND')
Indicates that the host in the URL could not be found.
- INVALID_CREDENTIALS = Status(string='INVALID_CREDENTIALS')
Indicates that the connection was rejected due to invalid credentials.
- INVALID_URL = Status(string='INVALID_URL')
Indicates that the supplied URL was not valid.
- RESOURCE_NOT_FOUND = Status(string='RESOURCE_NOT_FOUND')
Indicates that the given resource at the URL was not found.
- SUCCESS = Status(string='SUCCESS')
Indicates that the probe was successful.
- TIMED_OUT = Status(string='TIMED_OUT')
Indicates that the probe timed out while attempting to connect to the URL.
- UNKNOWN_ERROR = Status(string='UNKNOWN_ERROR')
Indicates an unspecified error different from the other error cases defined in
SubscribedLibrary.ProbeResult.Status
.
- create(create_spec, client_token=None)
Creates a new subscribed library.
Once created, the subscribed library will be empty. If the
LibraryModel.subscription_info
property is set, the Content Library Service will attempt to synchronize to the remote source. This is an asynchronous operation so the content of the published library may not immediately appear.- Parameters:
client_token (
str
orNone
) – Unique token generated on the client for each creation request. The token should be a universally unique identifier (UUID), for example:b8a2a2e3-2314-43cd-a871-6ede0f429751
. This token can be used to guarantee idempotent creation. If not specified creation is not idempotent.create_spec (
LibraryModel
) – Specification for the new subscribed library.
- Return type:
str
- Returns:
Identifier of the newly created subscribed library. The return value will be an identifier for the resource type:
com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if thecreate_spec
is not valid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theclient_token
does not conform to the UUID format.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if using multiple storage backings.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if subscribing to a published library which cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.CreateSubscribedLibrary
.The resource
Datastore
referenced by the attributecom.vmware.content.library_client.StorageBacking.datastore_id
requiresDatastore.AllocateSpace
.
- delete(library_id)
Deletes the specified subscribed library.
Deleting a subscribed library will remove the entry immediately and begin an asynchronous task to remove all cached content for the library. If the asynchronous task fails, file content may remain on the storage backing. This content will require manual removal.
- Parameters:
library_id (
str
) – Identifier of the subscribed library to delete. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library referenced bylibrary_id
is not a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library referenced bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.DeleteSubscribedLibrary
.
- evict(library_id)
Evicts the cached content of an on-demand subscribed library.
This method allows the cached content of a subscribed library to be removed to free up storage capacity. This method will only work when a subscribed library is synchronized on-demand.
- Parameters:
library_id (
str
) – Identifier of the subscribed library whose content should be evicted. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the library specified bylibrary_id
does not synchronize on-demand, or if the content of the library specified bylibrary_id
has been deleted from the storage backings (seeLibraryModel.storage_backings
) associated with it.For instance, this {\@term error) is reported on evicting an on-demand subscribed library that was restored from backup, and the library was deleted after the backup was taken, thus resulting in its content being deleted from the associated storage backings. In this scenario, the metadata of the library is present on a restore, while its content has been deleted.
- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.EvictSubscribedLibrary
.
- get(library_id)
Returns a given subscribed library.
- Parameters:
library_id (
str
) – Identifier of the subscribed library to return. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Return type:
- Returns:
The
LibraryModel
instance that corresponds tolibrary_id
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library associated withlibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library associated withlibrary_id
is not a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresSystem.Read
.
- list()
Returns the identifiers of all subscribed libraries in the Content Library.
- Return type:
list
ofstr
- Returns:
The
list
of identifiers of all subscribed libraries in the Content Library. The return value will contain identifiers for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- probe(subscription_info)
Probes remote library subscription information, including URL, SSL certificate and password. The resulting
SubscribedLibrary.ProbeResult
class describes whether or not the subscription configuration is successful.- Parameters:
subscription_info (
com.vmware.content.library_client.SubscriptionInfo
) – The subscription info to be probed.- Return type:
- Returns:
The subscription info probe result.
- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.ProbeSubscription
.
- sync(library_id)
Forces the synchronization of the subscribed library.
Synchronizing a subscribed library forcefully with this method will perform the same synchronization behavior as would run periodically for the library. The
com.vmware.content.library_client.SubscriptionInfo.on_demand
setting is respected. Calling this method on a library that is already in the process of synchronizing will have no effect.- Parameters:
library_id (
str
) – Identifier of the subscribed library to synchronize. The parameter must be an identifier for the resource type:com.vmware.content.Library
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the content of the library specified bylibrary_id
has been deleted from the storage backings (seeLibraryModel.storage_backings
) associated with it.For instance, this {\@term error) is reported on synchronizing a subscribed library that was restored from backup, and the library was deleted after the backup was taken, thus resulting in its content being deleted from the associated storage backings. In this scenario, the metadata of the library is present on a restore, while its content has been deleted.
- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if some parameter in the subscribed library subscription info is invalid.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the published library cannot be contacted or found.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.SyncLibrary
.
- update(library_id, update_spec)
Updates the properties of a subscribed library.
This is an incremental update to the subscribed library. Attributes that are None in the update specification will be left unchanged.
- Parameters:
library_id (
str
) – Identifier of the subscribed library to update. The parameter must be an identifier for the resource type:com.vmware.content.Library
.update_spec (
LibraryModel
) – Specification of the new property values to set on the subscribed library.
- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the library specified bylibrary_id
does not exist.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if theupdate_spec
updates the subscription URL (seecom.vmware.content.library_client.SubscriptionInfo.subscription_url
) and the content of the library specified bylibrary_id
has been deleted from the storage backings (seeLibraryModel.storage_backings
) associated with it.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the library specified bylibrary_id
is not a subscribed library.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theupdate_spec
is not valid.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the subscription info is being updated but the published library cannot be contacted or found.- Raise:
com.vmware.vapi.std.errors_client.ResourceBusy
if theLibraryModel.version
ofupdate_spec
is None and the library is being concurrently updated by another user.- Raise:
com.vmware.vapi.std.errors_client.ConcurrentChange
if theLibraryModel.version
ofupdate_spec
is not equal to the current version of the library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.Library
referenced by the parameterlibrary_id
requiresContentLibrary.UpdateSubscribedLibrary
.
- class com.vmware.content_client.TrustedCertificates(config)
Bases:
VapiInterface
The
TrustedCertificates
class provides methods to create, modify, delete and read trusted certificates. This class was added in vSphere API 7.0.3.0.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class CreateSpec(cert_text=None)
Bases:
VapiStruct
The
TrustedCertificates.CreateSpec
class is the specification used to create a trusted certificate, seeTrustedCertificates.create()
. 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:
cert_text (
str
) – A certText is the certificate in Base64 encoded PEM format. The input must be a single line string with escape sequence for new-lines. This attribute was added in vSphere API 7.0.3.0.
- class Info(cert_text=None)
Bases:
VapiStruct
The
TrustedCertificates.Info
class contains a trusted certificate. 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:
cert_text (
str
) – A certificate in Base64 encoding. This attribute was added in vSphere API 7.0.3.0.
- class ListResult(certificates=None)
Bases:
VapiStruct
The
TrustedCertificates.ListResult
class contains list of Summary of the trusted certificates, seeTrustedCertificates.list()
. 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:
certificates (
list
ofTrustedCertificates.Summary
) – List of certificates. This attribute was added in vSphere API 7.0.3.0.
- RESOURCE_TYPE = 'com.vmware.content.TrustedCertificate'
Resource type for trusted certificates. This class attribute was added in vSphere API 7.0.3.0.
- class Summary(certificate=None, cert_text=None)
Bases:
VapiStruct
The
TrustedCertificates.Summary
class contains a trusted certificate summary. 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:
certificate (
str
) – Unique identifier for the certificate. It is the TrustStore alias of the certificate. The alias is the SHA256 hash of the raw certificate data. 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.content.TrustedCertificate
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.content.TrustedCertificate
.cert_text (
str
) – Certificate in Base64 encoded PEM format.. This attribute was added in vSphere API 7.0.3.0.
- create(spec)
Adds a certificate to content library trust store.
This API has to be invoked separately for each certificate block - (BEGIN_CERTIFICATE … END_CERTIFICATE). This method was added in vSphere API 7.0.3.0.
- Parameters:
spec (
TrustedCertificates.CreateSpec
) – Specification for the certificate to be added to content library trust store.- Return type:
str
- Returns:
ID of the certificates added. The certificate ID will be unique for each certificate. If the certificate already exists, existing ID is returned. The return value will be an identifier for the resource type:
com.vmware.content.TrustedCertificate
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.AddCertToTrustStore
.
- delete(certificate)
Deletes the trusted certificate from content library’s trust store for a given identifier. This method was added in vSphere API 7.0.3.0.
- Parameters:
certificate (
str
) – id of the trusted certificate. The parameter must be an identifier for the resource type:com.vmware.content.TrustedCertificate
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the trusted certificate specified bycertificate
could not be found.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.TrustedCertificate
referenced by the parametercertificate
requiresContentLibrary.DeleteCertFromTrustStore
.
- get(certificate)
Retrieves a trusted certificate for a given certificate id. This method was added in vSphere API 7.0.3.0.
- Parameters:
certificate (
str
) – id of the trusted certificate. The parameter must be an identifier for the resource type:com.vmware.content.TrustedCertificate
.- Return type:
- Returns:
TrustedCertificates.Info
instance that corresponds to thecertificate
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if a trusted certificate does not exist for given id.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
com.vmware.content.TrustedCertificate
referenced by the parametercertificate
requiresSystem.Read
.
- list()
Returns
TrustedCertificates.ListResult
class. All content library’s trusted certificates. This method was added in vSphere API 7.0.3.0.- Return type:
- Returns:
TrustedCertificates.ListResult
containing trusted certificates.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
System.Read
.
- class com.vmware.content_client.Type(config)
Bases:
VapiInterface
The
Type
class exposes thecom.vmware.content.library_client.ItemModel
types that this Content Library Service supports.A library item has an optional type which can be specified with the
com.vmware.content.library_client.ItemModel.type
attribute. For items with a type that is supported by a plugin, the Content Library Service may understand the files which are part of the library item and can produce metadata for the item.In other cases, uploads may require a process in which one upload implies subsequent uploads. For example, an Open Virtualization Format (OVF) package is composed of an OVF descriptor file and the associated virtual disk files. Uploading an OVF descriptor can enable the Content Library Service to understand that the complete OVF package requires additional disk files, and it can set up the transfers for the disks automatically by adding the file entries for the disks when the OVF descriptor is uploaded.
When a type is not supported by a plugin, or the type is not specified, the Content Library Service can handle a library item in a default way, without adding metadata to the item or guiding the upload process.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(description=None, name=None, type=None, vendor=None, version=None, supported_rules=None)
Bases:
VapiStruct
The
Type.Info
class describes support for a specific type of data in ancom.vmware.content.library_client.ItemModel
. TheType.Info
can be queried through theType
class. Type support describes plugins in the Content Library which can provide metadata on library items and help manage the transfer process by adding dependent files when a current file is added.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
description (
str
) – A description of the type support offered by the plugin.name (
str
) – The name of the plugin which provides the type support.type (
str
) –The type which the plugin supports.
To upload a library item of the type supported by the plugin, the
com.vmware.content.library_client.ItemModel.type
attribute of the item should be set to this value.vendor (
str
) – The name of the vendor who created the type support plugin.version (
str
) – The version number of the type support plugin.supported_rules (
list
ofSecurityRuleType
orNone
) – List of security rules which can be applied to this item type. This attribute was added in vSphere API 7.0.3.0. If None no security rule can be associated with this item type.
- list()
Returns a
list
ofType.Info
instances which describe the type support plugins in a Content Library.- Return type:
- Returns:
The
list
ofType.Info
instances which describe the type support plugins in a Content Library.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:Method execution requires
ContentLibrary.TypeIntrospection
.
com.vmware.esx_client module
The com.vmware.esx_client
module provides classes to manage ESX.
- class com.vmware.esx_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
com.vmware.oauth2_client module
The com.vmware.oauth2_client
module contains classes for reuse by OAuth2
API definitions.
- class com.vmware.oauth2_client.Constants
Bases:
VapiStruct
Constants defined in RFC 6749 and RFC 8693.
Tip
The arguments are used to initialize data attributes with the same names.
- ACCESS_TOKEN_TYPE = 'urn:ietf:params:oauth:token-type:access_token'
Token type URI for an OAuth 2.0 access token
- ID_TOKEN_TYPE = 'urn:ietf:params:oauth:token-type:id_token'
Token type URI for an ID Token
- PASSWORD_GRANT = 'password'
Resource Owner Password Credentials grant type for OAuth 2.0. This class attribute was added in vSphere API 8.0.3.0.
- REFRESH_TOKEN_TYPE = 'urn:ietf:params:oauth:token-type:refresh_token'
Token type URI for an OAuth 2.0 refresh token
- SAML2_TOKEN_TYPE = 'urn:ietf:params:oauth:token-type:saml2'
Token type URI for a base64url-encoded SAML 2.0
- TOKEN_EXCHANGE_GRANT = 'urn:ietf:params:oauth:grant-type:token-exchange'
Token exchange grant type for OAuth 2.0
- class com.vmware.oauth2_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.oauth2_client.TokenInfo(access_token=None, token_type=None, expires_in=None, scope=None, refresh_token=None, issued_token_type=None)
Bases:
VapiStruct
The
TokenInfo
class contains data that represents successful access-token response as defined in RFC 6749 and extended in RFC 8693.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
access_token (
str
) – The access token issued by the authorization server.token_type (
str
) – A case-insensitive value specifying the method of using the access token issued.expires_in (
long
orNone
) – The validity lifetime, in seconds, of the token issued by the server. None if not applicable for issued token.scope (
str
orNone
) – Scope of the issued access token. The value of the scope parameter is expressed as a list of space- delimited, case-sensitive strings. The strings are defined by the authorization server. If the value contains multiple space-delimited strings, their order does not matter, and each string adds an additional access range to the requested scope. None if the scope of the issued security token is identical to the scope requested by the client.refresh_token (
str
orNone
) – The refresh token, which can be used to obtain new access tokens. None if not applicable to the specific request.issued_token_type (
str
orNone
) – An identifier which indicates the type of the access token in theTokenInfo.access_token
attribute. None if not the result of a token-exchange invocation; otherwise, required.
- BEARER_TOKEN_METHOD_TYPE = 'Bearer'
Class attribute indicating that the security token is a bearer token.
- class com.vmware.oauth2_client.TokenResult(access_token=None, token_type=None, expires_in=None, scope=None, refresh_token=None, issued_token_type=None)
Bases:
VapiStruct
The
TokenResult
class contains data that represents successful access-token response as defined in RFC 6749 and extended in RFC 8693. 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:
access_token (
str
) – The access token issued by the authorization server. This attribute was added in vSphere API 8.0.3.0.token_type (
str
) – A case-insensitive value specifying the method of using the access token issued. This attribute was added in vSphere API 8.0.3.0.expires_in (
long
orNone
) – The validity lifetime, in seconds, of the token issued by the server. This attribute was added in vSphere API 8.0.3.0. None if not applicable for issued token.scope (
str
orNone
) –Scope of the issued access token.
The value of the scope parameter is expressed as a list of space- delimited, case-sensitive strings. The strings are defined by the authorization server. If the value contains multiple space-delimited strings, their order does not matter, and each string adds an additional access range to the requested scope.. This attribute was added in vSphere API 8.0.3.0. None if the scope of the issued security token is identical to the scope requested by the client.
refresh_token (
str
orNone
) – The refresh token, which can be used to obtain new access tokens. This attribute was added in vSphere API 8.0.3.0. None if not applicable to the specific request.issued_token_type (
str
orNone
) – An identifier which indicates the type of the access token in theTokenResult.access_token
attribute. This attribute was added in vSphere API 8.0.3.0. None if not the result of a token-exchange invocation; otherwise, required.
- BEARER_TOKEN_METHOD_TYPE = 'Bearer'
Class attribute indicating that the security token is a bearer token. This class attribute was added in vSphere API 8.0.3.0.
com.vmware.snapservice_client module
The com.vmware.snapservice_client
module provides classes for configuring
and managing vSAN protection groups and snapshots
- class com.vmware.snapservice_client.ProtectionGroupInfo(name=None, status=None, target_entities=None, snapshot_policies=None, last_snapshot_time=None, oldest_snapshot_time=None, vms=None, snapshots=None, locked=None)
Bases:
VapiStruct
The
ProtectionGroupInfo
class contains attributes that provide detailed information regarding the protection group and the snapshot policies associated with it.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name of the protection group.status (
ProtectionGroupStatus
) – Current status of the protection group.target_entities (
TargetEntities
) – User provided target entities that must belong to the protection group.snapshot_policies (
list
ofSnapshotPolicy
) – Snapshot policies for the protection targets.last_snapshot_time (
datetime.datetime
orNone
) – Time at which the last protection group snapshot was taken. is None if there are no snapshots taken for the protection group.oldest_snapshot_time (
datetime.datetime
orNone
) – Time at which the current oldest protection group snapshot was taken. is None if there are no snapshots taken for the protection group.vms (
set
ofstr
) – List of virtual machines that belong to the protection group. This is a combined list of virtual machines from the dynamic vm name and the individual list of virtual machines specified during creation of the prtection group. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:VirtualMachine
.snapshots (
set
ofstr
) – List of snapshots taken for the protection group. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.snapservice.protection_group.snapshot
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.snapservice.protection_group.snapshot
.locked (
bool
) – Indicates if the protection group is to be locked. A locked protection group cannot be modified or deleted by the user. All snapshots associated with the protection group will be secure and cannot be deleted. The system will automatically delete these snapshots upon expiry based on the retention period
- class com.vmware.snapservice_client.ProtectionGroupSpec(name=None, target_entities=None, snapshot_policies=None, locked=None)
Bases:
VapiStruct
The
ProtectionGroupSpec
class contains attributes that describe the desired protection group and the snapshot policies associated with it. A protection group is a group of entities that vSAN Snapshot Service protects together.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name of the protection group.target_entities (
TargetEntities
) – Target entities for the protection.snapshot_policies (
list
ofSnapshotPolicy
orNone
) – Snapshot policy for the protection targets. if None local protection will be skipped.locked (
bool
orNone
) – Indicates if the protection group is to be locked. A locked protection group cannot be modified or deleted by the user. All snapshots associated with the protection group will be secure and cannot be deleted. The system will automatically delete these snapshots upon expiry based on the retention period. if None the protection group will be considered as unlocked.
- class com.vmware.snapservice_client.ProtectionGroupStatus(string)
Bases:
Enum
The
ProtectionGroupStatus
class contains the different states for the protection group. Does the status need to be specifically for snapshots? Are there other operations we will support for the Protection Group?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 theProtectionGroupStatus
instance.
- ACTIVE = ProtectionGroupStatus(string='ACTIVE')
Active
- MARKED_FOR_DELETE = ProtectionGroupStatus(string='MARKED_FOR_DELETE')
Marked for delete,
Indicates that the PG is soft deleted but has some PG snapshots and VM snapshots which are not yet expired.
- PAUSED = ProtectionGroupStatus(string='PAUSED')
Paused
- class com.vmware.snapservice_client.ProtectionGroupUpdateSpec(name=None, target_entities=None, snapshot_policies=None)
Bases:
VapiStruct
The
ProtectionGroupUpdateSpec
class contains attributes that describe the desired protection group and the snapshot policies associated with it. A protection group is a group of entities that vSAN Snapshot Service protects together.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
orNone
) – Name of the protection group. if None, the current proteciton group name will be retained.target_entities (
TargetEntities
orNone
) – Target entities for the protection. Ifset
, this will represent all the target entities for the protection group. if None, the existing target entities will be retained.snapshot_policies (
list
ofSnapshotPolicy
orNone
) – Snapshot policy for the protection targets. Ifset
, this will represent all the snapshot policies for the protection group. Any existing policies will be removed, if not specified in the new list. if None, existing snapshot policies will be retained.
- class com.vmware.snapservice_client.RetentionPeriod(unit=None, duration=None)
Bases:
VapiStruct
The
RetentionPeriod
class contains attributes that define the duration for which each snapshot must be retained.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
unit (
TimeUnit
) – Units for the retention periodduration (
long
) – Duration for the snapshot to be retained
- class com.vmware.snapservice_client.SnapshotPolicy(name=None, schedule=None, retention=None)
Bases:
VapiStruct
The
SnapshotPolicy
class contains attributes that describe the frequency and retention for taking snapshots of the protection targets.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name for the snapshot policy.schedule (
SnapshotSchedule
) – Schedule for the snapshots.retention (
RetentionPeriod
) – Retention period for the snapshots.
- class com.vmware.snapservice_client.SnapshotSchedule(unit=None, interval=None)
Bases:
VapiStruct
The
SnapshotSchedule
class contains attributes that define the frequency at which snapshots must be taken.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
unit (
TimeUnit
) – Units for the interval.interval (
long
) – Interval between each snapshot.
- class com.vmware.snapservice_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.snapservice_client.TargetEntities(vm_name_patterns=None, vms=None)
Bases:
VapiStruct
The
TargetEntities
class contains attributes specifying the target entities to be protected. The initial release will only support virtual machines.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
vm_name_patterns (
list
ofstr
orNone
) –One or more match patterns for virtual machines to be protected.
Uses standard POSIX Shell globbing pattern. See also, the POSIX Shell language: http://pubs.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html#tag_02_13_01 If None,
TargetEntities.vms
must be specified.vms (
set
ofstr
orNone
) – List of virtual machines to be protected. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:VirtualMachine
. If None, the virtual machines to be protected will be determined based on theTargetEntities.vm_name_patterns
.
- class com.vmware.snapservice_client.Tasks(config)
Bases:
VapiInterface
The
Tasks
class provides methods for managing the tasks related to long running operations.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(tasks=None, operations=None, services=None, status=None, users=None)
Bases:
VapiStruct
The
Tasks.FilterSpec
class contains attributes used to filter the results when listing tasks (seeTasks.list()
). If multiple attributes are specified, only tasks matching all of the attributes match the filter.Currently at least one of
Tasks.FilterSpec.tasks
orTasks.FilterSpec.services
must be specified and not empty.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
tasks (
set
ofstr
orNone
) – Identifiers of tasks that can 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.snapservice.task
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.snapservice.task
. This attribute may be None if other filters are specified. If None or empty, tasks with any identifier will match the filter.operations (
set
ofstr
orNone
) – Identifiers of operations. Tasks created by these operations match the filter (seecom.vmware.snapservice.tasks_client.CommonInfo.operation
). When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.snapservice.operation
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.snapservice.operation
. If None or empty, tasks associated with any operation will match the filter.services (
set
ofstr
orNone
) – Identifiers of services. Tasks created by operations in these services match the filter (seecom.vmware.snapservice.tasks_client.CommonInfo.service
). When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.snapservice.service
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.snapservice.service
. This attribute may be None iftasks
is specified. If this attribute is None or empty, tasks for any service will match the filter.status (
set
ofcom.vmware.snapservice.tasks_client.Status
orNone
) – Status that a task must have to match the filter (seecom.vmware.snapservice.tasks_client.CommonInfo.status
). If None or empty, tasks with any status match the filter.users (
set
ofstr
orNone
) – Users who must have initiated the operation for the associated task to match the filter (seecom.vmware.snapservice.tasks_client.CommonInfo.user
). If None or empty, tasks associated with operations initiated by any user match the filter.
- class ListItem(task=None, info=None)
Bases:
VapiStruct
The
Tasks.ListItem
class contains information about a task returned byTasks.list()
methodTip
The arguments are used to initialize data attributes with the same names.
- Parameters:
task (
str
) – Identifier of the task for which this entry belongs to. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.snapservice.task
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.snapservice.task
.info (
com.vmware.snapservice.tasks_client.Info
) – Information regarding the task.
- class ListResult(items=None)
Bases:
VapiStruct
The
Tasks.ListResult
class represents the result ofTasks.list()
method.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
items (
list
ofTasks.ListItem
) – List of tasks.
- get(task)
Returns information about a task.
- Parameters:
task (
str
) – Task identifier. The parameter must be an identifier for the resource type:com.vmware.snapservice.task
.- Return type:
- Returns:
Information about the specified task.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the task is not found.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the task’s state cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) tasks matching the
Tasks.FilterSpec
.- Parameters:
filter (
Tasks.FilterSpec
orNone
) – Specification of matching tasks. if None, the behavior is equivalent to aTasks.FilterSpec
with all attributes None which means all tasks match the filter.- Return type:
- Returns:
ListResult including details of all the tasks.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a task’s state cannot be accessed or over 1000 tasks matching theTasks.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.snapservice_client.TimeUnit(string)
Bases:
Enum
The
TimeUnit
class contains the supported values for how often snapshots are taken.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 theTimeUnit
instance.
- DAY = TimeUnit(string='DAY')
Day.
- HOUR = TimeUnit(string='HOUR')
Hours.
- MINUTE = TimeUnit(string='MINUTE')
Minutes.
- MONTH = TimeUnit(string='MONTH')
Months.
- WEEK = TimeUnit(string='WEEK')
Weeks.
com.vmware.vapi_client module
The com.vmware.vapi_client
component provides API infrastructure classes
and standard types that can be used in the interface specification of any
class.
- class com.vmware.vapi_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
com.vmware.vcenter_client module
The com.vmware.vcenter_client
module provides classes for managing VMware
vSphere environments. The module is available starting in vSphere 6.5.
- class com.vmware.vcenter_client.Cluster(config)
Bases:
VapiInterface
The
Cluster
class provides methods to manage clusters in the vCenter Server.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(clusters=None, names=None, folders=None, datacenters=None)
Bases:
VapiStruct
The
Cluster.FilterSpec
class contains attributes used to filter the results when listing clusters (seeCluster.list()
). If multiple attributes are specified, only clusters matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
clusters (
set
ofstr
orNone
) – Identifiers of clusters that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ClusterComputeResource
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ClusterComputeResource
. If None or empty, clusters with any identifier match the filter.names (
set
ofstr
orNone
) – Names that clusters must have to match the filter (seeCluster.Info.name
). If None or empty, clusters with any name match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the cluster for the cluster to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, clusters in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the cluster for the cluster to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, clusters in any datacenter match the filter.
- class Info(name=None, resource_pool=None)
Bases:
VapiStruct
The
Cluster.Info
class contains information about a cluster in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – The name of the clusterresource_pool (
str
) – Identifier of the root resource pool of the cluster When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
.
- RESOURCE_TYPE = 'ClusterComputeResource'
The resource type for the vCenter Cluster
- class Summary(cluster=None, name=None, ha_enabled=None, drs_enabled=None)
Bases:
VapiStruct
The
Cluster.Summary
class contains commonly used information about a cluster in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cluster (
str
) – Identifier of the cluster. 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
.name (
str
) – Name of the cluster.ha_enabled (
bool
) – Flag indicating whether the vSphere HA feature is enabled for the cluster.drs_enabled (
bool
) – Flag indicating whether the vSphere DRS service is enabled for the cluster.
- get(cluster)
Retrieves information about the cluster corresponding to
cluster
.- Parameters:
cluster (
str
) – Identifier of the cluster. The parameter must be an identifier for the resource type:ClusterComputeResource
.- Return type:
- Returns:
Information about the cluster associated with
cluster
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no cluster associated withcluster
in the system.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the session id is missing from the request or the corresponding session object cannot be found.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t not have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
ClusterComputeResource
referenced by the parametercluster
requiresSystem.Read
.
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) clusters in vCenter matching the
Cluster.FilterSpec
.- Parameters:
filter (
Cluster.FilterSpec
orNone
) – Specification of matching clusters for which information should be returned. If None, the behavior is equivalent to aCluster.FilterSpec
with all attributes None which means all clusters match the filter.- Return type:
- Returns:
Commonly used information about the clusters matching the
Cluster.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 1000 clusters match theCluster.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.Datacenter(config)
Bases:
VapiInterface
The
Datacenter
class provides methods to manage datacenters in the vCenter Server.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class CreateSpec(name=None, folder=None)
Bases:
VapiStruct
The
Datacenter.CreateSpec
class defines the information used to create a datacenter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – The name of the datacenter to be created.folder (
str
orNone
) – Datacenter folder in which the new datacenter should be created. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose a suitable folder for the datacenter; if a folder cannot be chosen, the datacenter creation operation will fail.
- class FilterSpec(datacenters=None, names=None, folders=None)
Bases:
VapiStruct
The
Datacenter.FilterSpec
class contains attributes used to filter the results when listing datacenters (seeDatacenter.list()
). If multiple attributes are specified, only datacenters matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datacenters (
set
ofstr
orNone
) – Identifiers of datacenters that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, datacenters with any identifier match the filter.names (
set
ofstr
orNone
) – Names that datacenters must have to match the filter (seeDatacenter.Info.name
). If None or empty, datacenters with any name match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the datacenters for the datacenter to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, datacenters in any folder match the filter.
- class Info(name=None, datastore_folder=None, host_folder=None, network_folder=None, vm_folder=None)
Bases:
VapiStruct
The
Datacenter.Info
class contains information about a datacenter in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – The name of the datacenter.datastore_folder (
str
) – The root datastore folder associated with the datacenter. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
.host_folder (
str
) – The root host and cluster folder associated with the datacenter. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
.network_folder (
str
) – The root network folder associated with the datacenter. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
.vm_folder (
str
) – The root virtual machine folder associated with the datacenter. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
.
- RESOURCE_TYPE = 'Datacenter'
The resource type for the vCenter Datacenter
- class Summary(datacenter=None, name=None)
Bases:
VapiStruct
The
Datacenter.Summary
class contains commonly used information about a datacenter in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datacenter (
str
) – Identifier of the datacenter. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datacenter
.name (
str
) – Name of the datacenter.
- create(spec)
Create a new datacenter in the vCenter inventory
- Parameters:
spec (
Datacenter.CreateSpec
) – Specification for the new datacenter to be created.- Return type:
str
- Returns:
The identifier of the newly created datacenter The return value will be an identifier for the resource type:
Datacenter
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a datacenter with the same name is already present.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the datacenter name is empty or invalid as per the underlying implementation.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the folder is not specified and the system cannot choose a suitable one.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the datacenter folder cannot be found.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- delete(datacenter, force=None)
Delete an empty datacenter from the vCenter Server
- Parameters:
datacenter (
str
) – Identifier of the datacenter to be deleted. The parameter must be an identifier for the resource type:Datacenter
.force (
bool
orNone
) – If true, delete the datacenter even if it is not empty. If None acom.vmware.vapi.std.errors_client.ResourceInUse
exception will be reported if the datacenter is not empty. This is the equivalent of passing the value false.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no datacenter associated withdatacenter
in the system.- Raise:
com.vmware.vapi.std.errors_client.ResourceInUse
if the datacenter associated withdatacenter
is not empty.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- get(datacenter)
Retrieves information about the datacenter corresponding to
datacenter
.- Parameters:
datacenter (
str
) – Identifier of the datacenter. The parameter must be an identifier for the resource type:Datacenter
.- Return type:
- Returns:
Information about the datacenter associated with
datacenter
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no datacenter associated withdatacenter
in the system.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) datacenters in vCenter matching the
Datacenter.FilterSpec
.- Parameters:
filter (
Datacenter.FilterSpec
orNone
) – Specification of matching datacenters for which information should be returned. If None, the behavior is equivalent to aDatacenter.FilterSpec
with all attributes None which means all datacenters match the filter.- Return type:
- Returns:
Commonly used information about the datacenters matching the
Datacenter.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 1000 datacenters match theDatacenter.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.Datastore(config)
Bases:
VapiInterface
The Datastore class provides methods for manipulating a datastore.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(datastores=None, names=None, types=None, folders=None, datacenters=None)
Bases:
VapiStruct
The
Datastore.FilterSpec
class contains attributes used to filter the results when listing datastores (seeDatastore.list()
). If multiple attributes are specified, only datastores matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastores (
set
ofstr
orNone
) – Identifiers of datastores that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datastore
. If None or empty, datastores with any identifier match the filter.names (
set
ofstr
orNone
) – Names that datastores must have to match the filter (seeDatastore.Info.name
). If None or empty, datastores with any name match the filter.types (
set
ofDatastore.Type
orNone
) – Types that datastores must have to match the filter (seeDatastore.Summary.type
). If None or empty, datastores with any type match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the datastore for the datastore to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, datastores in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the datastore for the datastore to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, datastores in any datacenter match the filter.
- class Info(name=None, type=None, accessible=None, free_space=None, multiple_host_access=None, thin_provisioning_supported=None)
Bases:
VapiStruct
The
Datastore.Info
class contains information about a datastore.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name of the datastore.type (
Datastore.Type
) – Type (VMFS, NFS, NFS41, CIFS, VSAN, VFFS, VVOL) of the datastore.accessible (
bool
) – Whether or not this datastore is accessible.free_space (
long
orNone
) –Available space of this datastore, in bytes.
The server periodically updates this value. This attribute will be None if the available space of this datastore is not known.
multiple_host_access (
bool
) – Whether or not more than one host in the datacenter has been configured with access to the datastore.thin_provisioning_supported (
bool
) – Whether or not the datastore supports thin provisioning on a per file basis. When thin provisioning is used, backing storage is lazily allocated.
- RESOURCE_TYPE = 'Datastore'
The resource type for the vCenter datastore
- class Summary(datastore=None, name=None, type=None, free_space=None, capacity=None)
Bases:
VapiStruct
The
Datastore.Summary
class contains commonly used information about a datastore.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastore (
str
) – Identifier of the datastore. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
.name (
str
) – Name of the datastore.type (
Datastore.Type
) – Type (VMFS, NFS, NFS41, CIFS, VSAN, VFFS, VVOL) of the datatore.free_space (
long
orNone
) –Available space of this datastore, in bytes.
The server periodically updates this value. This attribute will be None if the available space of this datastore is not known.
capacity (
long
orNone
) –Capacity of this datastore, in bytes.
The server periodically updates this value. This attribute will be None if the capacity of this datastore is not known.
- class Type(string)
Bases:
Enum
The
Datastore.Type
class defines the supported types of vCenter datastores.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theType
instance.
- CIFS = Type(string='CIFS')
Common Internet File System.
- NFS = Type(string='NFS')
Network file system v3 (linux & esx servers only).
- NFS41 = Type(string='NFS41')
Network file system v4.1 (linux & esx servers only).
- VFFS = Type(string='VFFS')
Flash Read Cache (ESX Server only).
- VMFS = Type(string='VMFS')
VMware File System (ESX Server only).
- VSAN = Type(string='VSAN')
Virtual SAN (ESX Server only).
- VVOL = Type(string='VVOL')
vSphere Virtual Volume (ESX Server only).
- get(datastore)
Retrieves information about the datastore indicated by
datastore
.- Parameters:
datastore (
str
) – Identifier of the datastore for which information should be retrieved. The parameter must be an identifier for the resource type:Datastore
.- Return type:
- Returns:
Information about the datastore associated with
datastore
.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the datastore indicated bydatastore
does not exist.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- list(filter=None)
Returns information about at most 2500 visible (subject to permission checks) datastores in vCenter matching the
Datastore.FilterSpec
.- Parameters:
filter (
Datastore.FilterSpec
orNone
) – Specification of matching datastores for which information should be returned. If None, the behavior is equivalent to aDatastore.FilterSpec
with all attributes None which means all datastores match the filter.- Return type:
- Returns:
Commonly used information about the datastores matching the
Datastore.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theDatastore.FilterSpec.types
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theDatastore.FilterSpec.types
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 2500 datastores match theDatastore.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.Deployment(config)
Bases:
VapiInterface
The
Deployment
class provides methods to get the status of the vCenter appliance deployment. This class was added in vSphere API 6.7.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(state=None, progress=None, subtask_order=None, subtasks=None, description=None, service=None, operation=None, parent=None, target=None, status=None, cancelable=None, error=None, start_time=None, end_time=None, user=None)
Bases:
VapiStruct
The
Deployment.Info
class contains attributes to describe the state of the appliance. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
state (
com.vmware.vcenter.deployment_client.ApplianceState
) – State of the vCenter Server Appliance. This attribute was added in vSphere API 6.7.progress (
com.vmware.cis.task_client.Progress
) – The progress info of the current appliance status. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofCommonInfo#status
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.subtask_order (
list
ofstr
orNone
) – The ordered list of subtasks for this deployment operation. This attribute was added in vSphere API 6.7. Onlyset
when the appliance state is RUNNING_IN_PROGRESS, FAILED, CANCELLED and SUCCEEDED.subtasks ((
dict
ofstr
andDeployment.Task
) orNone
) – The map of the deployment subtasks and their status infomation. This attribute was added in vSphere API 6.7. Onlyset
when the appliance state is RUNNING_IN_PROGRESS, FAILED, CANCELLED and SUCCEEDED.description (
com.vmware.vapi.std_client.LocalizableMessage
) – Description of the operation associated with the task.service (
str
) – Identifier of the service containing the operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.service
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.service
.operation (
str
) – Identifier of the operation associated with the task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.operation
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.operation
.parent (
str
orNone
) – Parent of the current task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.cis.task
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.cis.task
. This attribute will be None if the task has no parent.target (
com.vmware.vapi.std_client.DynamicID
orNone
) – Identifier of the target created by the operation or an existing one the operation performed on. This attribute will be None if the operation has no target or multiple targets.status (
com.vmware.cis.task_client.Status
) – Status of the operation associated with the task.cancelable (
bool
) – Flag to indicate whether or not the operation can be cancelled. The value may change as the operation progresses.error (
Exception
orNone
) – Description of the error if the operation status is “FAILED”. If None the description of why the operation failed will be included in the result of the operation (seecom.vmware.cis.task_client.Info.result
).start_time (
datetime.datetime
) – Time when the operation is started. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.end_time (
datetime.datetime
) – Time when the operation is completed. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.SUCCEEDED
orcom.vmware.cis.task_client.Status.FAILED
.user (
str
orNone
) – Name of the user who performed the operation. This attribute will be None if the operation is performed by the system.
- class Task(progress=None, result=None, description=None, service=None, operation=None, parent=None, target=None, status=None, cancelable=None, error=None, start_time=None, end_time=None, user=None)
Bases:
VapiStruct
The
Deployment.Task
class contains attributes to describe a particular deployment task. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
progress (
com.vmware.cis.task_client.Progress
) – The progress info of this deployment task. This attribute was added in vSphere API 6.7. This attribute is optional and it is only relevant when the value ofCommonInfo#status
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.result (
com.vmware.vcenter.deployment_client.Notifications
orNone
) – Result of the task. This attribute was added in vSphere API 6.7. This attribute will be None if result is not available at the current step of the task.description (
com.vmware.vapi.std_client.LocalizableMessage
) – Description of the operation associated with the task.service (
str
) – Identifier of the service containing the operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.service
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.service
.operation (
str
) – Identifier of the operation associated with the task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vapi.operation
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vapi.operation
.parent (
str
orNone
) – Parent of the current task. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.cis.task
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.cis.task
. This attribute will be None if the task has no parent.target (
com.vmware.vapi.std_client.DynamicID
orNone
) – Identifier of the target created by the operation or an existing one the operation performed on. This attribute will be None if the operation has no target or multiple targets.status (
com.vmware.cis.task_client.Status
) – Status of the operation associated with the task.cancelable (
bool
) – Flag to indicate whether or not the operation can be cancelled. The value may change as the operation progresses.error (
Exception
orNone
) – Description of the error if the operation status is “FAILED”. If None the description of why the operation failed will be included in the result of the operation (seecom.vmware.cis.task_client.Info.result
).start_time (
datetime.datetime
) – Time when the operation is started. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.RUNNING
,com.vmware.cis.task_client.Status.BLOCKED
,com.vmware.cis.task_client.Status.SUCCEEDED
, orcom.vmware.cis.task_client.Status.FAILED
.end_time (
datetime.datetime
) – Time when the operation is completed. This attribute is optional and it is only relevant when the value ofstatus
is one ofcom.vmware.cis.task_client.Status.SUCCEEDED
orcom.vmware.cis.task_client.Status.FAILED
.user (
str
orNone
) – Name of the user who performed the operation. This attribute will be None if the operation is performed by the system.
- get()
Get the current status of the appliance deployment. This method was added in vSphere API 6.7.
- Return type:
- Returns:
Info structure containing the status information about the appliance.
- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the caller is not authenticated.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if appliance state cannot be determined.
- rollback()
Rollback a failed appliance so it can be configured once again. This method was added in vSphere API 6.7.
- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if the appliance is not in FAILED state.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the caller is not authenticated.
- class com.vmware.vcenter_client.Folder(config)
Bases:
VapiInterface
The Folder class provides methods for manipulating a vCenter Server folder.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(folders=None, names=None, type=None, parent_folders=None, datacenters=None)
Bases:
VapiStruct
The
Folder.FilterSpec
class contains attributes used to filter the results when listing folders (seeFolder.list()
). If multiple attributes are specified, only folders matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folders (
set
ofstr
orNone
) – Identifiers of folders that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, folders with any identifier match the filter.names (
set
ofstr
orNone
) – Names that folders must have to match the filter (seeFolder.Summary.name
). If None or empty, folders with any name match the filter.type (
Folder.Type
orNone
) – Type that folders must have to match the filter (seeFolder.Summary.type
). If None, folders with any type match the filter.parent_folders (
set
ofstr
orNone
) – Folders that must contain the folder for the folder to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, folder in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the folder for the folder to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, folder in any datacenter match the filter.
- RESOURCE_TYPE = 'Folder'
The resource type for the vCenter folder
- class Summary(folder=None, name=None, type=None)
Bases:
VapiStruct
The
Folder.Summary
class contains commonly used information about a folder.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
) – Identifier of the folder. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
.name (
str
) – Name of the vCenter Server folder.type (
Folder.Type
) – Type (DATACENTER, DATASTORE, HOST, NETWORK, VIRTUAL_MACHINE) of the vCenter Server folder.
- class Type(string)
Bases:
Enum
The
Folder.Type
class defines the type of a vCenter Server folder. The type of a folder determines what what kinds of children can be contained in the folder.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theType
instance.
- DATACENTER = Type(string='DATACENTER')
A folder that can contain datacenters.
- DATASTORE = Type(string='DATASTORE')
A folder that can contain datastores.
- HOST = Type(string='HOST')
A folder that can contain compute resources (hosts and clusters).
- NETWORK = Type(string='NETWORK')
A folder that can contain networkds.
- VIRTUAL_MACHINE = Type(string='VIRTUAL_MACHINE')
A folder that can contain virtual machines.
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) folders in vCenter matching the
Folder.FilterSpec
.- Parameters:
filter (
Folder.FilterSpec
orNone
) – Specification of matching folders for which information should be returned. If None, the behavior is equivalent to aFolder.FilterSpec
with all attributes None which means all folders match the filter.- Return type:
- Returns:
Commonly used information about the folders matching the
Folder.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theFolder.FilterSpec.type
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 1000 folders match theFolder.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.Host(config)
Bases:
VapiInterface
The
Host
class provides methods to manage hosts in the vCenter Server.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ConnectionState(string)
Bases:
Enum
The
Host.ConnectionState
class defines the connection status of a host.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theConnectionState
instance.
- CONNECTED = ConnectionState(string='CONNECTED')
Host is connected to the vCenter Server
- DISCONNECTED = ConnectionState(string='DISCONNECTED')
Host is disconnected from the vCenter Server
- NOT_RESPONDING = ConnectionState(string='NOT_RESPONDING')
VirtualCenter is not receiving heartbeats from the server. The state automatically changes to connected once heartbeats are received again.
- class CreateSpec(hostname=None, port=None, user_name=None, password=None, folder=None, thumbprint_verification=None, thumbprint=None, force_add=None)
Bases:
VapiStruct
The
Host.CreateSpec
class defines the information used to create a host.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
hostname (
str
) – The IP address or DNS resolvable name of the host.port (
long
orNone
) – The port of the host. If None, port 443 will be used.user_name (
str
) – The administrator account on the host.password (
str
) – The password for the administrator account on the host.folder (
str
orNone
) – Host and cluster folder in which the new standalone host should be created. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose a suitable folder for the host; if a folder cannot be chosen, the host creation operation will fail.thumbprint_verification (
Host.CreateSpec.ThumbprintVerification
) – Type of host’s SSL certificate verification to be done.thumbprint (
str
) – The thumbprint of the SSL certificate, which the host is expected to have. The thumbprint is always computed using the SHA1 hash and is the string representation of that hash in the format: xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx where, ‘x’ represents a hexadecimal digit. This attribute is optional and it is only relevant when the value ofthumbprintVerification
isHost.CreateSpec.ThumbprintVerification.THUMBPRINT
.force_add (
bool
orNone
) – Whether host should be added to the vCenter Server even if it is being managed by another vCenter Server. The original vCenterServer loses connection to the host. If None, forceAdd is default to false.
- class ThumbprintVerification(string)
Bases:
Enum
The
Host.CreateSpec.ThumbprintVerification
class defines the thumbprint verification schemes for a host’s SSL certificate.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theThumbprintVerification
instance.
- NONE = ThumbprintVerification(string='NONE')
Accept the host’s thumbprint without verifying it.
- THUMBPRINT = ThumbprintVerification(string='THUMBPRINT')
Host’s SSL certificate verified by checking its thumbprint against the specified thumbprint.
- class FilterSpec(hosts=None, names=None, folders=None, datacenters=None, standalone=None, clusters=None, connection_states=None)
Bases:
VapiStruct
The
Host.FilterSpec
class contains attributes used to filter the results when listing hosts (seeHost.list()
). If multiple attributes are specified, only hosts matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
hosts (
set
ofstr
orNone
) – Identifiers of hosts that can match the filter. 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, hosts with any identifier match the filter.names (
set
ofstr
orNone
) – Names that hosts must have to match the filter (seeHost.Summary.name
). If None or empty, hosts with any name match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the hosts for the hosts to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, hosts in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the hosts for the hosts to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, hosts in any datacenter match the filter.standalone (
bool
orNone
) – If true, only hosts that are not part of a cluster can match the filter, and if false, only hosts that are are part of a cluster can match the filter. If None Hosts can match filter independent of whether they are part of a cluster or not. If this field is true andHost.FilterSpec.clusters
os not empty, no hosts will match the filter.clusters (
set
ofstr
orNone
) – Clusters that must contain the hosts for the hosts to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ClusterComputeResource
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ClusterComputeResource
. If None or empty, hosts in any cluster and hosts that are not in a cluster match the filter. If this attribute is not empty andHost.FilterSpec.standalone
is true, no hosts will match the filter.connection_states (
set
ofHost.ConnectionState
orNone
) – Connection states that a host must be in to match the filter (seeHost.Summary.connection_state
. If None or empty, hosts in any connection state match the filter.
- class PowerState(string)
Bases:
Enum
The
Host.PowerState
class defines the power states of a host.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for thePowerState
instance.
- POWERED_OFF = PowerState(string='POWERED_OFF')
The host was specifically powered off by the user through vCenter server. This state is not a cetain state, because after vCenter server issues the command to power off the host, the host might crash, or kill all the processes but fail to power off.
- POWERED_ON = PowerState(string='POWERED_ON')
The host is powered on. A host that is entering standby mode is also in this state.
- STANDBY = PowerState(string='STANDBY')
The host was specifically put in standby mode, either explicitly by the user, or automatically by DPM. This state is not a cetain state, because after VirtualCenter issues the command to put the host in standby state, the host might crash, or kill all the processes but fail to enter standby mode. A host that is exiting standby mode is also in this state.
- RESOURCE_TYPE = 'HostSystem'
The resource type for the vCenter Host.
- class Summary(host=None, name=None, connection_state=None, power_state=None)
Bases:
VapiStruct
The
Host.Summary
class contains commonly used information about a host in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
host (
str
) – Identifier of the host. 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
.name (
str
) – Name of the host.connection_state (
Host.ConnectionState
) – Connection status of the hostpower_state (
Host.PowerState
) – Power state of the host This attribute is optional and it is only relevant when the value ofconnectionState
isHost.ConnectionState.CONNECTED
.
- connect(host)
Connect to the host corresponding to
host
previously added to the vCenter server.- Parameters:
host (
str
) – Identifier of the host to be reconnected. The parameter must be an identifier for the resource type:HostSystem
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyInDesiredState
if the host associated withhost
is already connected.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no host associated withhost
in the system.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- create(spec)
Add a new standalone host in the vCenter inventory. The newly connected host will be in connected state. The vCenter Server will verify the SSL certificate before adding the host to its inventory. In the case where the SSL certificate cannot be verified because the Certificate Authority is not recognized or the certificate is self signed, the vCenter Server will fall back to thumbprint verification mode as defined by
Host.CreateSpec.ThumbprintVerification
.- Parameters:
spec (
Host.CreateSpec
) – Specification for the new host to be created.- Return type:
str
- Returns:
The newly created identifier of the host in vCenter. The return value will be an identifier for the resource type:
HostSystem
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if the host with the same name is already present.- Raise:
com.vmware.vapi.std.errors_client.Error
if installation of VirtualCenter agent on a host fails.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the host name is invalid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the host folder is invalid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the SSL thumbprint specified is invalid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the PEM SSL certificate in CreateSpec.sslCertificate is invalid.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if both CreateSpec.thumbprint and CreateSpec.sslCertificate areset
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the CreateSpec.sslCertificate argument is not set, and the CreateSpec.thumbprint argument is set, but the SHA-1 hashing algorithm is currently disabled for computing certificate thumbprints.- Raise:
com.vmware.vapi.std.errors_client.InvalidElementType
if the host folder id does not support vSphere compute resource as its children type.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no folder associated with thefolder
attribute in the system.- Raise:
com.vmware.vapi.std.errors_client.ResourceInUse
if the host is already being managed by another vCenter Server- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if there are not enough licenses to add the host.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user name or password for the administration account on the host are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
if the software version on the host is not supported.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- delete(host)
Remove a standalone host from the vCenter Server.
- Parameters:
host (
str
) – Identifier of the host to be deleted. The parameter must be an identifier for the resource type:HostSystem
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no host associated withhost
in the system.- Raise:
com.vmware.vapi.std.errors_client.ResourceInUse
if the host associated withhost
is in a vCenter cluster- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- disconnect(host)
Disconnect the host corresponding to
host
from the vCenter server- Parameters:
host (
str
) – Identifier of the host to be disconnected. The parameter must be an identifier for the resource type:HostSystem
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyInDesiredState
if the host associated withhost
is already disconnected.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no host associated withhost
in the system.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- list(filter=None)
Returns information about at most 2500 visible (subject to permission checks) hosts in vCenter matching the
Host.FilterSpec
.- Parameters:
filter (
Host.FilterSpec
orNone
) – Specification of matching hosts for which information should be returned. If None, the behavior is equivalent to aHost.FilterSpec
with all attributes None which means all hosts match the filter.- Return type:
list
ofHost.Summary
- Returns:
Commonly used information about the hosts matching the
Host.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theHost.FilterSpec.connection_states
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 2500 hosts match theHost.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.Network(config)
Bases:
VapiInterface
The Network class provides methods for manipulating a vCenter Server network.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(networks=None, names=None, types=None, folders=None, datacenters=None)
Bases:
VapiStruct
The
Network.FilterSpec
class contains attributes used to filter the results when listing networks (seeNetwork.list()
). If multiple attributes are specified, only networks matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
networks (
set
ofstr
orNone
) – Identifiers of networks that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Network
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Network
. If None or empty, networks with any identifier match the filter.names (
set
ofstr
orNone
) – Names that networks must have to match the filter (seeNetwork.Summary.name
). If None or empty, networks with any name match the filter.types (
set
ofNetwork.Type
orNone
) – Types that networks must have to match the filter (seeNetwork.Summary.type
). If None, networks with any type match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the network for the network to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, networks in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the network for the network to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, networks in any datacenter match the filter.
- RESOURCE_TYPE = 'Network'
The resource type for the vCenter network
- class Summary(network=None, name=None, type=None)
Bases:
VapiStruct
The
Network.Summary
class contains commonly used information about a network.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
network (
str
) – Identifier of the network. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Network
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Network
.name (
str
) – Name of the network.type (
Network.Type
) – Type (STANDARD_PORTGROUP, DISTRIBUTED_PORTGROUP, OPAQUE_NETWORK) of the vCenter Server network.
- class Type(string)
Bases:
Enum
The
Network.Type
class defines the type of a vCenter Server network. The type of a network can be used to determine what features it supports and which APIs can be used to find more information about the network or change its configuration.Note
This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.
- Parameters:
string (
str
) – String value for theType
instance.
- DISTRIBUTED_PORTGROUP = Type(string='DISTRIBUTED_PORTGROUP')
Distributed virtual portgroup (created and managed through vCenter)
- OPAQUE_NETWORK = Type(string='OPAQUE_NETWORK')
A network whose configuration is managed outside of vSphere. The identifer and name of the network is made available through vSphere so that host and virtual machine virtual ethernet devices can connect to them.
- STANDARD_PORTGROUP = Type(string='STANDARD_PORTGROUP')
vSphere standard portgroup (created and managed on ESX)
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) networks in vCenter matching the
Network.FilterSpec
.- Parameters:
filter (
Network.FilterSpec
orNone
) – Specification of matching networks for which information should be returned. If None, the behavior is equivalent to aNetwork.FilterSpec
with all attributes None which means all networks match the filter.- Return type:
- Returns:
Commonly used information about the networks matching the
Network.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theNetwork.FilterSpec.types
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 1000 networks match theNetwork.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- class com.vmware.vcenter_client.ResourcePool(config)
Bases:
VapiInterface
The ResourcePool class provides methods for manipulating a vCenter Server resource pool.
This class does not include virtual appliances in the inventory of resource pools even though part of the behavior of a virtual appliance is to act like a resource pool.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class CreateSpec(name=None, parent=None, cpu_allocation=None, memory_allocation=None)
Bases:
VapiStruct
The class contains information used to create a resource pool, see
ResourcePool.create()
. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name of the resource pool. This attribute was added in vSphere API 7.0.0.0.parent (
str
) – Parent of the created resource pool. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
.cpu_allocation (
ResourcePool.ResourceAllocationCreateSpec
orNone
) – Resource allocation for CPU. This attribute was added in vSphere API 7.0.0.0. if None or empty, use the default CPU allocation specification.memory_allocation (
ResourcePool.ResourceAllocationCreateSpec
orNone
) – Resource allocation for memory. This attribute was added in vSphere API 7.0.0.0. if None or empty, use the default memory allocation specification.
- class FilterSpec(resource_pools=None, names=None, parent_resource_pools=None, datacenters=None, hosts=None, clusters=None)
Bases:
VapiStruct
The
ResourcePool.FilterSpec
class contains attributes used to filter the results when listing resource pools (seeResourcePool.list()
). If multiple attributes are specified, only resource pools matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
resource_pools (
set
ofstr
orNone
) – Identifiers of resource pools that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ResourcePool
. If None or empty, resource pools with any identifier match the filter.names (
set
ofstr
orNone
) – Names that resource pools must have to match the filter (seeResourcePool.Info.name
). If None or empty, resource pools with any name match the filter.parent_resource_pools (
set
ofstr
orNone
) – Resource pools that must contain the resource pool for the resource pool to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ResourcePool
. If None or empty, resource pools in any resource pool match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the resource pool for the resource pool to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, resource pools in any datacenter match the filter.hosts (
set
ofstr
orNone
) – Hosts that must contain the resource pool for the resource pool to match the filter. 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, resource pools in any host match the filter.clusters (
set
ofstr
orNone
) – Clusters that must contain the resource pool for the resource pool to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ClusterComputeResource
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ClusterComputeResource
. If None or empty, resource pools in any cluster match the filter.
- class Info(name=None, resource_pools=None, cpu_allocation=None, memory_allocation=None)
Bases:
VapiStruct
The
ResourcePool.Info
class contains information about a resource pool.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
) – Name of the vCenter Server resource pool.resource_pools (
set
ofstr
) – Identifiers of the child resource pools contained in this resource pool. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ResourcePool
.cpu_allocation (
ResourcePool.ResourceAllocationInfo
) – Resource allocation information for CPU. This attribute was added in vSphere API 7.0.0.0. This attribute is optional because it was added in a newer version than its parent node.memory_allocation (
ResourcePool.ResourceAllocationInfo
) – Resource allocation information for memory. This attribute was added in vSphere API 7.0.0.0. This attribute is optional because it was added in a newer version than its parent node.
- RESOURCE_TYPE = 'ResourcePool'
The resource type for the vCenter resource pool
- class ResourceAllocationCreateSpec(reservation=None, expandable_reservation=None, limit=None, shares=None)
Bases:
VapiStruct
The
ResourcePool.ResourceAllocationCreateSpec
class contains resource allocation information used to create a resource pool, seeResourcePool.create()
. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
reservation (
long
orNone
) – Amount of resource that is guaranteed available to a resource pool. Reserved resources are not wasted if they are not used. If the utilization is less than the reservation, the resources can be utilized by other running virtual machines. Units are MB fo memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0. If None or empty,ResourcePool.ResourceAllocationCreateSpec.reservation
will be set to 0.expandable_reservation (
bool
orNone
) – In a resource pool with an expandable reservation, the reservation can grow beyond the specified value, if the parent resource pool has unreserved resources. A non-expandable reservation is called a fixed reservation. This attribute was added in vSphere API 7.0.0.0. If None or empty,ResourcePool.ResourceAllocationCreateSpec.expandable_reservation
will be set to true.limit (
long
orNone
) – The utilization of a resource pool will not exceed this limit, even if there are available resources. This is typically used to ensure a consistent performance of resource pools independent of available resources. If set to -1, then there is no fixed limit on resource usage (only bounded by available resources and shares). Units are MB for memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0. If None or empty,ResourcePool.ResourceAllocationCreateSpec.limit
will be set to -1.shares (
ResourcePool.SharesInfo
orNone
) – Shares are used in case of resource contention. This attribute was added in vSphere API 7.0.0.0. If None or empty,ResourcePool.ResourceAllocationCreateSpec.shares
will be set to ‘ResourcePool.SharesInfo.Level.NORMAL
’.
- class ResourceAllocationInfo(reservation=None, expandable_reservation=None, limit=None, shares=None)
Bases:
VapiStruct
The
ResourcePool.ResourceAllocationInfo
class contains resource allocation information of a resource pool. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
reservation (
long
) – Amount of resource that is guaranteed available to a resource pool. Reserved resources are not wasted if they are not used. If the utilization is less than the reservation, the resources can be utilized by other running virtual machines. Units are MB fo memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0.expandable_reservation (
bool
) – In a resource pool with an expandable reservation, the reservation can grow beyond the specified value, if the parent resource pool has unreserved resources. A non-expandable reservation is called a fixed reservation. This attribute was added in vSphere API 7.0.0.0.limit (
long
) – The utilization of a resource pool will not exceed this limit, even if there are available resources. This is typically used to ensure a consistent performance of resource pools independent of available resources. If set to -1, then there is no fixed limit on resource usage (only bounded by available resources and shares). Units are MB for memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0.shares (
ResourcePool.SharesInfo
) – Shares are used in case of resource contention. This attribute was added in vSphere API 7.0.0.0.
- class ResourceAllocationUpdateSpec(reservation=None, expandable_reservation=None, limit=None, shares=None)
Bases:
VapiStruct
The
ResourceAllocationUpdateSpec
class descrives the updates to be made to the resource allocation settings of a resource pool. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
reservation (
long
orNone
) – Amount of resource that is guaranteed available to a resource pool. Reserved resources are not wasted if they are not used. If the utilization is less than the reservation, the resources can be utilized by other running virtual machines. Units are MB fo memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0. If None or empty,reservation
will be set to 0.expandable_reservation (
bool
orNone
) – In a resource pool with an expandable reservation, the reservation can grow beyond the specified value, if the parent resource pool has unreserved resources. A non-expandable reservation is called a fixed reservation. This attribute was added in vSphere API 7.0.0.0. If None or empty,expandableReservation
will be set to true.limit (
long
orNone
) – The utilization of a resource pool will not exceed this limit, even if there are available resources. This is typically used to ensure a consistent performance of resource pools independent of available resources. If set to -1, then there is no fixed limit on resource usage (only bounded by available resources and shares). Units are MB for memory, and MHz for CPU. This attribute was added in vSphere API 7.0.0.0. If None or empty,limit
will be set to -1.shares (
ResourcePool.SharesInfo
orNone
) – Shares are used in case of resource contention. This attribute was added in vSphere API 7.0.0.0. If None or empty,shares
will be set to ‘ResourcePool.SharesInfo.Level.NORMAL
’.
Bases:
VapiStruct
The
ResourcePool.SharesInfo
class provides specification of shares.Shares are used to determine relative allocation between resource consumers. In general, a consumer with more shares gets proportionally more of the resource, subject to certain other constraints.. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
level (
ResourcePool.SharesInfo.Level
) – The allocation level. It maps to a pre-determined set of numeric values for shares. If the shares value does not map to a predefined size, then the level is set as CUSTOM. This attribute was added in vSphere API 7.0.0.0.shares (
long
) –When
ResourcePool.SharesInfo.level
is set to CUSTOM, it is the number of shares allocated. Otherwise, this value is ignored.There is no unit for this value. It is a relative measure based on the settings for other resource pools.. This attribute was added in vSphere API 7.0.0.0. This attribute is optional and it is only relevant when the value of
level
isResourcePool.SharesInfo.Level.CUSTOM
.
Bases:
Enum
The
ResourcePool.SharesInfo.Level
class defines the possible values for the allocation level. This enumeration was added in vSphere API 7.0.0.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 theLevel
instance.
If
set
, in case there is resource contention the server uses the shares value to determine the resource allocation. This class attribute was added in vSphere API 7.0.0.0.
For CPU: Shares = 2000 * number of virtual CPUs. For Memory: Shares = 20 * virtual machine memory size in MB. . This class attribute was added in vSphere API 7.0.0.0.
For CPU: Shares = 500 * number of virtual CPUs. For Memory: Shares = 5 * virtual machine memory size in MB. . This class attribute was added in vSphere API 7.0.0.0.
For CPU: Shares = 1000 * number of virtual CPUs. For Memory: Shares = 10 * virtual machine memory size in MB. . This class attribute was added in vSphere API 7.0.0.0.
- class Summary(resource_pool=None, name=None)
Bases:
VapiStruct
The
ResourcePool.Summary
class contains commonly used information about a resource pool in vCenter Server.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
resource_pool (
str
) – Identifier of the resource pool. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
.name (
str
) – Name of the resource pool.
- class UpdateSpec(name=None, cpu_allocation=None, memory_allocation=None)
Bases:
VapiStruct
The class contains specification for updating the configuration of a resource pool. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
orNone
) – Name of the resource pool. This attribute was added in vSphere API 7.0.0.0. if None or empty, the name of the resource pool will not be changed.cpu_allocation (
ResourcePool.ResourceAllocationUpdateSpec
orNone
) – Resource allocation for CPU. This attribute was added in vSphere API 7.0.0.0. if None or empty, the CPU allocation of the resource pool will not be changed.memory_allocation (
ResourcePool.ResourceAllocationUpdateSpec
orNone
) – Resource allocation for memory. This attribute was added in vSphere API 7.0.0.0. if None or empty, the memory allocation of the resource pool will not be changed.
- create(spec)
Creates a resource pool. This method was added in vSphere API 7.0.0.0.
- Parameters:
spec (
ResourcePool.CreateSpec
) – Specification of the new resource pool to be created, seeResourcePool.CreateSpec
.- Return type:
str
- Returns:
The identifier of the newly created resource pool. The return value will be an identifier for the resource type:
ResourcePool
.- Raise:
com.vmware.vapi.std.errors_client.Error
If the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
If a parameter passed in the spec is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the resource specified in parent could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
If the specified resource in parent is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
If the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to create the resource pool could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
ResourcePool
referenced by the attributeResourcePool.CreateSpec.parent
requiresResource.CreatePool
.
- delete(resource_pool)
Deletes a resource pool. This method was added in vSphere API 7.0.0.0.
- Parameters:
resource_pool (
str
) – Identifier of the resource pool to be deleted. The parameter must be an identifier for the resource type:ResourcePool
.- Raise:
com.vmware.vapi.std.errors_client.Error
If the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the resource pool is not found.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
If the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
If the resource pool is a root resource pool.
- get(resource_pool)
Retrieves information about the resource pool indicated by
resource_pool
.- Parameters:
resource_pool (
str
) – Identifier of the resource pool for which information should be retrieved. The parameter must be an identifier for the resource type:ResourcePool
.- Return type:
- Returns:
Information about the resource pool.
- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the resource pool indicated byresource_pool
does not exist.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
If the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
ResourcePool
referenced by the parameterresource_pool
requiresSystem.Read
.
- list(filter=None)
Returns information about at most 1000 visible (subject to permission checks) resource pools in vCenter matching the
ResourcePool.FilterSpec
.- Parameters:
filter (
ResourcePool.FilterSpec
orNone
) – Specification of matching resource pools for which information should be returned. If None, the behavior is equivalent to aResourcePool.FilterSpec
with all attributes None which means all resource pools match the filter.- Return type:
- Returns:
Commonly used information about the resource pools matching the
ResourcePool.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
If more than 1000 resource pools match theResourcePool.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
If the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user doesn’t have the required privileges.
- update(resource_pool, spec)
Updates the configuration of a resource pool. This method was added in vSphere API 7.0.0.0.
- Parameters:
resource_pool (
str
) – Identifier of the resource pool. The parameter must be an identifier for the resource type:ResourcePool
.spec (
ResourcePool.UpdateSpec
) – Specification for updating the configuration of the resource pool.
- Raise:
com.vmware.vapi.std.errors_client.Error
If the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
If any of the specified parameters is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
If the resource pool is not found.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
If the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
If any of the resources needed to reconfigure the resource pool could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
If the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
If the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
ResourcePool
referenced by the parameterresource_pool
requiresResource.EditPool
.
- class com.vmware.vcenter_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.vcenter_client.System(config)
Bases:
VapiInterface
The
System
class contains methods for negotiating API communication parameters including release ID.Software developers obtain a list of supported API release IDs from vCenter documentation or as part of the client library (SDK) they work with at the time they develop and test a solution. The software solution initiates a handshake by sending a prioritized list of release IDs supported by the solution. The server selects the first release ID it supports from the list.
Negotiating API release ID is necessary to use APIs utilizing inheritance based polymorphism. These include all VI/JSON APIs and a set of vSphere Automation APIs. vSphere Automation APIs that require API release ID state this in their documentation. Consult the Programming Guide and API reference documentation of specific methods for more information.. This class was added in vSphere API 8.0.2.0.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class HelloResult(api_release=None)
Bases:
VapiStruct
The
System.HelloResult
class contains common API communication parameters. This class was added in vSphere API 8.0.2.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
api_release (
str
) –The ID of a mutually-supported API release. This ID should be used in subsequent API calls to the current vCenter system.
If there is no mutually-supported API release, the value will be an empty string, e.g.
""
. Typically, this is a case where one of the parties is much older than the other party.. This attribute was added in vSphere API 8.0.2.0.
- class HelloSpec(api_releases=None)
Bases:
VapiStruct
The
System.HelloSpec
class describes the API client preferences. This class was added in vSphere API 8.0.2.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
api_releases (
list
ofstr
) – List of API release IDs that the client can work with in order of preference. The server will select the first mutually supported release ID. This attribute was added in vSphere API 8.0.2.0.
- hello(spec)
Negotiates common parameters for API communication.
This method selects mutually supported choices from the
System.HelloSpec.api_releases
list.. This method was added in vSphere API 8.0.2.0.- Parameters:
spec (
System.HelloSpec
) – Client capabilities including list of supported API release IDs.- Return type:
- Returns:
Common parameters for API communication.
- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if the list of client provided release IDs (System.HelloSpec.api_releases
) is empty or the list is longer then 128 releases or given release ID is longer then 64 characters.
- class com.vmware.vcenter_client.VM(config)
Bases:
VapiInterface
The
VM
class provides methods for managing the lifecycle of a virtual machine.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class ClonePlacementSpec(folder=None, resource_pool=None, host=None, cluster=None, datastore=None)
Bases:
VapiStruct
The
VM.ClonePlacementSpec
class contains information used to place a clone of a virtual machine onto resources within the vCenter inventory. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the cloned virtual machine should be placed. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. If attribute is None, the system will use the virtual machine folder of the source virtual machine. If this results in a conflict due to other placement parameters, the virtual machine clone operation will fail.resource_pool (
str
orNone
) – Resource pool into which the cloned virtual machine should be placed. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. If attribute is None, the system will use the resource pool of the source virtual machine. If this results in a conflict due to other placement parameters, the virtual machine clone operation will fail.host (
str
orNone
) –Host onto which the cloned virtual machine should be placed.
If
host
andresourcePool
are both specified,resourcePool
must belong tohost
.If
host
andcluster
are both specified,host
must be a member ofcluster
.. This attribute was added in vSphere API 7.0.0.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
. If this attribute is unset, ifresourcePool
is unset, the cloned virtual machine will use the host of the source virtual machine. ifresourcePool
is set, and the target is a standalone host, the host is used. ifresourcePool
is set, and the target is a DRS cluster, a host will be picked by DRS. ifresourcePool
is set, and the target is a cluster without DRS, InvalidArgument will be thrown.cluster (
str
orNone
) –Cluster into which the cloned virtual machine should be placed.
If
cluster
andresourcePool
are both specified,resourcePool
must belong tocluster
.If
cluster
andhost
are both specified,host
must be a member ofcluster
.. This attribute was added in vSphere API 7.0.0.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
. IfresourcePool
orhost
is specified, it is recommended that this attribute be None.datastore (
str
orNone
) – Datastore on which the cloned virtual machine’s configuration state should be stored. This datastore will also be used for any virtual disks that are created as part of the virtual machine clone operation unless individually overridden. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. If attribute is None, the system will use the datastore of the source virtual machine.
- class CloneSpec(source=None, name=None, placement=None, disks_to_remove=None, disks_to_update=None, power_on=None, guest_customization_spec=None)
Bases:
VapiStruct
Document-based clone spec. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
source (
str
) – Virtual machine to clone from. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine
.name (
str
) – Virtual machine name. This attribute was added in vSphere API 7.0.0.0.placement (
VM.ClonePlacementSpec
orNone
) – Virtual machine placement information. This attribute was added in vSphere API 7.0.0.0. If this attribute is None, the system will use the values from the source virtual machine. If specified, each field will be used for placement. If the fields result in disjoint placement the operation will fail. If the fields along with the placement values of the source virtual machine result in disjoint placement the operation will fail.disks_to_remove (
set
ofstr
orNone
) – Set of Disks to Remove. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vcenter.vm.hardware.Disk
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vcenter.vm.hardware.Disk
. If None, all disks will be copied. If the same identifier is inVM.CloneSpec.disks_to_update
InvalidArgument fault will be returned.disks_to_update ((
dict
ofstr
andVM.DiskCloneSpec
) orNone
) – Map of Disks to Update. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
. If None, all disks will copied to the datastore specified in theVM.ClonePlacementSpec.datastore
attribute ofVM.CloneSpec.placement
. If the same identifier is inVM.CloneSpec.disks_to_remove
InvalidArgument fault will be thrown.power_on (
bool
orNone
) – Attempt to perform aVM.CloneSpec.power_on
after clone. This attribute was added in vSphere API 7.0.0.0. If None, the virtual machine will not be powered on.guest_customization_spec (
VM.GuestCustomizationSpec
orNone
) – Guest customization spec to apply to the virtual machine after the virtual machine is deployed. This attribute was added in vSphere API 7.0.0.0. If None, the guest operating system is not customized after clone.
- class ComputePlacementSpec(resource_pool=None, host=None, cluster=None)
Bases:
VapiStruct
The
VM.ComputePlacementSpec
class contains information used to place a virtual machine on compute resources.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
resource_pool (
str
orNone
) – Resource pool into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. This attribute is currently required if bothhost
andcluster
are None. In the future, if this attribute is None, the system will attempt to choose a suitable resource pool for the virtual machine; if a resource pool cannot be chosen, the virtual machine creation operation will fail.host (
str
orNone
) –Host onto which the virtual machine should be placed.
If
host
andresourcePool
are both specified,resourcePool
must belong tohost
.If
host
andcluster
are both specified,host
must be a member ofcluster
. 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 may be None ifresourcePool
orcluster
is specified. If None, the system will attempt to choose a suitable host for the virtual machine; if a host cannot be chosen, the virtual machine creation operation will fail.cluster (
str
orNone
) –Cluster into which the virtual machine should be placed.
If
cluster
andresourcePool
are both specified,resourcePool
must belong tocluster
.If
cluster
andhost
are both specified,host
must be a member ofcluster
. 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
. IfresourcePool
orhost
is specified, it is recommended that this attribute be None.
- class CreateSpec(guest_os=None, name=None, placement=None, hardware_version=None, boot=None, boot_devices=None, cpu=None, memory=None, disks=None, nics=None, cdroms=None, floppies=None, parallel_ports=None, serial_ports=None, sata_adapters=None, scsi_adapters=None, nvme_adapters=None, storage_policy=None)
Bases:
VapiStruct
Document-based creation spec.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
guest_os (
com.vmware.vcenter.vm_client.GuestOS
) – Guest OS.name (
str
orNone
) – Virtual machine name. If None, a default name will be generated by the server.placement (
VM.PlacementSpec
orNone
) – Virtual machine placement information. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose suitable resources on which to place the virtual machine.hardware_version (
com.vmware.vcenter.vm_client.Hardware.Version
orNone
) – Virtual hardware version. If None, defaults to the most recent version supported by the server.boot (
com.vmware.vcenter.vm.hardware_client.Boot.CreateSpec
orNone
) – Boot configuration. If None, guest-specific default values will be used.boot_devices (
list
ofcom.vmware.vcenter.vm.hardware.boot_client.Device.EntryCreateSpec
orNone
) – Boot device configuration. If None, a server-specific boot sequence will be used.cpu (
com.vmware.vcenter.vm.hardware_client.Cpu.UpdateSpec
orNone
) – CPU configuration. If None, guest-specific default values will be used.memory (
com.vmware.vcenter.vm.hardware_client.Memory.UpdateSpec
orNone
) – Memory configuration. If None, guest-specific default values will be used.disks (
list
ofcom.vmware.vcenter.vm.hardware_client.Disk.CreateSpec
orNone
) – List of disks. If None, a single blank virtual disk of a guest-specific size will be created on the same storage as the virtual machine configuration, and will use a guest-specific host bus adapter type. If the guest-specific size is 0, no virtual disk will be created.nics (
list
ofcom.vmware.vcenter.vm.hardware_client.Ethernet.CreateSpec
orNone
) – List of Ethernet adapters. If None, no Ethernet adapters will be created.cdroms (
list
ofcom.vmware.vcenter.vm.hardware_client.Cdrom.CreateSpec
orNone
) – List of CD-ROMs. If None, no CD-ROM devices will be created.floppies (
list
ofcom.vmware.vcenter.vm.hardware_client.Floppy.CreateSpec
orNone
) – List of floppy drives. If None, no floppy drives will be created.parallel_ports (
list
ofcom.vmware.vcenter.vm.hardware_client.Parallel.CreateSpec
orNone
) – List of parallel ports. If None, no parallel ports will be created.serial_ports (
list
ofcom.vmware.vcenter.vm.hardware_client.Serial.CreateSpec
orNone
) – List of serial ports. If None, no serial ports will be created.sata_adapters (
list
ofcom.vmware.vcenter.vm.hardware.adapter_client.Sata.CreateSpec
orNone
) – List of SATA adapters. If None, any adapters necessary to connect the virtual machine’s storage devices will be created; this includes any devices that explicitly specify a SATA host bus adapter, as well as any devices that do not specify a host bus adapter if the guest’s preferred adapter type is SATA.scsi_adapters (
list
ofcom.vmware.vcenter.vm.hardware.adapter_client.Scsi.CreateSpec
orNone
) – List of SCSI adapters. If None, any adapters necessary to connect the virtual machine’s storage devices will be created; this includes any devices that explicitly specify a SCSI host bus adapter, as well as any devices that do not specify a host bus adapter if the guest’s preferred adapter type is SCSI. The type of the SCSI adapter will be a guest-specific default type.nvme_adapters (
list
ofcom.vmware.vcenter.vm.hardware.adapter_client.Nvme.CreateSpec
orNone
) – List of NVMe adapters. This attribute was added in vSphere API 7.0.0.1. If None, any adapters necessary to connect the virtual machine’s storage devices will be created; this includes any devices that explicitly specify a NVMe host bus adapter, as well as any devices that do not specify a host bus adapter if the guest’s preferred adapter type is NVMe.storage_policy (
VM.StoragePolicySpec
orNone
) – TheVM.StoragePolicySpec
class contains information about the storage policy that is to be associated with the virtual machine home (which contains the configuration and log files). This attribute was added in vSphere API 6.7. If None the datastore default storage policy (if applicable) is applied. Currently a default storage policy is only supported by object datastores : VVol and vSAN. For non-object datastores, if None then no storage policy would be associated with the virtual machine home.
- class DiskCloneSpec(datastore=None)
Bases:
VapiStruct
Document-based disk clone spec. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastore (
str
orNone
) – Destination datastore to clone disk. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. This attribute is currently required. In the future, if this attribute is None disk will be copied to the datastore specified in theVM.ClonePlacementSpec.datastore
attribute ofVM.CloneSpec.placement
.
- class DiskRelocateSpec(datastore=None)
Bases:
VapiStruct
Document-based disk relocate spec. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastore (
str
orNone
) – Destination datastore to relocate disk. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. This attribute is currently required. In the future, if this attribute is unset, disk will use the datastore specified inVM.RelocatePlacementSpec.datastore
attribute ofVM.RelocateSpec.placement
.
- class FilterSpec(vms=None, names=None, folders=None, datacenters=None, hosts=None, clusters=None, resource_pools=None, power_states=None)
Bases:
VapiStruct
The
VM.FilterSpec
class contains attributes used to filter the results when listing virtual machines (seeVM.list()
). If multiple attributes are specified, only virtual machines matching all of the attributes match the filter.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
vms (
set
ofstr
orNone
) – Identifiers of virtual machines that can match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:VirtualMachine
. If None or empty, virtual machines with any identifier match the filter.names (
set
ofstr
orNone
) – Names that virtual machines must have to match the filter (seeVM.Info.name
). If None or empty, virtual machines with any name match the filter.folders (
set
ofstr
orNone
) – Folders that must contain the virtual machine for the virtual machine to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Folder
. If None or empty, virtual machines in any folder match the filter.datacenters (
set
ofstr
orNone
) – Datacenters that must contain the virtual machine for the virtual machine to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:Datacenter
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:Datacenter
. If None or empty, virtual machines in any datacenter match the filter.hosts (
set
ofstr
orNone
) – Hosts that must contain the virtual machine for the virtual machine to match the filter. 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, virtual machines on any host match the filter.clusters (
set
ofstr
orNone
) – Clusters that must contain the virtual machine for the virtual machine to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ClusterComputeResource
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ClusterComputeResource
. If None or empty, virtual machines in any cluster match the filter.resource_pools (
set
ofstr
orNone
) – Resource pools that must contain the virtual machine for the virtual machine to match the filter. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:ResourcePool
. If None or empty, virtual machines in any resource pool match the filter.power_states (
set
ofcom.vmware.vcenter.vm_client.Power.State
orNone
) – Power states that a virtual machine must be in to match the filter (seecom.vmware.vcenter.vm_client.Power.Info.state
. If None or empty, virtual machines in any power state match the filter.
- class GuestCustomizationSpec(name=None)
Bases:
VapiStruct
The
VM.GuestCustomizationSpec
class contains information required to customize a virtual machine when deploying it. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
name (
str
orNone
) – Name of the customization specification. This attribute was added in vSphere API 7.0.0.0. If None, no guest customization is performed.
- class Info(guest_os=None, name=None, identity=None, power_state=None, instant_clone_frozen=None, hardware=None, boot=None, boot_devices=None, cpu=None, memory=None, disks=None, nics=None, cdroms=None, floppies=None, parallel_ports=None, serial_ports=None, sata_adapters=None, scsi_adapters=None, nvme_adapters=None)
Bases:
VapiStruct
Document-based info.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
guest_os (
com.vmware.vcenter.vm_client.GuestOS
) – Guest OS.name (
str
) – Virtual machine name.identity (
com.vmware.vcenter.vm_client.Identity.Info
) – Identity of the virtual machine. This attribute was added in vSphere API 6.7.1. This attribute is optional because it was added in a newer version than its parent node.power_state (
com.vmware.vcenter.vm_client.Power.State
) – Power state of the virtual machine.instant_clone_frozen (
bool
) – Indicates whether the virtual machine is frozen for instant clone, or not. This attribute was added in vSphere API 6.7.1. This attribute is optional because it was added in a newer version than its parent node.hardware (
com.vmware.vcenter.vm_client.Hardware.Info
) – Virtual hardware version information.boot (
com.vmware.vcenter.vm.hardware_client.Boot.Info
) – Boot configuration.boot_devices (
list
ofcom.vmware.vcenter.vm.hardware.boot_client.Device.Entry
) – Boot device configuration. If thelist
has no entries, a server-specific default boot sequence is used.cpu (
com.vmware.vcenter.vm.hardware_client.Cpu.Info
) – CPU configuration.memory (
com.vmware.vcenter.vm.hardware_client.Memory.Info
) – Memory configuration.disks (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Disk.Info
) – List of disks. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
.nics (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Ethernet.Info
) – List of Ethernet adapters. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet
.cdroms (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Cdrom.Info
) – List of CD-ROMs. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Cdrom
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Cdrom
.floppies (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Floppy.Info
) – List of floppy drives. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Floppy
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Floppy
.parallel_ports (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Parallel.Info
) – List of parallel ports. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ParallelPort
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ParallelPort
.serial_ports (
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Serial.Info
) – List of serial ports. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SerialPort
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SerialPort
.sata_adapters (
dict
ofstr
andcom.vmware.vcenter.vm.hardware.adapter_client.Sata.Info
) – List of SATA adapters. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SataAdapter
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SataAdapter
.scsi_adapters (
dict
ofstr
andcom.vmware.vcenter.vm.hardware.adapter_client.Scsi.Info
) – List of SCSI adapters. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ScsiAdapter
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ScsiAdapter
.nvme_adapters (
dict
ofstr
andcom.vmware.vcenter.vm.hardware.adapter_client.Nvme.Info
) – List of NVMe adapters. This attribute was added in vSphere API 7.0.0.1. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.NvmeAdapter
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.NvmeAdapter
. This attribute is optional because it was added in a newer version than its parent node.
- class InstantClonePlacementSpec(folder=None, resource_pool=None, datastore=None)
Bases:
VapiStruct
The
VM.InstantClonePlacementSpec
class contains information used to place an InstantClone of a virtual machine onto resources within the vCenter inventory. This class was added in vSphere API 6.7.1.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the InstantCloned virtual machine should be placed. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. If attribute is None, the system will use the virtual machine folder of the source virtual machine.resource_pool (
str
orNone
) – Resource pool into which the InstantCloned virtual machine should be placed. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. If attribute is None, the system will use the resource pool of the source virtual machine.datastore (
str
orNone
) – Datastore on which the InstantCloned virtual machine’s configuration state should be stored. This datastore will also be used for any virtual disks that are created as part of the virtual machine InstantClone operation. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. If attribute is None, the system will use the datastore of the source virtual machine.
- class InstantCloneSpec(source=None, name=None, placement=None, nics_to_update=None, disconnect_all_nics=None, parallel_ports_to_update=None, serial_ports_to_update=None, bios_uuid=None)
Bases:
VapiStruct
Document-based InstantClone spec. This class was added in vSphere API 6.7.1.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
source (
str
) – Virtual machine to InstantClone from. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine
.name (
str
) – Name of the new virtual machine. This attribute was added in vSphere API 6.7.1.placement (
VM.InstantClonePlacementSpec
orNone
) – Virtual machine placement information. This attribute was added in vSphere API 6.7.1. If this attribute is None, the system will use the values from the source virtual machine. If specified, each field will be used for placement. If the fields result in disjoint placement the operation will fail. If the fields along with the placement values of the source virtual machine result in disjoint placement the operation will fail.nics_to_update ((
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Ethernet.UpdateSpec
) orNone
) – Map of NICs to update. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Ethernet
. If None, no NICs will be updated.disconnect_all_nics (
bool
orNone
) – Indicates whether all NICs on the destination virtual machine should be disconnected from the newtwork. This attribute was added in vSphere API 6.7.1. If None, connection status of all NICs on the destination virtual machine will be the same as on the source virtual machine.parallel_ports_to_update ((
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Parallel.UpdateSpec
) orNone
) – Map of parallel ports to Update. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ParallelPort
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.ParallelPort
. If None, no parallel ports will be updated.serial_ports_to_update ((
dict
ofstr
andcom.vmware.vcenter.vm.hardware_client.Serial.UpdateSpec
) orNone
) – Map of serial ports to Update. This attribute was added in vSphere API 6.7.1. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SerialPort
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.SerialPort
. If None, no serial ports will be updated.bios_uuid (
str
orNone
) – 128-bit SMBIOS UUID of a virtual machine represented as a hexadecimal string in “12345678-abcd-1234-cdef-123456789abc” format. This attribute was added in vSphere API 6.7.1. If None, will be generated.
- class InventoryPlacementSpec(folder=None)
Bases:
VapiStruct
The
VM.InventoryPlacementSpec
class contains information used to place a virtual machine in the vCenter inventory.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose a suitable folder for the virtual machine; if a folder cannot be chosen, the virtual machine creation operation will fail.
- class PlacementSpec(folder=None, resource_pool=None, host=None, cluster=None, datastore=None)
Bases:
VapiStruct
The
VM.PlacementSpec
class contains information used to place a virtual machine onto resources within the vCenter inventory.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose a suitable folder for the virtual machine; if a folder cannot be chosen, the virtual machine creation operation will fail.resource_pool (
str
orNone
) – Resource pool into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. This attribute is currently required if bothhost
andcluster
are None. In the future, if this attribute is None, the system will attempt to choose a suitable resource pool for the virtual machine; if a resource pool cannot be chosen, the virtual machine creation operation will fail.host (
str
orNone
) –Host onto which the virtual machine should be placed.
If
host
andresourcePool
are both specified,resourcePool
must belong tohost
.If
host
andcluster
are both specified,host
must be a member ofcluster
. 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 may be None ifresourcePool
orcluster
is specified. If None, the system will attempt to choose a suitable host for the virtual machine; if a host cannot be chosen, the virtual machine creation operation will fail.cluster (
str
orNone
) –Cluster into which the virtual machine should be placed.
If
cluster
andresourcePool
are both specified,resourcePool
must belong tocluster
.If
cluster
andhost
are both specified,host
must be a member ofcluster
. 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
. IfresourcePool
orhost
is specified, it is recommended that this attribute be None.datastore (
str
orNone
) – Datastore on which the virtual machine’s configuration state should be stored. This datastore will also be used for any virtual disks that are created as part of the virtual machine creation operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose suitable storage for the virtual machine; if storage cannot be chosen, the virtual machine creation operation will fail.
- RESOURCE_TYPE = 'VirtualMachine'
Resource type for virtual machines.
- class RegisterPlacementSpec(folder=None, resource_pool=None, host=None, cluster=None)
Bases:
VapiStruct
The
VM.RegisterPlacementSpec
class contains information used to place a virtual machine, created from existing virtual machine files on storage, onto resources within the vCenter inventory. This class was added in vSphere API 6.8.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose a suitable folder for the virtual machine; if a folder cannot be chosen, the virtual machine creation operation will fail.resource_pool (
str
orNone
) – Resource pool into which the virtual machine should be placed. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. This attribute is currently required if bothhost
andcluster
are None. In the future, if this attribute is None, the system will attempt to choose a suitable resource pool for the virtual machine; if a resource pool cannot be chosen, the virtual machine creation operation will fail.host (
str
orNone
) –Host onto which the virtual machine should be placed.
If
host
andresourcePool
are both specified,resourcePool
must belong tohost
.If
host
andcluster
are both specified,host
must be a member ofcluster
. 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 may be None ifresourcePool
orcluster
is specified. If None, the system will attempt to choose a suitable host for the virtual machine; if a host cannot be chosen, the virtual machine creation operation will fail.cluster (
str
orNone
) –Cluster into which the virtual machine should be placed.
If
cluster
andresourcePool
are both specified,resourcePool
must belong tocluster
.If
cluster
andhost
are both specified,host
must be a member ofcluster
. 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
. IfresourcePool
orhost
is specified, it is recommended that this attribute be None.
- class RegisterSpec(datastore=None, path=None, datastore_path=None, name=None, placement=None)
Bases:
VapiStruct
The
VM.RegisterSpec
class contains information used to create a virtual machine from existing virtual machine files on storage.The location of the virtual machine files on storage must be specified by providing either
VM.RegisterSpec.datastore
andVM.RegisterSpec.path
or by providingVM.RegisterSpec.datastore_path
. IfVM.RegisterSpec.datastore
andVM.RegisterSpec.path
areset
,VM.RegisterSpec.datastore_path
must be None, and ifVM.RegisterSpec.datastore_path
isset
,VM.RegisterSpec.datastore
andVM.RegisterSpec.path
must be None.. This class was added in vSphere API 6.8.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastore (
str
orNone
) – Identifier of the datastore on which the virtual machine’s configuration state is stored. This attribute was added in vSphere API 6.8.7. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. If None,VM.RegisterSpec.path
must also be None andVM.RegisterSpec.datastore_path
must beset
.path (
str
orNone
) – Path to the virtual machine’s configuration file on the datastore corresponding to {\@link #datastore). This attribute was added in vSphere API 6.8.7. If None,VM.RegisterSpec.datastore
must also be None andVM.RegisterSpec.datastore_path
must beset
.datastore_path (
str
orNone
) – Datastore path for the virtual machine’s configuration file in the format “[datastore name] path”. For example “[storage1] Test-VM/Test-VM.vmx”. This attribute was added in vSphere API 6.8.7. If None, bothVM.RegisterSpec.datastore
andVM.RegisterSpec.path
must beset
.name (
str
orNone
) – Virtual machine name. This attribute was added in vSphere API 6.8.7. If None, the display name from the virtual machine’s configuration file will be used.placement (
VM.RegisterPlacementSpec
orNone
) – Virtual machine placement information. This attribute was added in vSphere API 6.8.7. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose suitable resources on which to place the virtual machine.
- class RelocatePlacementSpec(folder=None, resource_pool=None, host=None, cluster=None, datastore=None)
Bases:
VapiStruct
The
VM.RelocatePlacementSpec
class contains information used to change the placement of an existing virtual machine within the vCenter inventory. This class was added in vSphere API 7.0.0.0.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
folder (
str
orNone
) – Virtual machine folder into which the virtual machine should be placed. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Folder
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Folder
. If this attribute is None, the virtual machine will stay in the current folder.resource_pool (
str
orNone
) – Resource pool into which the virtual machine should be placed. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:ResourcePool
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:ResourcePool
. If this attribute is None, the virtual machine will stay in the current resource pool.host (
str
orNone
) –Host onto which the virtual machine should be placed.
If
host
andresourcePool
are both specified,resourcePool
must belong tohost
.If
host
andcluster
are both specified,host
must be a member ofcluster
.. This attribute was added in vSphere API 7.0.0.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
. If this attribute is unset, ifresourcePool
is unset, the virtual machine will remain on the current host. ifresourcePool
is set, and the target is a standalone host, the host is used. ifresourcePool
is set, and the target is a DRS cluster, a host will be picked by DRS. ifresourcePool
is set, and the target is a cluster without DRS, InvalidArgument will be thrown.cluster (
str
orNone
) –Cluster into which the virtual machine should be placed.
If
cluster
andresourcePool
are both specified,resourcePool
must belong tocluster
.If
cluster
andhost
are both specified,host
must be a member ofcluster
.. This attribute was added in vSphere API 7.0.0.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
. IfresourcePool
orhost
is specified, it is recommended that this attribute be None.datastore (
str
orNone
) – Datastore on which the virtual machine’s configuration state should be stored. This datastore will also be used for any virtual disks that are associated with the virtual machine, unless individually overridden. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. If this attribute is None, the virtual machine will remain on the current datastore.
- class RelocateSpec(placement=None, disks=None)
Bases:
VapiStruct
Document-based relocate spec. This class was added in vSphere API 7.0.0.0.
Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
placement (
VM.RelocatePlacementSpec
orNone
) – Virtual machine placement information. This attribute was added in vSphere API 7.0.0.0. If this attribute is None, the system will use the values from the source virtual machine. If specified, each field will be used for placement. If the fields result in disjoint placement the operation will fail. If the fields along with the other existing placement of the virtual machine result in disjoint placement the operation will fail.disks ((
dict
ofstr
andVM.DiskRelocateSpec
) orNone
) – Individual disk relocation map. This attribute was added in vSphere API 7.0.0.0. When clients pass a value of this class as a parameter, the key in the attributedict
must be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
. When methods return a value of this class as a return value, the key in the attributedict
will be an identifier for the resource type:com.vmware.vcenter.vm.hardware.Disk
. If None, all disks will migrate to the datastore specified in theVM.RelocatePlacementSpec.datastore
attribute ofVM.RelocateSpec.placement
.
- class StoragePlacementSpec(datastore=None)
Bases:
VapiStruct
The
VM.StoragePlacementSpec
class contains information used to store a virtual machine’s files.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
datastore (
str
orNone
) – Datastore on which the virtual machine’s configuration state should be stored. This datastore will also be used for any virtual disks that are created as part of the virtual machine creation operation. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:Datastore
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:Datastore
. This attribute is currently required. In the future, if this attribute is None, the system will attempt to choose suitable storage for the virtual machine; if storage cannot be chosen, the virtual machine creation operation will fail.
- class StoragePolicySpec(policy=None)
Bases:
VapiStruct
The
VM.StoragePolicySpec
class contains information about the storage policy to be associated with a virtual machine object. This class was added in vSphere API 6.7.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
policy (
str
) – Identifier of the storage policy which should be associated with the virtual machine. This attribute was added in vSphere API 6.7. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vcenter.StoragePolicy
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vcenter.StoragePolicy
.
- class Summary(vm=None, name=None, power_state=None, cpu_count=None, memory_size_mib=None)
Bases:
VapiStruct
The
VM.Summary
class contains commonly used information about a virtual machine.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
vm (
str
) – Identifier of the virtual machine. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:VirtualMachine
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:VirtualMachine
.name (
str
) – Name of the Virtual machine.power_state (
com.vmware.vcenter.vm_client.Power.State
) – Power state of the virtual machine.cpu_count (
long
orNone
) – Number of CPU cores. This attribute will be None if the virtual machine configuration is not available. For example, the configuration information would be unavailable if the server is unable to access the virtual machine files on disk, and is often also unavailable during the intial phases of virtual machine creation.memory_size_mib (
long
orNone
) – Memory size in mebibytes. This attribute will be None if the virtual machine configuration is not available. For example, the configuration information would be unavailable if the server is unable to access the virtual machine files on disk, and is often also unavailable during the intial phases of virtual machine creation.
- clone(spec)
Creates a virtual machine from an existing virtual machine.
. This method was added in vSphere API 7.0.0.0.
- Parameters:
spec (
VM.CloneSpec
) – Virtual machine clone specification.- Return type:
str
- Returns:
ID of newly-created virtual machine. The return value will be an identifier for the resource type:
VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a virtual machine with the specified name already exists.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to clone the virtual machine could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
Datastore
referenced by the attributeVM.DiskCloneSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Datastore
referenced by the attributeVM.ClonePlacementSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Folder
referenced by the attributeVM.ClonePlacementSpec.folder
requiresVirtualMachine.Inventory.CreateFromExisting
.The resource
ResourcePool
referenced by the attributeVM.ClonePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.The resource
VirtualMachine
referenced by the attributeVM.CloneSpec.source
requiresVirtualMachine.Provisioning.Clone
.
- clone_task(spec)
Creates a virtual machine from an existing virtual machine.
. This method was added in vSphere API 7.0.0.0.
- Parameters:
spec (
VM.CloneSpec
) – Virtual machine clone specification.- Return type:
- class:
vmware.vapi.stdlib.client.task.Task
- Returns:
Task instance
- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a virtual machine with the specified name already exists.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to clone the virtual machine could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
Datastore
referenced by the attributeVM.DiskCloneSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Datastore
referenced by the attributeVM.ClonePlacementSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Folder
referenced by the attributeVM.ClonePlacementSpec.folder
requiresVirtualMachine.Inventory.CreateFromExisting
.The resource
ResourcePool
referenced by the attributeVM.ClonePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.The resource
VirtualMachine
referenced by the attributeVM.CloneSpec.source
requiresVirtualMachine.Provisioning.Clone
.
- create(spec)
Creates a virtual machine.
- Parameters:
spec (
VM.CreateSpec
) – Virtual machine specification.- Return type:
str
- Returns:
ID of newly-created virtual machine. The return value will be an identifier for the resource type:
VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a virtual machine with the specified name already exists.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ResourceInUse
if any of the specified storage addresses (eg. IDE, SATA, SCSI, NVMe) result in a storage address conflict.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to create the virtual machine could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unsupported
ifguestOS
is not supported for the requested virtual hardware version and spec includes None attributes that default to guest-specific values.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
Folder
referenced by the attributeVM.InventoryPlacementSpec.folder
requiresVirtualMachine.Inventory.Create
.The resource
ResourcePool
referenced by the attributeVM.ComputePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.The resource
Datastore
referenced by the attributeVM.StoragePlacementSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Network
referenced by the attributecom.vmware.vcenter.vm.hardware_client.Ethernet.BackingSpec.network
requiresNetwork.Assign
.
- delete(vm)
Deletes a virtual machine.
- Parameters:
vm (
str
) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the virtual machine is running (powered on).- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the virtual machine is not found.- Raise:
com.vmware.vapi.std.errors_client.ResourceBusy
if the virtual machine is busy performing another operation.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the virtual machine’s configuration state cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the parametervm
requiresVirtualMachine.Inventory.Delete
.
- get(vm)
Returns information about a virtual machine.
- Parameters:
vm (
str
) – Virtual machine identifier. The parameter must be an identifier for the resource type:VirtualMachine
.- Return type:
- Returns:
Information about the specified virtual machine.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the virtual machine is not found.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if the virtual machine’s configuration state cannot be accessed.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the parametervm
requiresSystem.Read
.
- instant_clone(spec)
Create an instant clone of an existing virtual machine. This method was added in vSphere API 6.7.1.
- Parameters:
spec (
VM.InstantCloneSpec
) – Virtual machine InstantCloneSpec.- Return type:
str
- Returns:
ID of newly-created virtual machine. The return value will be an identifier for the resource type:
VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a virtual machine with the specified name already exists.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to create an instant clone could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the attributeVM.InstantCloneSpec.source
requiresVirtualMachine.Provisioning.Clone
andVirtualMachine.Inventory.CreateFromExisting
.The resource
Folder
referenced by the attributeVM.InstantClonePlacementSpec.folder
requiresVirtualMachine.Interact.PowerOn
.The resource
ResourcePool
referenced by the attributeVM.InstantClonePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.The resource
Datastore
referenced by the attributeVM.InstantClonePlacementSpec.datastore
requiresDatastore.AllocateSpace
.The resource
Network
referenced by the attributecom.vmware.vcenter.vm.hardware_client.Ethernet.BackingSpec.network
requiresNetwork.Assign
.
- list(filter=None)
Returns information about at most 4000 visible (subject to permission checks) virtual machines in vCenter matching the
VM.FilterSpec
.- Parameters:
filter (
VM.FilterSpec
orNone
) – Specification of matching virtual machines for which information should be returned. If None, the behavior is equivalent to aVM.FilterSpec
with all attributes None which means all virtual machines match the filter.- Return type:
list
ofVM.Summary
- Returns:
Commonly used information about the virtual machines matching the
VM.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if theVM.FilterSpec.power_states
attribute contains a value that is not supported by the server.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if more than 4000 virtual machines match theVM.FilterSpec
.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.
- register(spec)
Creates a virtual machine from existing virtual machine files on storage. This method was added in vSphere API 6.8.7.
- Parameters:
spec (
VM.RegisterSpec
) – Specification of the location of the virtual machine files and the placement of the new virtual machine.- Return type:
str
- Returns:
Identifier of the newly-created virtual machine. The return value will be an identifier for the resource type:
VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.AlreadyExists
if a virtual machine with the specified name already exists or if a virtual machine using the specified virtual machine files already exists.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec could not be found.- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.UnableToAllocateResource
if any of the resources needed to register the virtual machine could not be allocated.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user cannot be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
Datastore
referenced by the attributeVM.RegisterSpec.datastore
requiresSystem.Read
.The resource
Folder
referenced by the attributeVM.InventoryPlacementSpec.folder
requiresVirtualMachine.Inventory.Register
.The resource
ResourcePool
referenced by the attributeVM.ComputePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.
- relocate(vm, spec)
Relocates a virtual machine based on the specification. The parts of the virtual machine that can move are: FOLDER, RESOURCE_POOL, HOST, CLUSTER and DATASTORE of home of the virtual machine and disks.
. This method was added in vSphere API 7.0.0.0.
- Parameters:
vm (
str
) – Existing Virtual machine to relocate. The parameter must be an identifier for the resource type:VirtualMachine
.spec (
VM.RelocateSpec
) – Relocate specification.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec or the given “vm” could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the parametervm
requiresResource.ColdMigrate
.The resource
ResourcePool
referenced by the attributeVM.RelocatePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.
- relocate_task(vm, spec)
Relocates a virtual machine based on the specification. The parts of the virtual machine that can move are: FOLDER, RESOURCE_POOL, HOST, CLUSTER and DATASTORE of home of the virtual machine and disks.
. This method was added in vSphere API 7.0.0.0.
- Parameters:
vm (
str
) – Existing Virtual machine to relocate. The parameter must be an identifier for the resource type:VirtualMachine
.spec (
VM.RelocateSpec
) – Relocate specification.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if any of the resources specified in spec or the given “vm” could not be found- Raise:
com.vmware.vapi.std.errors_client.ResourceInaccessible
if a specified resource (eg. host) is not accessible.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the parametervm
requiresResource.ColdMigrate
.The resource
ResourcePool
referenced by the attributeVM.RelocatePlacementSpec.resource_pool
requiresResource.AssignVMToPool
.
- unregister(vm)
Removes the virtual machine corresponding to
vm
from the vCenter inventory without removing any of the virtual machine’s files from storage. All high-level information stored with the management server (ESXi or vCenter) is removed, including information such as statistics, resource pool association, permissions, and alarms. This method was added in vSphere API 6.8.7.- Parameters:
vm (
str
) – Identifier of the virtual machine to be unregistered. The parameter must be an identifier for the resource type:VirtualMachine
.- Raise:
com.vmware.vapi.std.errors_client.NotAllowedInCurrentState
if the virtual machine is running (powered on).- Raise:
com.vmware.vapi.std.errors_client.NotFound
if there is no virtual machine associated withvm
in the system.- Raise:
com.vmware.vapi.std.errors_client.ResourceBusy
if the virtual machine is busy performing another operation.- Raise:
com.vmware.vapi.std.errors_client.ServiceUnavailable
if the system is unable to communicate with a service to complete the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user doesn’t have the required privileges.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if you do not have all of the privileges described as follows:The resource
VirtualMachine
referenced by the parametervm
requiresVirtualMachine.Inventory.Unregister
.
com.vmware.vstats_client module
The com.vmware.vstats_client
component provides API classes and types used
in the vStats service.
- class com.vmware.vstats_client.AcqSpecs(config)
Bases:
VapiInterface
The
AcqSpecs
class provides methods to perform acquisition specification related operations. An acquisition specification defines the statistical data that should be collected at desired sampling rates from the underlying providers. It designates the resources and their counters which should be sampled, and a desired sampling rate. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class CounterSpec(cid_mid=None, set_id=None)
Bases:
VapiStruct
The
AcqSpecs.CounterSpec
class designates a counter or counter set in an acquisition specification. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid_mid (
CidMid
orNone
) – Counter and optional meatadata identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None thesetId
field will be used.set_id (
str
orNone
) – Counter set identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.CounterSet
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.CounterSet
. When None thecidMid
field will be used.
- class CreateSpec(counters=None, resources=None, interval=None, expiration=None, memo_=None)
Bases:
VapiStruct
The
AcqSpecs.CreateSpec
class contains information for a new data acquisition specification. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
counters (
AcqSpecs.CounterSpec
) – Designates the counter(s) to be sampled. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.resources (
list
ofRsrcId
) – A set of resource identifiers representing a single resource to be monitored. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.interval (
long
orNone
) – Desired sampling rate in seconds. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None default of 10s will be used.expiration (
long
orNone
) – Expiration time for this acquisition specification in Unix UTC number of seconds (since epoch). Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None or 0, default expiration duration is 100 minutes.memo (
str
orNone
) – Consumer provided text about this acquisition specification. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None default empty string will be used.
- class FilterSpec(page=None)
Bases:
VapiStruct
The
AcqSpecs.FilterSpec
class contains attributes used to filter the results when listing acquisition specifications. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
page (
str
orNone
) – Used to retrieve paged data for larger result sets. The value of this token is generated by server and returned asnext
attribute in the result oflist
methods. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. None the first page of results will be returned.
- class Info(id=None, counters=None, resources=None, interval=None, expiration=None, memo_=None, status=None)
Bases:
VapiStruct
The
AcqSpecs.Info
class is the information about an acquisition specification. It specifies the statistical data that should be collected at desired sampling rates. It designates the resources and their counters which should be sampled, and a desired sampling rate. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – Acquisition specification identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.AcqSpec
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.AcqSpec
.counters (
AcqSpecs.CounterSpec
) – Designates the counter(s) to be sampled. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.resources (
list
ofRsrcId
) – A set of resource identifiers representing a single resource to be monitored. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.interval (
long
orNone
) – Desired sampling rate in seconds. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None, default interval is 10 seconds.expiration (
long
orNone
) – Expiration time for this acquisition specification represented as Unix UTC number of seconds (since epoch). Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None or 0, default expiration duration is 100 minutes.memo (
str
) – Consumer provided text about this Acquisition Specification. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.status (
AcqSpecs.Status
) – Acquisition Specification status. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class ListResult(acq_specs=None, next=None)
Bases:
VapiStruct
The
AcqSpecs.ListResult
class contains attributes used to return the acquisition specifications. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
acq_specs (
list
ofAcqSpecs.Info
) – List of acquisition specifications received. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.next (
str
orNone
) – Thenext
attribute is a token used to retrieve paged data for larger result sets. This is opaque token generated by the server. It is to be sent in theAcqSpecs.FilterSpec.page
attribute to issue a subsequent call to the list method for retrieving results that did not fit the current page. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.set
when there are more results to retrieve.
- RESOURCE_TYPE = 'com.vmware.vstats.model.AcqSpec'
Resource type for acquisition specifications. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class Status(string)
Bases:
Enum
Describes the status of an Acquisition Specification. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
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 theStatus
instance.
- DISABLED = Status(string='DISABLED')
The acquisition specification is disabled when the stats data collection is paused. This can happen when the counters are enabled or disabled dynamically on providers. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- ENABLED = Status(string='ENABLED')
The acquisition specification is enabled when the stats data collection is going on. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EXPIRED = Status(string='EXPIRED')
The acquisition specification is expired when the expiration time is exceeded. There is no data collection in that case. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class UpdateSpec(counters=None, resources=None, interval=None, expiration=None, memo_=None)
Bases:
VapiStruct
The
AcqSpecs.UpdateSpec
class contains attributes that can be updated in an acquisition specification. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
counters (
AcqSpecs.CounterSpec
orNone
) – Designates the counter(s) to be sampled. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None, the value is unchanged.resources (
list
ofRsrcId
orNone
) – A set of resource identifiers representing a single resource to be monitored. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None, the value is unchanged.interval (
long
orNone
) – Desired sampling rate in seconds. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None, the value is unchanged.expiration (
long
orNone
) – Expiration time for this acquisition specification in Unix UTC number of seconds (since epoch). When this attribute is 0, the default expiration duration is 100 minutes. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None, the value is unchanged.memo (
str
orNone
) – Consumer provided text about this Acquisition Specification. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. If None, the value is unchanged.
- create(acq_spec)
Create a new acquisition specification record. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
acq_spec (
AcqSpecs.CreateSpec
) – Specification for the acquisition of stats data.- Return type:
str
- Returns:
Identifier of the newly created acquisition specification. The return value will be an identifier for the resource type:
com.vmware.vstats.model.AcqSpec
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifacq_spec
contain any errors.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- delete(id)
Delete an acquisition specification. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
id (
str
) – Acquisition specification ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.AcqSpec
.- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if acquisition specification could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- get(id)
Returns information about a specific acquisition specification. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
id (
str
) – Acquisition specification ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.AcqSpec
.- Return type:
- Returns:
Information about the desired acquisition specification.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
acquisition specification could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- list(filter=None)
Returns information about all acquisition specifications. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
filter (
AcqSpecs.FilterSpec
orNone
) – Criteria for selecting records to return. Whenset
filtering will be applied to the result.- Return type:
- Returns:
List of acquisition specification records.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- update(id, acq_spec)
Update an existing acquisition specification. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
id (
str
) – Acquisition specification ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.AcqSpec
.acq_spec (
AcqSpecs.UpdateSpec
) – Updated acquisition specification.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
acquisition specification could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.CidMid(cid=None, mid=None)
Bases:
VapiStruct
The
CidMid
class is used to designate a counter. It contains a counter id that identifies the semantical counter. There is optional metadata identifier that identifies the particular generation of the counter. When counter metadata is not designated vStats will use a default for the counter metadata. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid (
str
) – Counter Id. CID is a string with rather strong semantic consistency across deployments and versions. If two CIDs are identical it implies the corresponding counters are the same. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
.mid (
str
orNone
) – MID is a 64-bit integer with strong consistency. Given a particular CID=cid, if two MIDs are the same, then the corresponding counter-metadata objects are same. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
. When this attribute is None vStats will use default for the counter metadata as obtained from the provider.
- class com.vmware.vstats_client.CounterMetadata(config)
Bases:
VapiInterface
The
CounterMetadata
class provides access to the different historical editions of counters. As computing platforms evolve over time the measurement units for different characteristics of the systems change. As such changes occur, counters will receive different editions reflected in a new metadata record. For example computer memory had changes from kilobytes through megabytes into gigabytes. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class CounterEditionStatus(string)
Bases:
Enum
Counter metadata status. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
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 theCounterEditionStatus
instance.
- CURRENT = CounterEditionStatus(string='CURRENT')
The counter edition is current. This implies a support commitment. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- DEFAULT = CounterEditionStatus(string='DEFAULT')
The counter edition is current and is the default. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- DEPRECATED = CounterEditionStatus(string='DEPRECATED')
The counter edition is deprecated. It will be decommissioned rather soon. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EXPERIMENTAL = CounterEditionStatus(string='EXPERIMENTAL')
The counter edition is experimental. Consumers shouldn’t rely on it for the long haul. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- REMOVED = CounterEditionStatus(string='REMOVED')
The counter edition was removed. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class FilterSpec(status=None)
Bases:
VapiStruct
The
CounterMetadata.FilterSpec
class is used to filter the counter metadata list. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
status (
CounterMetadata.CounterEditionStatus
orNone
) – Counter edition status. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None no filtering on counter metadata status will be made.
- class Info(cid=None, mid=None, status=None, type=None, units=None, scale=None, user_info=None, pid=None)
Bases:
VapiStruct
The
CounterMetadata.Info
class contains information about CounterMetadata. It represents edition of the Counter. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid (
str
) – Counter Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
.mid (
str
) – Metadata Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
.status (
CounterMetadata.CounterEditionStatus
) – Counter Edition status. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.type (
CounterMetadata.SampleType
) – Numeric properties of the sampled data. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.units (
CounterMetadata.MetricUnits
) – The units of the measurement. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.scale (
CounterMetadata.UnitsFactor
orNone
) – Additional multiplier factors to be used with units. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None default ofONE
is used.user_info (
UserInfo
orNone
) – Human legible localizable text about the counter. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. This attribute is None in the current version.pid (
str
orNone
) – ID of the respective provider. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Provider
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Provider
. This attribute is None in the current version.
- class MetricUnits(string)
Bases:
Enum
Unit used by a metric. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
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 theMetricUnits
instance.
- AMPERE = MetricUnits(string='AMPERE')
Ampere. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- BIT = MetricUnits(string='BIT')
Bit. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- BITSPERSECOND = MetricUnits(string='BITSPERSECOND')
Bits per second. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- BYTE = MetricUnits(string='BYTE')
Byte. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- BYTESPERSECOND = MetricUnits(string='BYTESPERSECOND')
Bytes per second. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- CANDELA = MetricUnits(string='CANDELA')
Candela. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- CELSIUS = MetricUnits(string='CELSIUS')
Celsius. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- GRAM = MetricUnits(string='GRAM')
Gram. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- HERTZ = MetricUnits(string='HERTZ')
Hertz. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- JOULE = MetricUnits(string='JOULE')
Joule. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- KELVIN = MetricUnits(string='KELVIN')
Kelvin. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- KILOGRAM = MetricUnits(string='KILOGRAM')
Kilogram. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- METER = MetricUnits(string='METER')
Meter. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- METERSPERSECOND = MetricUnits(string='METERSPERSECOND')
Meters per second. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- METERSPERSECONDSQUARED = MetricUnits(string='METERSPERSECONDSQUARED')
Meters per second squared. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- MOLE = MetricUnits(string='MOLE')
Mole. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- NUMBER = MetricUnits(string='NUMBER')
Number. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- PERCENT = MetricUnits(string='PERCENT')
Percent. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- SECOND = MetricUnits(string='SECOND')
Second. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- VOLT = MetricUnits(string='VOLT')
Volt. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- VOLTAMPERE = MetricUnits(string='VOLTAMPERE')
Volt Ampere. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- WATT = MetricUnits(string='WATT')
Watt. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class SampleType(string)
Bases:
Enum
Type of the sampled data. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
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 theSampleType
instance.
- ABSOLUTE = SampleType(string='ABSOLUTE')
Absolute value samples. Represents an actual value of the counter. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- DELTA = SampleType(string='DELTA')
Delta samples. Represents an amount of change for the counter between the current time-stamp and the last time-stamp when the counter was sampled. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- FRACTION = SampleType(string='FRACTION')
Fraction samples. Implies range from 0.00 to 1.00. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- LOGN = SampleType(string='LOGN')
Log(n) samples. A natural logarithm of the value. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- RATE = SampleType(string='RATE')
Rate samples. Represents a value that has been normalized over the time period. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- RAW = SampleType(string='RAW')
Raw samples. The value unprocessed as-is sampled. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class UnitsFactor(string)
Bases:
Enum
Unit factor of measurement. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
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 theUnitsFactor
instance.
- ATTO = UnitsFactor(string='ATTO')
Atto 10^-18. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- CENTI = UnitsFactor(string='CENTI')
Centi 10^-2. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- DECA = UnitsFactor(string='DECA')
Deca 10. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- DECI = UnitsFactor(string='DECI')
Deci 10^-1. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EXA = UnitsFactor(string='EXA')
Exa 10^18. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EXBI = UnitsFactor(string='EXBI')
Exbi 2^60, 1024^6. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- FEMTO = UnitsFactor(string='FEMTO')
Femto 10^-15. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- GIBI = UnitsFactor(string='GIBI')
Gibi 2^30, 1024^3. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- GIGA = UnitsFactor(string='GIGA')
Giga 10^9. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- HECTO = UnitsFactor(string='HECTO')
Hecto 10^2. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- KIBI = UnitsFactor(string='KIBI')
Kibi 2^10, 1024. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- KILO = UnitsFactor(string='KILO')
Kilo 10^3. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- MEBI = UnitsFactor(string='MEBI')
Mebi 2^20, 1024^2. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- MEGA = UnitsFactor(string='MEGA')
Mega 10^6. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- MICRO = UnitsFactor(string='MICRO')
Micro 10^-6. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- MILLI = UnitsFactor(string='MILLI')
Milli 10^-3. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- NANO = UnitsFactor(string='NANO')
Nano 10^-9. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- ONE = UnitsFactor(string='ONE')
One. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- PEBI = UnitsFactor(string='PEBI')
Pebi 2^50, 1024^5. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- PETA = UnitsFactor(string='PETA')
Peta 10^15. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- PIKO = UnitsFactor(string='PIKO')
Pico 10^-12. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- TEBI = UnitsFactor(string='TEBI')
Tebi 2^40, 1024^4. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- TERA = UnitsFactor(string='TERA')
Tera 10^12. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- YOBI = UnitsFactor(string='YOBI')
Yobi 2^80, 1024^8. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- YOCTO = UnitsFactor(string='YOCTO')
Yocto 10^-24. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- YOTTA = UnitsFactor(string='YOTTA')
Yotta 10^24. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- ZEBI = UnitsFactor(string='ZEBI')
Zebi 2^70, 1024^7. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- ZEPTO = UnitsFactor(string='ZEPTO')
Zepto 10^-21. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- ZETTA = UnitsFactor(string='ZETTA')
Zetta 10^21. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- get(cid, mid)
Returns information about a specific CounterMetadata. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
cid (
str
) – Counter ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.Counter
.mid (
str
) – CounterMetadata ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
.
- Return type:
- Returns:
Information about the desired CounterMetadata.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if Counter or CounterMetadata could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- get_default(cid)
This method returns the “default” CounterMetadata. A Counter has at least one related metadata object. Usually, stats providers (for example hosts) are in agreement about the default metadata. In this case the returned list has a single metadata object.
Sometimes, when providers are in “disagreement” about the default, then the returned list would include all the possible “defaults”. This potential ambiguity isn’t a real issue because consumers of the vStats API rarely need to specify the “mid” of metadata. Therefore, this API is used primarily for informational purposes.. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
cid (
str
) – Counter ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.Counter
.- Return type:
- Returns:
List of counter metadata records.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifcid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if Counter could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- list(cid, filter=None)
Returns information about all counter metadata records for a specific Counter. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
cid (
str
) – Counter ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.Counter
.filter (
CounterMetadata.FilterSpec
orNone
) – Filter specification. When None no filtering will be performed.
- Return type:
- Returns:
List of counter metadata for the specified counter.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if Counter could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.CounterSets(config)
Bases:
VapiInterface
The
CounterSets
class provides methods for accessing groupings of counters. Counter-sets allow consumers to use groups of counters. The counters may relate to different resource types. When anAcqSpecs
record refers to a counter-set, only the relevant counters apply. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(id=None, counters=None, user_info=None)
Bases:
VapiStruct
The
CounterSets.Info
class contains information about a set of counters. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – Counter set identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.counters (
list
ofCidMid
) – List of Counter CidMids. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.user_info (
UserInfo
orNone
) – Human legible localizable conter set description. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. In future versions it may be possible to have custom counter sets that lack localizable descriptions.
- RESOURCE_TYPE = 'com.vmware.vstats.model.CounterSet'
Resource type for counter sets. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- get(counter_set)
Returns information about a specific counter set. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
counter_set (
str
) – identifier of the counter set to retrieve. The parameter must be an identifier for the resource type:com.vmware.vstats.model.CounterSet
.- Return type:
- Returns:
Information about the desired CounterSet.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifcounter_set
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if the requested counter set could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- list()
Returns information about all the counter sets. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Return type:
- Returns:
List of counter sets.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.Counters(config)
Bases:
VapiInterface
The
Counters
class provides methods to perform various Counter related operations. Counter is derived from metric. It applies the metric to a particular class of a resource. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(cid=None, types=None, metric=None)
Bases:
VapiStruct
The
Counters.FilterSpec
class contains fields that can be used to filter list of counters. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid (
str
orNone
) – Counter identifier that will be listed. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
. If None counter filter will not be applied.types (
list
ofstr
orNone
) – Resource type filter. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. If None resource type filter will not be applied.metric (
str
orNone
) – Metric for which counters will be listed. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Metric
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Metric
. If None metric filter will not be applied.
- class Info(cid=None, metric=None, resource_address_schema=None)
Bases:
VapiStruct
The
Counters.Info
class contains the counter information. Counter is derived from metric. It applies the metric to a particular class of a resource. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid (
str
) – Counter Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
.metric (
str
) – A metric is typically human-legible ASCII/English name of a measurable aspect, for example “length” and “temperature”. It is not internationalizable. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Metric
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Metric
.resource_address_schema (
str
) – Describes formally how to address (or identify) the resources the counter could be bound to (or instantiated for). Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.RsrcAddrSchema
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.RsrcAddrSchema
.
- RESOURCE_TYPE = 'com.vmware.vstats.model.Counter'
Resource type for counters. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- get(cid)
Returns information about a specific Counter. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
cid (
str
) – Counter ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.Counter
.- Return type:
- Returns:
Information about the requested counter.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifcid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if Counter could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- list(filter=None)
Returns information about all counters matching the filter parameters. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
filter (
Counters.FilterSpec
orNone
) – Filters the returned records. When None no filtering will be applied.- Return type:
- Returns:
List of Counters.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.Data(config)
Bases:
VapiInterface
The
Data
class provides methods to query measurement and statistic data. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class DataPoint(cid=None, mid=None, rid=None, ts=None, val=None)
Bases:
VapiStruct
The
Data.DataPoint
class is an instance of a measurement or stat. A data point is comprised of a Counter, CounterMetadata, Resource, timestamp and value. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
cid (
str
) – Counter Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
.mid (
str
) – CounterMetadata Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.CounterMetadata
.rid (
str
) – Resource Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.ts (
long
) – Timestamp for the data point. format: 64-bit integer. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.val (
float
) – Stat value. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class DataPointsResult(data_points=None, next=None)
Bases:
VapiStruct
The
Data.DataPointsResult
class contains attributes used to return DataPoints. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
data_points (
list
ofData.DataPoint
) – List of DataPoints received. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.next (
str
orNone
) – Thenext
attribute is a token used to retrieve paged data for larger result sets. This is opaque token generated by the server. It is to be sent in theData.FilterSpec.page
attribute to issue a subsequent call to the query method for retrieving results that did not fit the current page. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.set
when there are more results to retrieve.
- class FilterSpec(start=None, end=None, cid=None, metric=None, types=None, resources=None, order=None, page=None)
Bases:
VapiStruct
The
Data.FilterSpec
class contains attributes used to filter the results when listing DataPoint. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
start (
long
orNone
) – Start of a time window (included), timestamp in seconds UTC. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None the result will not be limited by start time.end (
long
orNone
) – End of a time window (excluded), timestamp in seconds UTC. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None the result will not be limited by end time.cid (
str
orNone
) – Counter ID. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Counter
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Counter
. When None the result will not be filtered by counter.metric (
str
orNone
) – Metric name. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Metric
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Metric
. When None the result will not be filtered by metric name.types (
list
ofstr
orNone
) – List of Resource types. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. When None the result will not be filtered by resource types.resources (
list
ofstr
orNone
) –Resources to include in the query. Each resource is specified through a composite string that follows the following format.
type.<resource type>[.<scheme>]=<resource id>
resource type specifies the type of resource for example
VM
,VCPU
etc.scheme is an optional element to disambiguate the resource as needed for example to differentiate managed object id from
uuid
.resource id is the unique resource identifier value for example:
vm-41
Example values include:
type.VM=vm-41
,type.VCPU=1
,type.VM.moid=vm-41
. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When left None the result will not be filtered for specific resources.order (
str
orNone
) – Directs the server to order the returned data. Passing a value ofDEFAULT
will apply default ordering of the results that makes them easier for consumption. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this parameter is None the server will not order the result, save computational time and therefore the API will operate faster.page (
str
orNone
) – Used to retrieve paged data for larger result sets. The value of this token is generated by server and returned asnext
attribute in the result ofqueryDataPoints
methods. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None the first page of results will be returned.
- query_data_points(filter=None)
Returns
Data.DataPointsResult
matching the filter parameters."/stats/data/dp?types=VM&types=VCPU"
"/stats/data/dp?rsrcs=type.HOST=host-16&rsrcs=type.VM=vm-31"
. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
filter (
Data.FilterSpec
orNone
) – Specification to match DataPoints. Whenset
filtering will be applied to the result.- Return type:
- Returns:
Data points matching the filter.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.Metrics(config)
Bases:
VapiInterface
The
Metrics
class provides method to list metrics. A metric is a fundamental concept. It means a measurable aspect or property. For instance, temperature, count, velocity, data size, bandwidth. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- RESOURCE_TYPE = 'com.vmware.vstats.model.Metric'
Resource type for metrics. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class Summary(metric=None)
Bases:
VapiStruct
The
Metrics.Summary
class contains metric summary. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
metric (
str
) – Metric name. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Metric
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Metric
.
- list()
Returns list of available Metrics as supplied by the discovered providers. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Return type:
- Returns:
List of Metrics.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.Providers(config)
Bases:
VapiInterface
The
Providers
class manages list of statistical data provider services that are currently used. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- RESOURCE_TYPE = 'com.vmware.vstats.model.Provider'
Resource type for data providers. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class Summary(id=None, id_value=None, type=None, scheme=None, metadata=None, tracking_sn=None)
Bases:
VapiStruct
Providers.Summary
class describes a statistical data provider. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – Provider identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.Provider
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.Provider
.id_value (
str
) – The ID given to the provider by its respective inventory. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.type (
str
) – Provider type. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.scheme (
str
orNone
) – An optional designation of the scheme. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When None the provider is not designating a specific scheme.metadata (
str
orNone
) – Schema-less metadata with extra information for the provider. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. As supplied by the provider.tracking_sn (
long
orNone
) – Timestamp which is obtained when querying counters from a provider and is used as since parameter when new counter listing is needed. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. {term unset} if no timestamp has been obtained yet.
- list()
Returns a list of stats providers. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Return type:
- Returns:
List of stats providers.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.QueryPredicate(string)
Bases:
Enum
The
QueryPredicate
enum describes how to query an id present in aRsrcId
. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.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 theQueryPredicate
instance.
- ALL = QueryPredicate(string='ALL')
Matching all available id-s. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EQUAL = QueryPredicate(string='EQUAL')
Matching id-s by equality. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class com.vmware.vstats_client.ResourceAddressSchemas(config)
Bases:
VapiInterface
The
ResourceAddressSchemas
class manages inventory of resource addressing schemas used byCounters
. Each schema consists of a named list of resource identifiers of specific resource type. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class Info(id=None, schema=None)
Bases:
VapiStruct
The
ResourceAddressSchemas.Info
class defines addressing schema for a counter. This is set of named placeholders for different resource types. For example a network link between VMs will take two arguments “source” and “destination” both of type VM. For each argument query capability is defined. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – Identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.RsrcAddrSchema
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.RsrcAddrSchema
.schema (
list
ofResourceAddressSchemas.ResourceIdDefinition
) – List of :class:`ResourceAddressSchemas.ResourceIdDefinition`s. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class QueryCapabilities(string)
Bases:
Enum
Declares which predicates are supported by the
ResourceAddressSchemas.ResourceIdDefinition
. Warning: This enumeration is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.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 theQueryCapabilities
instance.
- EQUAL = QueryCapabilities(string='EQUAL')
Equal. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- EQUAL_ALL = QueryCapabilities(string='EQUAL_ALL')
Supports both Equality and Aggregation. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- RESOURCE_TYPE = 'com.vmware.vstats.model.RsrcAddrSchema'
Resource type for resource addressing schemas. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class ResourceIdDefinition(key=None, type=None, query_options=None)
Bases:
VapiStruct
The
ResourceAddressSchemas.ResourceIdDefinition
class describes a single identifier of the Resource Addressing Schema. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
key (
str
) – Designates a semantic key for the resource identifier. This could be “vm” for virtual machine whose CPU usage is metered or “source” to identify the virtual machine that is origin of measured network traffic. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.type (
str
) – Type of the resource. This represents various entities for which statistical data is gathered such as virtual machines, containers, servers, disks etc. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.RsrcType
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.RsrcType
.query_options (
ResourceAddressSchemas.QueryCapabilities
) – Designates the supported query-options. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- get(id)
Returns information about a specific resource address schema. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
id (
str
) – Resource address schema identifier.- Return type:
- Returns:
Information about the desired resource address schema.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if RsrcAddrSchema could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.ResourceAddresses(config)
Bases:
VapiInterface
The
ResourceAddresses
class provides methods to perform resource addressing queries. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- class FilterSpec(types=None, resources=None, page=None)
Bases:
VapiStruct
ResourceAddresses.FilterSpec
class describes filter criteria for resource addresses. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
types (
list
ofstr
orNone
) – List of Resource types. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type:com.vmware.vstats.model.RsrcType
. When None the result will not be filtered by resource types.resources (
list
ofstr
orNone
) –Resources to include in the query. Each resource is specified through a composite string that follows the following format.
type.<resource type>[.<scheme>]=<resource id>
resource type specifies the type of resource for example
VM
,VCPU
etc.scheme is an optional element to disambiguate the resource as needed for example to differentiate managed object id from
uuid
.resource id is the unique resource identifier value for example:
vm-41
Example values include:
type.VM=vm-41
,type.VCPU=1
,type.VM.moid=vm-41
. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When left None the result will not be filtered for specific resources.page (
str
orNone
) – Thepage
field is used to retrieve paged data for large result sets. It is an opaque paging token obtained from a prior call to theResourceAddresses.list()
API. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. whenset
a follow up page in a paged result set will be delivered.
- class Info(id=None, resource_ids=None)
Bases:
VapiStruct
The
ResourceAddresses.Info
class contains global address of a specific Resource. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
id (
str
) – Identifier. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.RsrcAddr
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.RsrcAddr
.resource_ids (
list
ofRsrcId
) – List of Resource Identifiers. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class ListResult(rsrc_addrs=None, next=None)
Bases:
VapiStruct
The
ResourceAddresses.ListResult
class contains attributes used to return the resource addresses. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
rsrc_addrs (
list
ofResourceAddresses.Info
) – List of Resource Addresses received. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.next (
str
orNone
) – Used to retrieve paged data for larger result sets. Token is generated by server. The value of this field should be supplied in a subsequent call toResourceAddresses.list()
method. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. None when there are no more pages of data to be retrieved.
- RESOURCE_TYPE = 'com.vmware.vstats.model.RsrcAddr'
Resource type for
ResourceAddresses
. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- get(id)
Returns information about a specific Resource Address. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
id (
str
) – Resource Address ID. The parameter must be an identifier for the resource type:com.vmware.vstats.model.RsrcAddr
.- Return type:
- Returns:
Information about the desired Resource Address.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
ifid
is invalid.- Raise:
com.vmware.vapi.std.errors_client.NotFound
if Resource Address could not be located.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- list(filter=None)
Returns the list of Resource Addresses matching the filter parameters. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
filter (
ResourceAddresses.FilterSpec
orNone
) – Criteria for selecting records to return. If None all records will be returned.- Return type:
- Returns:
Matching resource addresses.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.InvalidArgument
if any of the specified parameters are invalid.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.ResourceTypes(config)
Bases:
VapiInterface
The
ResourceTypes
class provides list of resource types. Resource refers to any item or concept that could have measurable properties. It is a prerequisite that a resource can be identified.Example resource types are virtual machine, virtual disk etc.. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Parameters:
config (
vmware.vapi.bindings.stub.StubConfiguration
) – Configuration to be used for creating the stub.
- RESOURCE_TYPE = 'com.vmware.vstats.model.RsrcType'
Resource type for resource types. Warning: This class attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- class Summary(type=None)
Bases:
VapiStruct
The
ResourceTypes.Summary
class contains information of addressable resource. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
type (
str
) – Resource type. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type:com.vmware.vstats.model.RsrcType
. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type:com.vmware.vstats.model.RsrcType
.
- list()
Returns a list of available resource types. Warning: This method is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.
- Return type:
- Returns:
List of resource types.
- Raise:
com.vmware.vapi.std.errors_client.Error
if the system reports an error while responding to the request.- Raise:
com.vmware.vapi.std.errors_client.Unauthenticated
if the user can not be authenticated.- Raise:
com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have sufficient privileges.
- class com.vmware.vstats_client.RsrcId(key=None, type=None, id_value=None, predicate=None, scheme=None)
Bases:
VapiStruct
The
RsrcId
class specifies identification of a resource to be monitored by an acquisition specification record. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
key (
str
orNone
) – Key relates to the corresponding ResourceIdDefinition of the related resource address schema. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None, type attribute will be used.type (
str
orNone
) – Type of the resource identified by the Resource Id. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None, in current version the api will throw InvalidArgument error. To be made optional in future.id_value (
str
) – The id value binding the related resource id definition. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.predicate (
QueryPredicate
orNone
) – Predicate to use to match resource Ids. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None, default predicate is EQUAL.scheme (
str
orNone
) – An optional designation of the scheme. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments. When this attribute is None, default scheme is moid (ManagedObject Identifier).
- class com.vmware.vstats_client.StubFactory(stub_config)
Bases:
StubFactoryBase
Initialize StubFactoryBase
- Parameters:
stub_config (
vmware.vapi.bindings.stub.StubConfiguration
) – Stub config instance
- class com.vmware.vstats_client.UserInfo(label=None, description=None)
Bases:
VapiStruct
The
UserInfo
class contains human legible, localizable description, used for VMware provided objects. Warning: This class is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.Tip
The arguments are used to initialize data attributes with the same names.
- Parameters:
label (
com.vmware.vapi.std_client.LocalizableMessage
) – Short label. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.description (
com.vmware.vapi.std_client.LocalizableMessage
) – Detailed description of the object. Warning: This attribute is available as Technology Preview. These are early access APIs provided to test, automate and provide feedback on the feature. Since this can change based on feedback, VMware does not guarantee backwards compatibility and recommends against using them in production environments. Some Technology Preview APIs might only be applicable to specific environments.