Skip to main content
Version: 2.10

Copying contents via REST

This document explains how to copy contents inside a repository to new target folders using the Document.One (D1) REST API.

  1. Log in to D1 and open the repository where the contents to be moved are stored:

    Opening the content explorer

  2. Select the content you want to move. Copy the content's technical ID:

    Copying the content's technical ID

  3. Similarly, copy the technical ID of the target folder.

  4. Go back to the landing page and click the API link under content access where the contents to be updated are stored:

    Accessing the D1 REST API

    The OpenAPI page opens, showing the available D1 endpoints.

  5. Open the /access.adx.content.test/v1/content/checkout endpoint available under Versioning.

  6. Enter the content's technical ID into the contentId field:

    Filling out the contentId field

  7. Similarly, enter the technical ID of the target folder into the targetFolderId field.

  8. 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 new content ID. Copy the new content ID from the message:

    Copying the new content ID

  9. Open the /access.adx.content.test/v1/content/copy endpoint available under Content. Click Try it out to activate the fields.

  10. Enter the new content technical ID into the contentId field.

    Filling out the content ID field with the new content ID

  11. Change other properties if required.

  12. Click Execute and check the response. A response with status 200 (success) is expected, meaning that the content has been copied to the target folder. Check the content access again to verify this is the case.

  13. Open the /access.adx.content.test/v1/content/checkin endpoint available under Versioning.

  14. Paste the new content technical ID into the contentId field.

  15. Click Execute. Your copied content is now saved with a new version, with the status CURRENT.

OpenAPI

For code samples, see

Checkout by ID
Copy content by ID
Checkin by ID