Many Tsara API endpoints return lists of data — such as transactions, customers, or wallets.
To make these results manageable, all list endpoints are paginated using page and limit query parameters.
🚀 Overview
Pagination helps you control how many results are returned per request and allows efficient navigation through large datasets.
Base format:
GET /resource?page=1&limit=20⚙️ Parameters
| Parameter | Type | Description | Default |
|---|---|---|---|
| page | Integer | The page number to retrieve. | 1 |
| limit | Integer | The number of items per page (max 100). | 20 |
💡 You can adjust limit for performance — smaller values reduce payload size, larger values reduce total requests.
🧾 Example Request
Retrieve a paginated list of transactions for a wallet:
curl -X GET "https://sandbox.tsara.ng/v1/wallets/wal_123/transactions?page=2&limit=10" \
-H "Authorization: Bearer YOUR_SECRET_KEY"Response
{
"success": true,
"data": [
{
"id": "txn_021",
"type": "incoming",
"amount": "50.00",
"asset": "USDC",
"status": "success",
"created_at": "2025-10-17T11:00:00Z"
},
{
"id": "txn_022",
"type": "outgoing",
"amount": "25.00",
"asset": "USDC",
"status": "pending",
"created_at": "2025-10-17T11:10:00Z"
}
],
"pagination": {
"page": 2,
"limit": 10,
"total": 35
},
"request_id": "req_abc789"
}🧮 Pagination Object
| Field | Description |
|---|---|
| page | The current page number. |
| limit | The number of items per page. |
| total | The total number of items available for that resource. |
💡 You can calculate total pages as:
total_pages = ceil(total / limit)🔁 Recommended Practices
- Use pagination for all list endpoints to avoid large payloads.
- Cache paginated responses for high-traffic endpoints (e.g., transactions).
- Display
page,limit, andtotalin admin dashboards for transparency. - Combine pagination with filters (coming soon) for flexible querying.
⚡ Supported Endpoints
| Endpoint | Description |
|---|---|
/wallets | List all stablecoin wallets. |
/wallets/{id}/transactions | List wallet transactions. |
/bank-accounts | List virtual bank accounts. |
/customers | List all customers. |
/bank-transfers | List transfer records. |