All templates
Starters
Mock a paginated API
Three real pages, so infinite scroll has somewhere to stop.
3 routes · live immediately · no account needed
Pagination bugs hide on the pages a single-page fixture never reaches: the second fetch, the last page, the moment has_more flips to false and the loader has to stop. This mock serves three distinct pages off the page query parameter and ends honestly, so infinite scroll, load-more buttons, and cursor bookkeeping can be tested end to end.
What you get
GET
/items200 OKGET
/itemsconditional200 OKGET
/itemsconditional200 OKExample response
GET /items
{
"page": 1,
"per_page": 3,
"total": 8,
"total_pages": 3,
"has_more": true,
"data": [
{
"id": 1,
"name": "Item 1"
},
{
"id": 2,
"name": "Item 2"
},
{
"id": 3,
"name": "Item 3"
}
]
}Good for
- Test infinite scroll all the way to the final page
- Check that a load-more button disables when the list runs out
- Reproduce off-by-one paging bugs deterministically