# Latest topics JSON - How to load paginated data?

**URL:** https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864
**Category:** Development
**Tags:** rest-api
**Created:** [Fevereiro 5, 2015, 1:39pm UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864 "2015-02-05T13:39:36Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![kkershaw](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/kkershaw/32/115025_2.png) [@kkershaw](https://meta.discourse.org/u/kkershaw)
#### Post date: [Fevereiro 5, 2015, 1:39pm UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864/1 "2015-02-05T13:39:36Z")

</div>

When scrolling down the ‘latest’ view in Discourse, the page lazy loads more topics as one scrolls down. Is there any way to load more topics via the `latest.json` endpoint? Is there a pagination parameter that can be passed to the JSON endpoint?

---

<div class="post-metadata">

### Author: ![DeanMarkTaylor](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/deanmarktaylor/32/102462_2.png) [@DeanMarkTaylor](https://meta.discourse.org/u/DeanMarkTaylor)
#### Post date: [Fevereiro 5, 2015, 2:01pm UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864/2 "2015-02-05T14:01:14Z")

</div>

Pretty sure this has been covered many times before…

But the simple answer is, this is what is called by the page as you scroll:  
`https://meta.discourse.org/latest.json`  
`https://meta.discourse.org/latest.json?no_definitions=true&page=1`  
`https://meta.discourse.org/latest.json?no_definitions=true&page=2`

Use Chrome Dev tools and look in the Network tab for XHR requests to find out what Discourse calls when you perform actions.

---

<div class="post-metadata">

### Author: ![kkershaw](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/kkershaw/32/115025_2.png) [@kkershaw](https://meta.discourse.org/u/kkershaw)
#### Post date: [Fevereiro 8, 2015, 11:52am UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864/3 "2015-02-08T11:52:17Z")

</div>

Sorry, I wasn’t able to find anything through a number of searches, but thank you for your help, this is perfect and you are right, looking in the Network tab is very useful.

To point out a further oversight on my behalf, the JSON file itself contains, in the `topic_list` array: `more_topics_url` 😊

---

<div class="post-metadata">

### Author: ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)
#### Post date: [Fevereiro 8, 2015, 4:59pm UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864/4 "2015-02-08T16:59:04Z")

</div>

> [@kkershaw](#):
>
> more\_topics\_url

And that will be missing (or null?) when you run out 😉

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [Novembro 27, 2023, 1:32pm UTC](https://meta.discourse.org/t/latest-topics-json-how-to-load-paginated-data/24864/7 "2023-11-27T13:32:49Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
