com.vmware.cis package¶
Submodules¶
com.vmware.cis.tagging_client module¶
The com.vmware.cis.tagging_client
component provides methods and classes to
attach metadata, by means of tags, to vSphere objects to make these objects
more sortable and searchable. You can use it to create, manage, and enumerate
tags and their categories (the group a tag belongs to). You can also query the
attached tags and attached objects.
-
class
com.vmware.cis.tagging_client.
Category
(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterface
The
Category
class provides methods to create, read, update, delete, and enumerate categories.-
class
CreateSpec
(name=None, description=None, cardinality=None, associable_types=None, category_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
Category.CreateSpec
class is used to create a category.Use the
Category.create()
method to create a category defined by the create specification.Tip
The arguments are used to initialize data attributes with the same names.
-
class
UpdateSpec
(name=None, description=None, cardinality=None, associable_types=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
Category.UpdateSpec
class describes the updates to be made to an existing category.Use the
Category.update()
method to modify a category. When you call the method, specify the category identifier. You obtain the category identifier when you call theCategory.create()
method. You can also retrieve an identifier by using theCategory.list()
method.Tip
The arguments are used to initialize data attributes with the same names.
-
add_to_used_by
(category_id, used_by_entity)¶ Adds the
used_by_entity
to theCategoryModel.used_by
subscribersset
for the specified category. If theused_by_entity
is already in theset
, then this becomes an idempotent no-op. To invoke this method, you need the modifyCategoryModel.used_by
privilege on the category.Parameters: - category_id (
str
) – The identifier of the input category. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
. - used_by_entity (
str
) – The name of the user to be added to theCategoryModel.used_by
set
.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to add an entity to theCategoryModel.used_by
field.- category_id (
-
create
(create_spec)¶ Creates a category. To invoke this method, you need the create category privilege.
Parameters: create_spec ( Category.CreateSpec
) – Specification for the new category to be created.Return type: str
Returns: The identifier of the created category. The return value will be an identifier for the resource type: com.vmware.cis.tagging.Category
.Raise: com.vmware.vapi.std.errors_client.AlreadyExists
if theCategory.CreateSpec.name
provided in thecreate_spec
is the name of an already existing category.Raise: com.vmware.vapi.std.errors_client.InvalidArgument
if any of the information in thecreate_spec
is invalid.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to create a category.
-
delete
(category_id)¶ Deletes an existing category. To invoke this method, you need the delete privilege on the category.
Parameters: category_id ( str
) – The identifier of category to be deleted. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to delete the category.
-
get
(category_id)¶ Fetches the category information for the given category identifier. In order to view the category information, you need the read privilege on the category.
Parameters: category_id ( str
) – The identifier of the input category. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
.Return type: CategoryModel
Returns: The CategoryModel
that corresponds tocategory_id
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the category.
-
list
()¶ Enumerates the categories in the system. To invoke this method, you need the read privilege on the individual categories. The
list
will only contain those categories for which you have read privileges.Return type: list
ofstr
Returns: The list
of resource identifiers for the categories in the system. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Category
.
-
list_used_categories
(used_by_entity)¶ Enumerates all categories for which the
used_by_entity
is part of theCategoryModel.used_by
subscribersset
. To invoke this method, you need the read privilege on the individual categories.Parameters: used_by_entity ( str
) – The field on which the results will be filtered.Return type: list
ofstr
Returns: The list
of resource identifiers for the categories in the system that are used byused_by_entity
. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Category
.
-
remove_from_used_by
(category_id, used_by_entity)¶ Removes the
used_by_entity
from theCategoryModel.used_by
subscribersset
. If theused_by_entity
is not using this category, then this becomes a no-op. To invoke this method, you need the modifyCategoryModel.used_by
privilege on the category.Parameters: - category_id (
str
) – The identifier of the input category. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
. - used_by_entity (
str
) – The name of the user to be removed from theCategoryModel.used_by
set
.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to remove an entity from theCategoryModel.used_by
field.- category_id (
-
revoke_propagating_permissions
(category_id)¶ Revokes all propagating permissions on the given category. You should then attach a direct permission with tagging privileges on the given category. To invoke this method, you need category related privileges (direct or propagating) on the concerned category.
Parameters: category_id ( str
) – The identifier of the input category. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to revoke propagating permissions on the category.
-
update
(category_id, update_spec)¶ Updates an existing category. To invoke this method, you need the edit privilege on the category.
Parameters: - category_id (
str
) – The identifier of the category to be updated. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
. - update_spec (
Category.UpdateSpec
) – Specification to update the category.
Raise: com.vmware.vapi.std.errors_client.AlreadyExists
if theCategory.UpdateSpec.name
provided in theupdate_spec
is the name of an already existing category.Raise: com.vmware.vapi.std.errors_client.InvalidArgument
if any of the information in theupdate_spec
is invalid.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to update the category.- category_id (
-
class
-
class
com.vmware.cis.tagging_client.
CategoryModel
(id=None, name=None, description=None, cardinality=None, associable_types=None, used_by=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
CategoryModel
class defines a category that is used to group one or more tags.Tip
The arguments are used to initialize data attributes with the same names.
-
class
Cardinality
(string)¶ Bases:
vmware.vapi.bindings.enum.Enum
The
CategoryModel.Cardinality
class defines the number of tags in a category that can be assigned to an object.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.
-
MULTIPLE
= Cardinality(string='MULTIPLE')¶ An object can be assigned several of the tags in this category. For example, if a category is “Server”, then different tags of this category would be “AppServer”, “DatabaseServer” and so on. In this case a VM object can be assigned more than one of the above tags and hence the cardinality of the associated category here is multiple.
-
SINGLE
= Cardinality(string='SINGLE')¶ An object can only be assigned one of the tags in this category. For example, if a category is “Operating System”, then different tags of this category would be “Windows”, “Linux”, and so on. In this case a VM object can be assigned only one of these tags and hence the cardinality of the associated category here is single.
-
-
class
-
class
com.vmware.cis.tagging_client.
StubFactory
(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBase
-
class
com.vmware.cis.tagging_client.
Tag
(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterface
The
Tag
class provides methods to create, read, update, delete, and enumerate tags.-
class
CreateSpec
(name=None, description=None, category_id=None, tag_id=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
Tag.CreateSpec
class describes a tag.Use the
Tag.create()
method to create a tag defined by the create specification.Tip
The arguments are used to initialize data attributes with the same names.
-
class
UpdateSpec
(name=None, description=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
Tag.UpdateSpec
class describes the updates to be made to an existing tag.Use the
Tag.update()
method to modify a tag. When you call the method, you specify the tag identifier. You obtain the tag identifier when you call theTag.create()
method. You can also retrieve an identifier by using theTag.list()
method.Tip
The arguments are used to initialize data attributes with the same names.
-
add_to_used_by
(tag_id, used_by_entity)¶ Adds the
used_by_entity
to theTagModel.used_by
subscribersset
. If theused_by_entity
is already in theset
, then this becomes a no-op. To invoke this method, you need the modifyTagModel.used_by
privilege on the tag.Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - used_by_entity (
str
) – The name of the user to be added to theTagModel.used_by
set
.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to add an entity to theTagModel.used_by
field.- tag_id (
-
create
(create_spec)¶ Creates a tag. To invoke this method, you need the create tag privilege on the input category.
Parameters: create_spec ( Tag.CreateSpec
) – Specification for the new tag to be created.Return type: str
Returns: The identifier of the created tag. The return value will be an identifier for the resource type: com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.AlreadyExists
if theTag.CreateSpec.name
provided in thecreate_spec
is the name of an already existing tag in the input category.Raise: com.vmware.vapi.std.errors_client.InvalidArgument
if any of the input information in thecreate_spec
is invalid.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for in the givencreate_spec
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to create tag.
-
delete
(tag_id)¶ Deletes an existing tag. To invoke this method, you need the delete privilege on the tag.
Parameters: tag_id ( str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to delete the tag.
-
get
(tag_id)¶ Fetches the tag information for the given tag identifier. To invoke this method, you need the read privilege on the tag in order to view the tag info.
Parameters: tag_id ( str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
.Return type: TagModel
Returns: The TagModel
that corresponds totag_id
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if the user does not have the privilege to read the tag.
-
list
()¶ Enumerates the tags in the system. To invoke this method, you need read privilege on the individual tags. The
list
will only contain tags for which you have read privileges.Return type: list
ofstr
Returns: The list
of resource identifiers for the tags in the system. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.
Enumerates all tags for the given category. To invoke this method, you need the read privilege on the given category and the individual tags in that category.
Parameters: category_id ( str
) – The identifier of the input category. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Category
.Return type: list
ofstr
Returns: The list
of resource identifiers for the tags in the given input category. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the category for the givencategory_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the category.
Enumerates all tags for which the
used_by_entity
is part of theTagModel.used_by
subscribersset
. To invoke this method, you need the read privilege on the individual tags.Parameters: used_by_entity ( str
) – The field on which the results will be filtered.Return type: list
ofstr
Returns: The list
of resource identifiers for the tags in the system that are used byused_by_entity
. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.
-
remove_from_used_by
(tag_id, used_by_entity)¶ Removes the
used_by_entity
from theTagModel.used_by
subscribers set. If theused_by_entity
is not using this tag, then this becomes a no-op. To invoke this method, you need modifyTagModel.used_by
privilege on the tag.Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - used_by_entity (
str
) – The name of the user to be removed from theTagModel.used_by
set
.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to remove an entity from theTagModel.used_by
field.- tag_id (
-
revoke_propagating_permissions
(tag_id)¶ Revokes all propagating permissions on the given tag. You should then attach a direct permission with tagging privileges on the given tag. To invoke this method, you need tag related privileges (direct or propagating) on the concerned tag.
Parameters: tag_id ( str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to revoke propagating permissions on the tag.
-
update
(tag_id, update_spec)¶ Updates an existing tag. To invoke this method, you need the edit privilege on the tag.
Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - update_spec (
Tag.UpdateSpec
) – Specification to update the tag.
Raise: com.vmware.vapi.std.errors_client.AlreadyExists
if theTag.UpdateSpec.name
provided in theupdate_spec
is the name of an already existing tag in the same category.Raise: com.vmware.vapi.std.errors_client.InvalidArgument
if any of the input information in theupdate_spec
is invalid.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to update the tag.- tag_id (
-
class
-
class
com.vmware.cis.tagging_client.
TagAssociation
(config)¶ Bases:
vmware.vapi.bindings.stub.VapiInterface
The
TagAssociation
class provides methods to attach, detach, and query tags.-
class
BatchResult
(success=None, error_messages=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
TagAssociation.BatchResult
class describes the result of performing the same method on several tags or objects in a single invocation. This class was added in vSphere API 6.5Tip
The arguments are used to initialize data attributes with the same names.
-
class
ObjectToTags
(object_id=None, tag_ids=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
TagAssociation.ObjectToTags
class describes an object and its related tags. Use theTagAssociation.list_attached_tags_on_objects()
method to retrieve alist
with each element containing an object and the tags attached to it. This class was added in vSphere API 6.5Tip
The arguments are used to initialize data attributes with the same names.
-
class
TagToObjects
(tag_id=None, object_ids=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
TagAssociation.TagToObjects
class describes a tag and its related objects. Use theTagAssociation.list_attached_objects_on_tags()
method to retrieve alist
with each element containing a tag and the objects to which it is attached. This class was added in vSphere API 6.5Tip
The arguments are used to initialize data attributes with the same names.
-
attach
(tag_id, object_id)¶ Attaches the given tag to the input object. The tag needs to meet the cardinality (
CategoryModel.cardinality
) and associability (CategoryModel.associable_types
) criteria in order to be eligible for attachment. If the tag is already attached to the object, then this method is a no-op and an error will not be thrown. To invoke this method, you need the attach tag privilege on the tag and the read privilege on the object.Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - object_id (
com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.InvalidArgument
if the input tag is not eligible to be attached to this object or if theobject_id
is not valid.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to attach the tag or do not have the privilege to read the object.- tag_id (
Attaches the given tags to the input object. If a tag is already attached to the object, then the individual method is a no-op and an error will not be added to
TagAssociation.BatchResult.error_messages
. To invoke this method, you need the read privilege on the object and the attach tag privilege on each tag. This method was added in vSphere API 6.5Parameters: - object_id (
com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object. - tag_ids (
list
ofstr
) – The identifiers of the input tags. The parameter must contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.
Return type: Returns: The outcome of the batch method and the
list
of error messages (TagAssociation.BatchResult.error_messages
) describing attachment failures.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the object.- object_id (
-
attach_tag_to_multiple_objects
(tag_id, object_ids)¶ Attaches the given tag to the input objects. If a tag is already attached to the object, then the individual method is a no-op and an error will not be added to
TagAssociation.BatchResult.error_messages
. To invoke this method, you need the attach tag privilege on the tag and the read privilege on each object. This method was added in vSphere API 6.5Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - object_ids (
list
ofcom.vmware.vapi.std_client.DynamicID
) – The identifiers of the input objects.
Return type: Returns: The outcome of the batch method and the
list
of error messages (TagAssociation.BatchResult.error_messages
) describing attachment failures.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the attach tag privilege on the tag.- tag_id (
-
detach
(tag_id, object_id)¶ Detaches the tag from the given object. If the tag is already removed from the object, then this method is a no-op and an error will not be thrown. To invoke this method, you need the attach tag privilege on the tag and the read privilege on the object.
Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - object_id (
com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object.
Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to detach the tag or do not have the privilege to read the given object.- tag_id (
Detaches the given tags from the input object. If a tag is already removed from the object, then the individual method is a no-op and an error will not be added to
TagAssociation.BatchResult.error_messages
. To invoke this method, you need the read privilege on the object and the attach tag privilege each tag. This method was added in vSphere API 6.5Parameters: - object_id (
com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object. - tag_ids (
list
ofstr
) – The identifiers of the input tags. The parameter must contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.
Return type: Returns: The outcome of the batch method and the
list
of error messages (TagAssociation.BatchResult.error_messages
) describing detachment failures.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the object.- object_id (
-
detach_tag_from_multiple_objects
(tag_id, object_ids)¶ Detaches the given tag from the input objects. If a tag is already removed from the object, then the individual method is a no-op and an error will not be added to
TagAssociation.BatchResult.error_messages
. To invoke this method, you need the attach tag privilege on the tag and the read privilege on each object. This method was added in vSphere API 6.5Parameters: - tag_id (
str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
. - object_ids (
list
ofcom.vmware.vapi.std_client.DynamicID
) – The identifiers of the input objects.
Return type: Returns: The outcome of the batch method and the
list
of error messages (TagAssociation.BatchResult.error_messages
) describing detachment failures.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the given tag does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the attach tag privilege on the tag.- tag_id (
Fetches the
list
of attachable tags for the given object, omitting the tags that have already been attached. Criteria for attachability is calculated based on tagging cardinality (CategoryModel.cardinality
) and associability (CategoryModel.associable_types
) constructs. To invoke this method, you need the read privilege on the input object. Thelist
will only contain those tags for which you have read privileges.Parameters: object_id ( com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object.Return type: list
ofstr
Returns: The list
of tag identifiers that are eligible to be attached to the given object. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the object.
-
list_attached_objects
(tag_id)¶ Fetches the
list
of attached objects for the given tag. To invoke this method, you need the read privilege on the input tag. Only those objects for which you have the read privilege will be returned.Parameters: tag_id ( str
) – The identifier of the input tag. The parameter must be an identifier for the resource type:com.vmware.cis.tagging.Tag
.Return type: list
ofcom.vmware.vapi.std_client.DynamicID
Returns: The list
of attached object identifiers.Raise: com.vmware.vapi.std.errors_client.NotFound
if the tag for the giventag_id
does not exist in the system.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the tag.
Fetches the
list
ofTagAssociation.TagToObjects
describing the input tag identifiers and the objects they are attached to. To invoke this method, you need the read privilege on each input tag. TheTagAssociation.TagToObjects.object_ids
will only contain those objects for which you have the read privilege. This method was added in vSphere API 6.5Parameters: tag_ids ( list
ofstr
) – The identifiers of the input tags. The parameter must contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.Return type: list
ofTagAssociation.TagToObjects
Returns: The list
of the tag identifiers to all object identifiers that each tag is attached to.
Fetches the
list
of tags attached to the given object. To invoke this method, you need the read privilege on the input object. Thelist
will only contain those tags for which you have the read privileges.Parameters: object_id ( com.vmware.vapi.std_client.DynamicID
) – The identifier of the input object.Return type: list
ofstr
Returns: The list
of all tag identifiers that correspond to the tags attached to the given object. The return value will contain identifiers for the resource type:com.vmware.cis.tagging.Tag
.Raise: com.vmware.vapi.std.errors_client.Unauthorized
if you do not have the privilege to read the object.
Fetches the
list
ofTagAssociation.ObjectToTags
describing the input object identifiers and the tags attached to each object. To invoke this method, you need the read privilege on each input object. TheTagAssociation.ObjectToTags.tag_ids
will only contain those tags for which you have the read privilege. This method was added in vSphere API 6.5Parameters: object_ids ( list
ofcom.vmware.vapi.std_client.DynamicID
) – The identifiers of the input objects.Return type: list
ofTagAssociation.ObjectToTags
Returns: The list
of the object identifiers to all tag identifiers that are attached to that object.
-
class
-
class
com.vmware.cis.tagging_client.
TagModel
(id=None, category_id=None, name=None, description=None, used_by=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
TagModel
class defines a tag that can be attached to vSphere objects.Tip
The arguments are used to initialize data attributes with the same names.
com.vmware.cis.task_client module¶
The com.vmware.cis.task_client
module provides classes and classes used for
managing tasks.
-
class
com.vmware.cis.task_client.
CommonInfo
(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:
vmware.vapi.bindings.struct.VapiStruct
The
CommonInfo
class contains information common to all tasks. This class was added in vSphere API 6.7Tip
The arguments are used to initialize data attributes with the same names.
-
class
com.vmware.cis.task_client.
Info
(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:
vmware.vapi.bindings.struct.VapiStruct
The
Info
class contains information about a task. This class was added in vSphere API 6.7Tip
The arguments are used to initialize data attributes with the same names.
-
class
com.vmware.cis.task_client.
Progress
(total=None, completed=None, message=None)¶ Bases:
vmware.vapi.bindings.struct.VapiStruct
The
Progress
class contains information describe the progress of an operation. This class was added in vSphere API 6.7Tip
The arguments are used to initialize data attributes with the same names.
-
class
com.vmware.cis.task_client.
Status
(string)¶ Bases:
vmware.vapi.bindings.enum.Enum
The
Status
class defines the status values that can be reported for an operation. This enumeration was added in vSphere API 6.7Note
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.
-
BLOCKED
= Status(string='BLOCKED')¶ The operation is blocked. This class attribute was added in vSphere API 6.7
-
FAILED
= Status(string='FAILED')¶ The operation failed. This class attribute was added in vSphere API 6.7
-
PENDING
= Status(string='PENDING')¶ The operation is in pending state. This class attribute was added in vSphere API 6.7
-
RUNNING
= Status(string='RUNNING')¶ The operation is in progress. This class attribute was added in vSphere API 6.7
-
SUCCEEDED
= Status(string='SUCCEEDED')¶ The operation completed successfully. This class attribute was added in vSphere API 6.7
-
-
class
com.vmware.cis.task_client.
StubFactory
(stub_config)¶ Bases:
vmware.vapi.bindings.stub.StubFactoryBase