Update Subscribed Library
Updates the properties of a subscribed library. This is an incremental update to the subscribed library. Fields that are unset in the update specification will be left unchanged.
if you do not have all of the privileges described as follows: - The resource com.vmware.content.Library referenced by the parameter libraryId requires ContentLibrary.UpdateSubscribedLibrary.
Request
URLURL
Path Parameters
Path Parameters
Identifier of the subscribed library to update. The parameter must be an identifier for the resource type: com.vmware.content.Library.
Header Parameters
Header Parameters
Required session ID, acquired from Create Session API under CIS product
vmware-api-session-id example
"b00db39f948d13ea1e59b4d6fce56389"
Request Body
Specification of the new property values to set on the subscribed library.
{
"creation_time": "string",
"description": "string",
"id": "string",
"last_modified_time": "string",
"last_sync_time": "string",
"name": "string",
"optimization_info": {
"optimize_remote_publishing": false
},
"publish_info": {
"authentication_method": "BASIC",
"current_password": "string",
"password": "string",
"persist_json_enabled": false,
"publish_url": "string",
"published": false,
"user_name": "string"
},
"security_policy_id": "string",
"server_guid": "string",
"storage_backings": [
{
"datastore_id": "string",
"storage_uri": "string",
"type": "DATASTORE"
}
],
"subscription_info": {
"authentication_method": "BASIC",
"automatic_sync_enabled": false,
"on_demand": false,
"password": "string",
"source_info": {
"source_library": "string",
"subscription": "string"
},
"ssl_thumbprint": "string",
"subscription_url": "string",
"user_name": "string"
},
"type": "LOCAL",
"unset_security_policy_id": false,
"version": "string"
}
The date and time when this library was created. This field is not used for the create operation. It will always be present in the result of the get or list operations. It is not used for the update operation.
A human-readable description for this library. This field is optional for the create operation. Leaving it unset during creation will result in an empty string value. It will always be present in the result of a get or list operation. It is optional for the update operation. Leaving it unset during update indicates that the description should be left unchanged.
An identifier which uniquely identifies this LibraryModel. This field is not used for the create operation. It will not be present in the result of the get or list operations. It is not used for the update operation. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.Library. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.Library.
The date and time when this library was last updated. This field is updated automatically when the library properties are changed. This field 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 field.
This field is not used for the create operation. It will always be present in the result of the get or list operations. It is not used for the update operation.
The date and time when this library was last synchronized. This field applies only to subscribed libraries. It is updated every time a synchronization is triggered on the library. The value is unset for a local library.
This field is not used for the create operation. It is optional in the result of the get or list operations. It is not used for the update operation.
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 field must be provided for the create operation. It will always be present in the result of the get or list operations. It is optional for the update operation.
Defines various optimizations and optimization parameters applied to this library. This field is optional for the create operation. It is optional in the result of the get or list operations. It is optional for the update operation.
Defines how this library is published so that it can be subscribed to by a remote subscribed library. The PublishInfo defines where and how the metadata for this local library is accessible. A local library is only published publically if PublishInfo.published is true.
This field is optional for the create and update operations. If not specified during creation, the default is for the library to not be published. If not specified during update, the field is left unchanged.
Represents the security policy applied to this library. Setting the field will make the library secure. This field is ignored in update operation if LibraryModel.unset-security-policy-id is set to true.
This field is optional for the create and update operations. If not set in create operation, the library will be insecure. If not specified in update operation, the field is left unchanged. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.Library. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.Library.
The unique identifier of the vCenter server where the library exists. This field is optional for the create operation. It will always be present in the result of the get or list operations. It is not used for the update operation. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.vcenter.VCenter. When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.vcenter.VCenter.
The list of default storage backings which are available for this library. A 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 field must be provided for the create operation. It will always be present in the result of the get or list operations. It is not used for the update operation.
Defines the subscription behavior for this Library. The 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. Setting SubscriptionInfo.automatic-sync-enabled to false will halt subscription but will not remove existing cached data.
This field is optional for the create and update operations. If not specified during creation, a default will be created without an active subscription. If not specified during update, the field is left unchanged.
The LibraryModel.LibraryType enumerated type defines the type of a LibraryModel.
The type of a library can be used to determine which additional services can be performed with a library.
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 : The library synchronizes its items and content from another published library.
A subscribed library can be retrieved and managed via the SubscribedLibrary.
Possible values are: LOCAL , SUBSCRIBED
This represents the intent of the change to LibraryModel.security-policy-id in update operation. If this field is set to true, any security policy applied to the library will be removed. If this field is set to false, any security policy applied to library will be changed to the value specified in LibraryModel.security-policy-id, if any.
This field is optional for the update operation. If unset, any existing security policy will be changed to the value specified in LibraryModel.security-policy-id, if any.
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 field is not used for the create operation. It will always be present in the result of a get or list operation. It is optional for the update operation. Leaving it unset during update indicates that you do not need to detect concurrent updates.
Authentication
Errors
Errors
com.vmware.vapi.std.errors.not_allowed_in_current_state : if the updateSpec updates the subscription URL (see SubscriptionInfo.subscription-url) and the content of the library specified by libraryId has been deleted from the storage backings (see LibraryModel.storage-backings) associated with it. | com.vmware.vapi.std.errors.invalid_element_type : if the library specified by libraryId is not a subscribed library. | com.vmware.vapi.std.errors.invalid_argument : if the updateSpec is not valid.
com.vmware.vapi.std.errors.not_found : if the library specified by libraryId does not exist.
com.vmware.vapi.std.errors.concurrent_change : if the LibraryModel.version of updateSpec is not equal to the current version of the library.
com.vmware.vapi.std.errors.resource_inaccessible : if the subscription info is being updated but the published library cannot be contacted or found. | com.vmware.vapi.std.errors.resource_busy : if the LibraryModel.version of updateSpec is unset and the library is being concurrently updated by another user.
‘Default’ means this response is used for all HTTP codes that are not covered individually for this operation.
Code Samples
PowerCLI Client SDK Example
cURL Command
Vendor Extensions
x-vmw-doc-deprecated-method: patch
x-vmw-doc-deprecated-path: /rest/com/vmware/content/subscribed-library/id:{library_id}
x-vmw-doc-operation: update