Unless specified otherwise in the endpoint documentation, all list endpoints will return Length aware pagination response, which mean they will always have the total count of results and the remaining pages on the returned response.
The pagination return response will have:
Unless specified otherwise in the endpoint documentation, all pagination endpoints accept the following parameters:
Key | Type | default | Description |
---|---|---|---|
page | string | 1 | The page number |
limit | int | 15 | Define how many result are returned per request, max is 100 |
search | string | - | Search (what keys this search depends on the endpoint) |
order | string | created_at | Ordering the results (keys to order by depends on the endpoint) |
direction | string | desc | The direction of the order |
{
"data": [],
"links": {
"first": "http://localhost/api/contacts?search=tjrbeh123123&page=1",
"last": "http://localhost/api/contacts?search=tjrbeh123123&page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": null,
"last_page": 1,
"links": [
{
"url": null,
"label": "« Previous",
"active": false
},
{
"url": "http://localhost/api/contacts?search=tjrbeh123123&page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "Next »",
"active": false
}
],
"path": "http://localhost/api/contacts",
"per_page": 15,
"to": null,
"total": 0
}
}