I'm trying to get all the pages in status 'draft' via REST API
I found an article "How to clean programmatically old drafts and purge trash with python"
rest/api/content?spaceKey={space}&status=draft
The proposed method returns draft pages only for the current user in space.
And I need a method that returns the result for all users.
Hi Pavel,
The API would have the same permissions applied as if you were viewing the pages/drafts through your Browser. If you're not the Draft's Author, it should not return when you call for Draft pages.
If you have access to your SQL Server, you could run a direct SELECT to find the Drafts within your instance; something like the following query would return all Draft Pages.
select * from CONTENT where CONTENTTYPE = 'DRAFT';
You can then manipulate the Drafts as needed.
Cheers,
Shawn
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.