Skip to content
MiniMailer
Docs
Toggle sidebar
Quick links
Documentation
Knowledge Base
API Reference
Changelog
No results found

Pagination

Every collection endpoint uses cursor pagination. Follow the links each response carries — cursors are opaque tokens the API issues for you; you never build one by hand.

Page parameters

Two query parameters control the page: page[cursor] — an opaque token taken from a previous response — and page[size] (defaults to 25, capped at 100; a larger size is silently reduced, and out-of-range or non-numeric values fall back to the default). Omit the cursor to get the first page. An invalid or expired cursor also returns the first page. Replaying a cursor with a different sort than it was issued under returns 400, as do unknown page members such as page[number].

GET /v1/outbound-emails?page[size]=50
GET /v1/outbound-emails?page[cursor]=eyJpZCI6MTAwLCJfcG9pbnRzVG9OZXh0SXRlbXMiOnRydWV9&page[size]=50

Every collection response carries a links object. next and prev carry the cursor for the adjacent page and are null when there is no page in that direction; first restarts traversal from the beginning, and last is always null under cursor pagination. Link URLs carry the page parameters URL-encoded (page%5Bcursor%5D=...) and preserve any filter, sort, include, fields, and page size you sent.

"links": {
  "first": "https://api.minimailer.app/outbound-emails?page%5Bsize%5D=50",
  "last": null,
  "prev": null,
  "next": "https://api.minimailer.app/outbound-emails?page%5Bcursor%5D=eyJpZCI6NTAsIl9wb2ludHNUb05leHRJdGVtcyI6dHJ1ZX0&page%5Bsize%5D=50"
}

Response meta

Alongside links, each collection response includes a meta object: has_more tells you whether another page exists, and next_cursor / prev_cursor expose the raw cursors for clients that build their own URLs.

"meta": {
  "has_more": true,
  "next_cursor": "eyJpZCI6NTAsIl9wb2ludHNUb05leHRJdGVtcyI6dHJ1ZX0",
  "per_page": 50,
  "prev_cursor": null
}

Traversing pages

To walk a whole collection, request the list endpoint and keep following links.next until it is null. Cursor pagination is stable under concurrent writes — new records arriving mid-traversal never cause skipped or duplicated items. Links are plain URLs — pass them back with the same Authorization and Accept headers.