This article explains how to convert the old editor style of a page to a new editor in the cloud using the Confluence Command Line Interface (CLI).
Instructions
To convert a single page into a new editor,: use Use the renderRequest action as given below below:
Code Block theme Midnight --action renderRequest --request "/rest/api/content/506527918/convert?hash=13" --type "JSON" --requestType PUT
In the above action command, the 506527918 within the URL refers to the page id.
To convert multiple pages to the new editor, use : Use the renderRequest action along with runFromPageList as given below:
Code Block theme Midnight --action runFromPageList --space KT --common "--action renderRequest --request "/rest/api/content/@contentId@/convert\?\hash=13" --type "JSON" --requestType PUT" --continue
To convert multiple pages to the new editor that are modified from a specific date, use : Use the --cql parameter along with the action as given below:
Code Block theme Midnight --action runFromPageList --cql "space = "HTML" AND lastModified > "2020-12-11" " --common "--action renderRequest --request "/rest/api/content/@contentId@/convert\?\hash=13" --type "JSON" --requestType PUT" --continue
The above actions contain the following parameters:
--space: Space key
--request: URL fragment for a request.
--type: Application type, shortcut type, content type, or similar depending on the context.
--requestType: Type of a render request like GET or POST.
--cql: CQL content search.
Info |
---|
It is recommended to test the commands in a non-production environment or run the action with the --simulate parameter to verify the behavior before deploying. |
...