The Copy Page Tree app must make pages unique in the destination space so that there are no page title conflicts.
When copying within a single space, when the destination space IS the origin space then hidden pages in the copied page tree can cause trouble. A hidden page is a page whose restrictions have been set to disallow the copying user to see the page. They don’t know it is in the tree they are copying.
If you are using Search/Replace for the page titles, not adding a unique prefix to the title, and you are copying within a single space then you can run into trouble for a hidden page. If the hidden page has some title that is not matched by your Search/Replace then the title will remain unchanged during the copy and it will fail:
Unexpected response code: 400:
The copied pages have conflicting titles. e.g. My Private Draft.
Please specify a page title prefix to avoid conflict.
When you are in this situation then an admin (not just a site-admin) must use the Space Settings tool to view Permissions. Then they go to “Restricted Pages” and they can see an entry for the problem page. The title of the problem page is in the error message, like “My Private Draft” in the above example.
The admin user can click on the lock icon for the hidden page to access a summary for the page:
From the page summary the admin user can “View Page History”, then view the current version and delete the problem page. That is the brute force fix. The nicer way would be to contact the user who created their page and have them rename it so it fits in with your Search/Replace scheme or have them delete it themselves.
User who can set restrictions on pages can cause trouble in a space. This is only one example of the trouble that private pages can cause. That is why Confluence, by default, does not grant this ability to most users. You should carefully consider this ability before you grant it to all of your users in a space.