-
Suggestion
-
Resolution: Unresolved
-
None
When using the Confluence API to copy a set of pages using the if the[ copy page hierarchy request|https://developer.atlassian.com/cloud/confluence/rest/api-group-content---children-and-descendants/#api-wiki-rest-api-content-id-pagehierarchy-copy-post] if the pages contain hyperlinks to each other then the pages created from the copy will be updated to point to the other copied pages.
We would like this functionality to be extended to the copy single page request so that if pages which link to each other are copied from the same hierarchy at different times the links within them are updated to point to the other copied pages rather than the originals they were copied from.
Steps to reproduce:
Create two pages "parent page" and "child page"
Create a hyper link in "child page" that points to "parent page"
Copy "parent page" to another space with:
curl -H "Authorization: Basic <AUTH_KEY>" -X POST -H "Content-Type: application/json" -d'{"destination":{"type":"space","value":<SPACE_ID>}}' https://<ATLASSIAN_INSTANCE>/wiki/rest/api/content/<parent page ID>/copy
Copy "child page" with:
curl -H "Authorization: Basic <AUTH_KEY>" -X POST -H "Content-Type: application/json" -d'{"destination":{"type":"parent_page","value":<parent page copy ID>}}' https://<ATLASSIAN_INSTANCE>/wiki/rest/api/content/<child page ID>/copy
Current result: the link on "child page copy" will point to the original parent page
Ideal result: the link on "child page copy" will point to the new copy of the parent page
- is related to
-
CONFCLOUD-73684 Copying a page will break its link
- Closed
-
CONFCLOUD-3191 Easily create a copy of an entire space
- Gathering Interest