List endpoints return paginated results using offset-based pagination. You control the page size and position with two query parameters.
Parameters
| Parameter | Type | Default | Range | Description |
|---|
limit | integer | 25 | 1-100 | Maximum number of items per page. |
offset | integer | 0 | 0-10000 | Number of items to skip. |
Response shape
Every paginated response includes these fields:
{
"data": [],
"total": 42,
"offset": 0,
"limit": 25
}
| Field | Type | Description |
|---|
data | array | The items for the current page. |
total | integer | Total number of matching items across all pages. |
offset | integer | The offset used for this request. |
limit | integer | The limit used for this request. |
Example
Fetch the first page of applications:
curl -H "Authorization: Bearer YOUR_API_KEY" \
"https://api.sevalla.com/v3/applications?limit=10&offset=0"
Fetch the next page:
curl -H "Authorization: Bearer YOUR_API_KEY" \
"https://api.sevalla.com/v3/applications?limit=10&offset=10"
Paging through all results
To iterate through every item, increment offset by limit until you’ve fetched total items.
const url = "https://api.sevalla.com/v3/applications";
const headers = { Authorization: "Bearer YOUR_API_KEY" };
let offset = 0;
const limit = 25;
const allItems: any[] = [];
while (true) {
const resp = await fetch(`${url}?limit=${limit}&offset=${offset}`, { headers });
const body = await resp.json();
allItems.push(...body.data);
if (offset + limit >= body.total) break;
offset += limit;
}
console.log(`Fetched ${allItems.length} applications`);
Use the smallest limit that works for your use case. If you only need to check whether items exist, limit=1 keeps the response fast.