Pagination

Page through long lists with page and pageSize.

GET /transactions is paginated with page numbers. Other list endpoints return a bounded list in one response, described below.

Parameters

Prop

Type

curl "https://business-api.migrapay.com/v1/api/transactions?page=2&pageSize=50" \
  -H "Authorization: Bearer $MIGRAPAY_API_KEY"

Response shape

Results are newest first. The page sits in data.docs, alongside the totals you need to build a pager:

{
  "status": "success",
  "message": "Transactions retrieved successfully.",
  "data": {
    "docs": [],
    "totalDocs": 132,
    "page": 2,
    "totalPages": 3,
    "counts": { "all": 132, "transfer": 97, "collection": 30, "fee": 5 }
  }
}
FieldDescription
docsThe items on this page.
totalDocsItems matching your filters, across all pages.
pageThe page returned.
totalPagesPages available at the current pageSize.
countsTotals per activity type for the whole account. Not affected by filters, handy for tab badges.

To read everything, request page=1, 2, 3… until page equals totalPages. New transactions arriving while you page shift later pages, so when syncing, filter by a fixed endDate first.

Bounded lists

EndpointReturns
GET /payoutsThe 100 most recent payouts. For older ones use GET /transactions?activity=transfer.
GET /collectionsThe 200 most recent collections.
GET /recipientsAll recipients.
GET /walletsAll wallets.