get
https://www.humanity.com/api/v2/new-endpoint
Retrieve employee tasks for specified shifts using the Humanity API v2. View task assignments, status, and activity details for employees with appropriate permissions.
Overview
Retrieve employee tasks for specified shifts. This endpoint returns detailed information about tasks assigned to employees for the provided shift IDs.
API Details
- Minimum Role: Employee
- API Version: v2
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
shiftIds | string | Yes | Comma separated IDs of shifts |
access_token | string | Yes | Authentication token |
Permissions
Users can view employee tasks for shifts they have read permissions on.
Request Format
GET {baseUrl}/api/v2/shifts/{shiftIds}/employee-tasks?access_token={token}
Example
Request
GET https://www.humanity.com/api/v2/shifts/2413,2415/employee-tasks?access_token=7d31c4e93f680b48685eaeaebadc57cbc1846260Response
{
"status": 1,
"data": [
{
"id": "01jbegdrx488az35r79fcj4s8x",
"employeeId": 2,
"taskId": "01ht07sr1e36pw203eyy7nhn0b",
"shiftId": 2413,
"shiftTaskId": "01jbegdrv07rdnwkfn2y0zcgf6",
"type": 1,
"options": null,
"activity": {
"startedAt": null,
"endedAt": null,
"startedBy": null,
"endedBy": null,
"status": 0
},
"createdBy": 3,
"createdAt": "2024-10-30T10:44:29+00:00",
"updatedBy": null,
"updatedAt": null,
"deletedBy": null,
"deletedAt": null
},
{
"id": "01k6wdtxjpqt6hzyyr094ybv5t",
"employeeId": 2,
"taskId": "01ht07sr1e36pw203eyy7nhn0b",
"shiftId": 2415,
"shiftTaskId": "01k6wdtxg32wchygd7j01dvpwz",
"type": 1,
"options": null,
"activity": {
"startedAt": "2025-10-06T09:37:49+00:00",
"endedAt": "2025-10-06T09:39:07+00:00",
"startedBy": 2,
"endedBy": 2,
"status": 2
},
"createdBy": 3,
"createdAt": "2025-10-06T09:32:25+00:00",
"updatedBy": 2,
"updatedAt": "2025-10-06T09:39:07+00:00",
"deletedBy": null,
"deletedAt": null
},
{
"id": "01k6wdtxjr3kdxcc73xcmz5s0y",
"employeeId": 39737,
"taskId": "01ht07sr1e36pw203eyy7nhn0b",
"shiftId": 2415,
"shiftTaskId": "01k6wdtxg32wchygd7j01dvpwz",
"type": 1,
"options": null,
"activity": {
"startedAt": null,
"endedAt": null,
"startedBy": null,
"endedBy": null,
"status": 0
},
"createdBy": 3,
"createdAt": "2025-10-06T09:32:25+00:00",
"updatedBy": null,
"updatedAt": null,
"deletedBy": null,
"deletedAt": null
},
{
"id": "01k6wdtxjsjzda6jmj83xfcbmk",
"employeeId": 39786,
"taskId": "01ht07sr1e36pw203eyy7nhn0b",
"shiftId": 2415,
"shiftTaskId": "01k6wdtxg32wchygd7j01dvpwz",
"type": 1,
"options": null,
"activity": {
"startedAt": "2025-10-06T09:38:33+00:00",
"endedAt": null,
"startedBy": 2,
"endedBy": null,
"status": 1
},
"createdBy": 3,
"createdAt": "2025-10-06T09:32:25+00:00",
"updatedBy": 2,
"updatedAt": "2025-10-06T09:38:33+00:00",
"deletedBy": null,
"deletedAt": null
}
],
"metadata": [],
"token": "token",
"error": null
}Response Fields
Employee Task Object
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier for the employee task |
employeeId | integer | ID of the employee assigned to the task |
taskId | string | ID of the task definition |
shiftId | integer | ID of the shift this task is associated with |
shiftTaskId | string | ID of the shift task assignment |
type | integer | Task type identifier |
options | object/null | Additional task options |
activity | object | Task activity tracking information |
createdBy | integer | ID of user who created the task assignment |
createdAt | string | ISO 8601 timestamp of creation |
updatedBy | integer/null | ID of user who last updated the task |
updatedAt | string/null | ISO 8601 timestamp of last update |
deletedBy | integer/null | ID of user who deleted the task (if applicable) |
deletedAt | string/null | ISO 8601 timestamp of deletion (if applicable) |
Activity Object
| Field | Type | Description |
|---|---|---|
startedAt | string/null | ISO 8601 timestamp when task was started |
endedAt | string/null | ISO 8601 timestamp when task was completed |
startedBy | integer/null | ID of user who started the task |
endedBy | integer/null | ID of user who ended the task |
status | integer | Task status (0: Not Started, 1: In Progress, 2: Completed) |
