REST API - sync
com.vmware.content.library.subscribed_item
sync
POST /com/vmware/content/library/subscribed-item/id:{library_item_id}?~action=sync |
POST /com/vmware/content/library/subscribed-item?~action=sync |
Forces the synchronization of an individual library item in a subscribed library.
Synchronizing an individual item will update that item's metadata from the remote source. If the source library item on the remote library has been deleted, this operation will delete the library item from the subscribed library as well.
The default behavior of the synchronization is determined by the com.vmware.content.library.subscription_info of the library which owns the library item.
- If com.vmware.content.library.subscription_info.on_demand is true, then the file content is not synchronized by default. In this case, only the library item metadata is synchronized. The file content may still be forcefully synchronized by passing true for the
force_sync_content
parameter. - If com.vmware.content.library.subscription_info.on_demand is false, then this call will always synchronize the file content. The
force_sync_content
parameter is ignored when the subscription is not on-demand.
This operation will return immediately and create an asynchronous task to perform the synchronization.
- Request:
-
- Representations:
{
"force_sync_content": true,
"library_item_id": "obj-103"
}<?xml version="1.0" ?>
<ns0:Sync-Input xmlns:ns0="http://vmware.com/content/library/subscribed_item" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<library_item_id>obj-103</library_item_id>
<force_sync_content>true</force_sync_content>
</ns0:Sync-Input>POST /com/vmware/content/library/subscribed-item?~action=sync
&library_item_id=obj-103
&force_sync_content=true- Parameters:
Name Type Required Description library_item_id *
ID Yes Identifier of the library item to synchronize. Id of type com.vmware.content.library.Item. force_sync_content *
boolean Yes Whether to synchronize file content as well as metadata. This parameter applies only if the subscription is on-demand. - Response:
-
- Representations:
- Parameters:
Name Type Required Description result VOID Yes - Errors:
-
Type Description HTTP Status Code not_found if the library item specified by library_item_id
could not be found.404 invalid_element_type if the library item specified by library_item_id
is not a member of a subscribed library.400
Copyright © 2014. All Rights Reserved.