REST API Paginator: Every Page of a JSON API
Pricing
from $2.31 / 1,000 fetched pages
REST API Paginator: Every Page of a JSON API
Fetch every page of a REST or JSON API in one run: page number, offset/limit, cursor, Link header or next-URL pagination. One dataset row per item (or per page), with your headers and API keys kept secret. Internal addresses are blocked. Empty input = free demo.
Pricing
from $2.31 / 1,000 fetched pages
Rating
0.0
(0)
Developer
Actor Factory
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
a day ago
Last modified
Categories
Features
Share
Get every page of a JSON API without writing a pagination loop
For developers, data and ops teams who need all records from a REST API, not just the first page. Give it one
endpoint (URL, method, headers, query or JSON body) and it follows the API's pagination to the end: page numbers,
offset/limit, cursors or next tokens, Link headers (rel="next") or a next-page URL in the response. You get one
dataset row per item with _page and _sourceUrl, ready for CSV, Excel, Google Sheets or the next Actor — or one row
per page if you prefer. $3.30 per 1,000 pages. Leave the input empty for a free demo.
Use cases
- Export all orders, tickets, contacts or products from a SaaS API that returns 50 or 100 records per page
- Pull a full list from a public JSON API (search results, catalogs, open-data endpoints) into one dataset
- Turn a paginated API into a CSV or spreadsheet: run this, then export the dataset or use JSON to CSV
- Schedule a nightly full sync of an API listing without maintaining a script
How it works
- Pagination types:
page—page=1, 2, 3 ...(parameter name and first page number are configurable)offset—offset=0, 20, 40 ...orskip/start; the offset grows by the number of items actually receivedcursor— reads the next cursor from a dot path in the response (meta.next_cursor,nextPageToken,response_metadata.next_cursor...) and sends it back ascursor,pageToken,start_cursoror any name you choose.@last.idtakes it from the last item (starting_afterstyle)link— follows theLinkheader withrel="next"(GitHub-style APIs)nextUrl— follows a next-page URL in the body (next,links.next,paging.next,@odata.nextLink,{ "href": ... }objects, relative URLs ...)auto(default) — Link header first, then a next-page URL in the body;none— a single request
- Items: set
itemsPath(a dot path such asdata.items,resultsordata[0].rows) or leave it empty: the first page is scanned for a top-level array or the first array of objects (data,items,results,records...). Plain values become{ "value": ... }rows - GET or POST/PUT/PATCH with a JSON body; pagination values can go in the query string or into the body (
paramLocation: "body", dot paths allowed) for search endpoints that read them from the body pageSizewith your page-size parameter (limit,per_page,page_size...),hasMorePath(e.g.has_more) to stop when the API says so- Stops by itself on an empty page, a missing or repeated cursor, a repeated next link, a page identical to the previous one (an API that ignores the page parameter),
maxPages(up to 10,000),maxItems, or the maximum charge you set for the run - Polite by default: one request at a time,
delaySecsbetween requests (default 0.3 s),timeoutSecs, andretriesfor 429 and 5xx. HTTP 429Retry-Afteris honoured (seconds or a date, waits up to 120 s); otherwise backoff of 1, 2, 4 ... s - Run totals — pages, items, why it stopped, detected items path, a per-page log — are saved as
SUMMARYin the key-value store
Your API keys stay secret
- Headers and Secret query parameters are secret input fields: Apify stores them encrypted
- Values of headers whose names contain key, token, auth, secret, cookie or password, and of query parameters with such names (
api_key,access_token...), are never written to the log, the dataset or the key-value store: they appear as[REDACTED]. If the API echoes your key back in its response, it is redacted in the items too - Logs show only the host name and per-page counts
- Secret headers and secret query parameters are not sent to another host — neither on redirects nor when a next-page link points to a different domain
- Internal addresses are never contacted. Host names are resolved and localhost, private ranges, link-local (such as the cloud metadata address 169.254.169.254) and similar are refused, also at every redirect hop
Pricing
$0.0033 per page that returned items (a 2xx response with a JSON body containing at least one item). One page with 100 items costs the same as one with 1 item. Not charged: failed requests (4xx/5xx after retries, timeouts, DNS errors), non-JSON answers, requests blocked by the internal-address guard, empty last pages, pages that repeat the previous page, retries, and the free demo on empty input. On the Apify Free plan, the $5 of monthly platform credit covers about 1,500 pages a month — 150,000 items at 100 items per page.
Input
{"url": "https://api.example.com/v1/orders","headers": { "Authorization": "Bearer YOUR_TOKEN" },"queryParams": { "status": "open" },"paginationType": "cursor","cursorPath": "meta.next_cursor","cursorParam": "cursor","limitParam": "limit","pageSize": 100,"itemsPath": "data","maxPages": 500,"delaySecs": 0.5}
Offset example (the prefilled one): { "url": "https://dummyjson.com/products", "paginationType": "offset", "offsetParam": "skip", "limitParam": "limit", "pageSize": 20, "itemsPath": "products", "maxPages": 5 }.
Output
One row per item (default):
{ "id": 21, "title": "Cucumber", "price": 1.49, "category": "groceries", "_page": 2,"_sourceUrl": "https://dummyjson.com/products?select=title,price,category&limit=20&skip=20" }
With "outputMode": "pages", one row per page:
{ "_page": 1, "_sourceUrl": "https://api.example.com/v1/orders?limit=100&api_key=[REDACTED]", "statusCode": 200,"itemCount": 100, "items": [ { "...": "..." } ], "next": "eyJpZCI6MTAwfQ", "error": null, "elapsedMs": 212 }
The SUMMARY record has pagesFetched, pagesCharged, items, stopReason (e.g. empty_page, no_next_cursor,
repeated_cursor, max_pages, request_failed), lastError, itemsPath and a per-page log.
Free demo
With empty input the Actor fetches 3 pages of products from DummyJSON, a free public fake
REST API made for testing and prototyping (no sign-up, no key). Demo rows have _demo: true and nothing is charged.
Notes
You are responsible for what you call: only use APIs you are allowed to access, with your own credentials, and follow their terms of service and rate limits. The Actor sends only the requests needed to page through the one endpoint you give; it does not crawl or follow other links. Each response is read up to 8 MB. Known limit: the internal-address check happens just before connecting; an attacker-controlled DNS server that changes its answer between the check and the connection (DNS rebinding) is not covered.
If this Actor saved you time, a rating on the Store helps others find it.
More tools from the same developer
- Bulk HTTP Request — send many HTTP requests (GET/POST/...) from a list and collect status, headers and body
- JSON to CSV Converter — turn nested JSON files or datasets into one flat CSV file
- Flatten JSON to CSV — flatten nested JSON into flat rows with the separator you choose
- Dataset Transform — flatten, filter, rename and convert any Apify dataset, export CSV / JSON / JSONL with a link
- Bulk URL Status Checker — bulk HTTP status and redirect-chain checker for URL lists