/v2/api/entity base and authenticated with a Bearer token.1) is the data level — how deeply related records are loaded — not a page number. On this endpoint the data level has no visible effect, so /attendance_log/list and /attendance_log/list/1 return the same result. Pagination is controlled by the page and per_page query parameters.| Parameter | Purpose |
|---|---|
page | Page number (default 1). |
per_page | Items per page (default 20). |
filter[<field>][<operator>] | Filter by a field (see the Filterable fields table below). |
sort[<field>] | Sort by a field, asc or desc. |
fields[] | Restrict the returned columns. |
filter[<field>][<operator>]=<value>. The fields intended for filtering:| Field | Type | Example |
|---|---|---|
staff_id | integer (staff) | filter[staff_id][equal]=1 |
status | enum | filter[status][equal]=draft |
source_type | enum (machine, supervisor, file, self) | filter[source_type][equal]=self |
sort[<field>]=asc|desc (e.g. sort[time]=desc). No field is specifically flagged as sortable in the metadata, but the endpoint accepts a sort on any existing column; with no sort, results are returned newest-first.data is a flat attendance-log record.status is one of:| Value | Meaning |
|---|---|
| draft | Draft |
| sign_in | Sign In |
| sign_out | Sign Out |
| repeated_sign_in | Repeated Sign In |
| repeated_sign_out | Repeated Sign Out |
| invalid | Invalid |
| unknown_employee | Unknown Employee |
source_type, when present, is one of machine, supervisor, file, self.curl --location --globoff 'https://.daftra.com/v2/api/entity/attendance_log/list/1?page=undefined&per_page=undefined' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer ' \
--header 'apikey: ' \
--header 'Content-Type: application/json'{
"current_page": 1,
"data": [
{
"id": 0,
"staff_id": 0,
"time": "string",
"session_id": 0,
"status": "draft",
"source_id": 0,
"source_name": "string",
"source_type": "machine",
"source_method": "string",
"deleted_at": "string",
"created": "string",
"modified": "string",
"invalidity_reason": "weekend"
}
],
"per_page": 20,
"total": 0,
"last_page": 0,
"from": 0,
"to": 0,
"first_page_url": "string",
"last_page_url": "string",
"next_page_url": "string",
"prev_page_url": "string",
"path": "string",
"links": [
{}
]
}