> ## Documentation Index
> Fetch the complete documentation index at: https://docs.spotflow.one/llms.txt
> Use this file to discover all available pages before exploring further.

# Pagination

> How to page through lists of payments, subscriptions, plans, accounts, balances and bulk transfers.

List endpoints return results one page at a time. Choose the page and its size with query parameters, and the response tells you how many pages there are.

```bash Paginated request theme={null}
curl "https://api.spotflow.co/api/v1/payments?page=0&size=10" \
  -H "Authorization: Bearer sk_test_..."
```

```json Paginated response theme={null}
{
  "content": [],
  "pageNumber": 0,
  "pageSize": 10,
  "totalElements": 0,
  "totalPages": 0
}
```

## Query parameters

| Parameter | Type | Default | Description |
| - | - | - | - |
| `page` | integer | `0` | The page to return. Pages start at **0** |
| `size` | integer | `10` | How many items per page |

## Response attributes

| Attribute | Description |
| - | - |
| `content` | The items on this page |
| `pageNumber` | The page you're on, starting at 0 |
| `pageSize` | The number of items per page |
| `totalElements` | The number of items across all pages |
| `totalPages` | The number of pages |

You've reached the last page when `pageNumber + 1` equals `totalPages`. Don't assume every record comes back in one response.

## Paginated endpoints

* [List payments](https://docs.spotflow.one/api-reference/payments/list-collection.md)
* [List subscriptions](https://docs.spotflow.one/api-reference/subscriptions/list-subscriptions.md)
* [List subscription plans](https://docs.spotflow.one/api-reference/subscription-plans/list-single-plan.md)
* [List static virtual accounts](https://docs.spotflow.one/api-reference/static-account/list-spotflow-account.md)
* [Balances](https://docs.spotflow.one/api-reference/balances/main-account-balance.md)
* [List bulk transfers](https://docs.spotflow.one/api-reference/transfer-api/bulk-transfers.md) and [transfers in a bulk transfer](https://docs.spotflow.one/api-reference/transfer-api/bulk-transfers-by-id.md)

> [!TIP]
>
> Many list endpoints also take filters, such as `status`, `currency`, `from` and `to`. Each endpoint page lists the filters it accepts.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.