ReferencePagination

Pagination

All list endpoints in the Parsify API return paginated responses. The API uses page-based pagination with a standard envelope format.

Response Format

{
  "count": 142,
  "next": "https://api.parsifyhq.com/api/v1/documents/?page=2",
  "previous": null,
  "results": [...]
}
FieldTypeDescription
countintegerTotal number of results across all pages.
nextstring | nullURL for the next page, or null if this is the last page.
previousstring | nullURL for the previous page, or null if this is the first page.
resultsarrayThe items for the current page.

Iterating Through Pages

Follow the next URL until it returns null to retrieve all results.

URL="https://api.parsifyhq.com/api/v1/documents/"
 
while [ "$URL" != "null" ]; do
  RESPONSE=$(curl -s "$URL" \
    -H "X-API-Key: YOUR_API_KEY")
 
  echo "$RESPONSE" | jq '.results'
 
  URL=$(echo "$RESPONSE" | jq -r '.next')
done

Query Parameters

ParameterTypeDefaultDescription
pageinteger1The page number to retrieve.
page_sizeinteger20Number of results per page (max 100).

Example:

curl "https://api.parsifyhq.com/api/v1/documents/?page=3&page_size=50" \
  -H "X-API-Key: YOUR_API_KEY"