Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Rest api confluence - only 200 pages when using /rest/api/space/space_name/content?expand=ancestors&limit=1000

Karol Kozakowski (Cosaquee) October 5, 2015

I need to get all pages(their id)  from one space. There is much more then 200 but even if i set limit to 10000, i only get 200. Any ideas how to do it ? 

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

3 votes
Answer accepted
Stephen Deutsch
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 5, 2015

The Confluence REST API does not necessarily return all the way up to the requested limit no matter what, there is also a hardcoded maximum limit (which may be different based on which version of Confluence you have). 

If there are more results than the limit (i.e. if the "size" variable is the same as the "limit" variable), then you will have to include another parameter called "start".  So, if your limit is 200, then you should call /rest/api/space with "&start=200", and if size is still 200, then you will have to call it again with "&start=400".  So you might have to call /rest/api/space multiple times, but eventually you will get all the results.

TAGS
AUG Leaders

Atlassian Community Events