Moving contents via REST
This document explains how to move contents within a repository to new target folders using Document.One (D1) REST API.
Log in to D1 and open the repository where the contents to be moved are stored.
Select the content you want to move. Copy the content's technical ID:
Similarly, copy the technical ID of the target folder.
Go back to the landing page and click the API link under content access where the contents to be updated are stored:
The OpenAPI page opens, showing the available D1 REST API endpoints.
Open the
/access.adx.content.test/v1/content/checkout
endpoint available under Versioning.Enter the content's technical ID into the contentId field:
Click Execute and check the response. A response with status
200
(success) is expected, meaning that the content is now checked out. At this point, a new version of the content is created, with a newcontentID
. Copy the newcontentID
from the message:Open the
/access.adx.content.test/v1/content/move
endpoint available under Content. Click Try it out to activate the fields.Enter the new content technical ID into the contentId field.
Similarly, enter the technical ID of the target folder into the targetFolderId field.
Change other properties if required.
Click Execute and check the response. A response with status
200
(success) is expected, meaning that the content has been moved. Check the content access again to verify this is the case.Open the
/access.adx.content.test/v1/content/checkin
endpoint available under Versioning.Paste the new content technical ID into the contentId field.
Click Execute. Your moved content is now saved with a new version, with the status
CURRENT
.
For code samples, see