Pagination
Every list endpoint uses cursor-based pagination. Responses include a next_cursor field when more results exist; request the next page by passing it as the cursor query parameter.
Shape of a paginated response
GET /v1/accounts — first page
{
"data": [
{ "id": "acc_01J…", "name": "Nordea Bank" },
{ "id": "acc_01K…", "name": "Saxo Bank" }
],
"has_more": true,
"next_cursor": "eyJpZCI6ImFjY18wMUsifQ=="
}
When has_more is false, next_cursor is omitted — that's the terminal page.
Iterating
Fetch every account
const all = [];
let cursor: string | undefined;
do {
const page = await aleta.accounts.list({ cursor, limit: 100 });
all.push(...page.data);
cursor = page.next_cursor;
} while (cursor);
Tips
- Max page size is 100. Requesting larger pages returns a
400. - Cursors are opaque — don't try to decode them or construct your own.
- Cursors are stable for 24 hours. After that, the underlying order may have changed; restart from the beginning.
Need real-time updates? Don't poll — subscribe to the relevant webhook event and keep your local index in sync as changes happen.