Time activity webhook
Upon integrating with the time activity webhook, you will be notified of a variety of events that reflect the actions taken by users and admins within the system. These events are crucial for real-time monitoring and management of time-related activities.
Important to knowThis article provides helpful insights and examples about different types of time activities. For the most up-to-date information, please follow this link.
Below is a detailed overview of the events you can expect to receive:
| eventType | activityType | Description |
|---|---|---|
| clock_in | shift, manual_break | User clocked in |
| clock_out | shift, manual_break | User clocked out |
| auto_clock_out | shift, manual_break | User clocked out automatically based on the predefined settings in the time clock configuration |
| admin_add | shift, manual_break, time_off | Admin added a new time activity |
| admin_edit | shift, manual_break | Admin edited a time activity |
| admin_delete | shift, manual_break | Admin deleted a time activity |
| admin_approved_clock_out_outside_geo_fence_request | shift, manual_break | Admin approved a clock out that occurred outside the geofence. In response, the initial shift created at clock-in is deleted, and a new shift aligned with the clock-out outside geofence parameters is created |
| admin_approved_add_request | shift, manual_break, time_off | Admin approved a time activity that was added by a user |
| admin_approved_edit_request | shift, manual_break | Admin approved changes made by a user to a time activity |
| admin_approved_delete_request | shift, manual_break | Admin approved the deletion of a time activity by a user |
| admin_declined_request | time_off | Admin declined a time off request that had been previously approved |
| auto_approved_clock_out_outside_geo_fence_request | shift, manual_break | Automatically approved a clock-out that occurred outside the geofence |
| auto_approved_add_request | shift, manual_break, time_off | Automatically approved a time activity added by a user |
| auto_approved_edit_request | shift, manual_break | Automatically approved changes made by a user to a time activity |
| auto_approved_delete_request | shift, manual_break | Automatically approved the deletion of a time activity by a user |
| user_add_request š | shift, manual_break, time_off | Coming Soon - User submitted a new time activity request pending approval |
| user_edit_request š | shift, manual_break | Coming Soon - User submitted an edit request pending approval |
| user_delete_request š | shift, manual_break | Coming Soon - User submitted a delete request pending approval |
| admin_declined_add_request š | shift, manual_break, time_off | Coming Soon - Admin declined a user's add request |
| admin_declined_edit_request š | shift, manual_break | Coming Soon - Admin declined a user's edit request |
| admin_declined_delete_request š | shift, manual_break | Coming Soon - Admin declined a user's delete request |
Timesheet Period Events š Coming Soon
These events notify you about changes to timesheet approval status and day locking.
| eventType | Description |
|---|---|
| admin_day_locked | Admin locked a day/period for a user |
| admin_day_unlocked | Admin unlocked a day/period for a user |
| user_timesheet_submitted | User submitted their timesheet for approval |
| user_timesheet_approved | Admin approved a user's timesheet |
| user_timesheet_reopened | Admin reopened a user's timesheet |
Event examples
This section includes examples of the JSON payloads for event types mentioned, illustrating how the data is structured and what information is included. This practical insight helps in understanding how to process and react to each event within your system effectively:
clock_in - shift
{
"userId": 145,
"timeClockId": 67,
"activityType": "shift",
"eventType": "clock_in",
"timeActivity": {
"id": "65d46394a0973d7bbd55cd26",
"start": {
"timestamp": 1708417940,
"timezone": "Asia/Jerusalem",
"locationData": {
"address": "address test",
"longitude": 0,
"latitude": 0
}
},
"jobId": "cc6e0b98-1f9a-4e3f-8535-c02d55a362d8",
"schedulerShiftId": "cc6e0b98c02d55a362d8",
"shiftAttachments": []
}
}clock_out - shift
{
"userId": 145,
"timeClockId": 67,
"activityType": "shift",
"eventType": "clock_out",
"timeActivity": {
"id": "65d5da9df9a1952f149bc47c",
"start": {
"timestamp": 1708513949,
"timezone": "Asia/Jerusalem",
"locationData": {
"address": "string",
"longitude": 0,
"latitude": 0
}
},
"end": {
"timestamp": 1708513979,
"timezone": "Asia/Jerusalem",
"locationData": {
"address": "string",
"longitude": 0,
"latitude": 0
}
},
"jobId": "cc6e0b98-1f9a-4e3f-8535-c02d55a362d8",
"schedulerShiftId": "cc6e0b98c02d55a362d8",
"shiftAttachments": [
{
"shiftAttachmentId": "a69ef24c-41d5-2e91-d84b-e73ddb5773d1",
"attachment": {
"files": [
{
"fileName": "file",
"fileUrl": "https://link_to_file"
}
]
}
}
]
}
}admin_add - time_off
{
"userId": 146,
"timeClockId": 67,
"activityType": "time_off",
"eventType": "admin_add",
"timeActivity": {
"id": "65d32918a28dbd2c492d76bb",
"start": {
"timestamp": 1710885600,
"timezone": "Asia/Jerusalem"
},
"end": {
"timestamp": 1710971999,
"timezone": "Asia/Jerusalem"
},
"policyTypeId": "65af9319dea5e39064086d93",
"duration": {
"value": 1.0,
"units": "days"
},
"isAllDay": true
}
}admin_edit - manual_break
{
"userId": 145,
"timeClockId": 67,
"activityType": "manual_break",
"eventType": "admin_edit",
"timeActivity": {
"id": "65d370a6a28dbd2c492d76bf",
"start": {
"timestamp": 1708671600,
"timezone": "Asia/Jerusalem"
},
"end": {
"timestamp": 1708675200,
"timezone": "Asia/Jerusalem"
},
"manualBreakId": "aad8cb0d-0d27-4adc-84f9-eb2ac4fa26b6"
}
}admin_delete - shift
{
"userId": 145,
"timeClockId": 67,
"activityType": "shift",
"eventType": "admin_delete",
"timeActivityId": "65d4636ba0973d7bbd55cd25"
}admin_approved_edit_request - shift
{
"userId": 145,
"timeClockId": 67,
"activityType": "shift",
"eventType": "admin_approved_edit_request",
"timeActivity": {
"id": "65d1f5cc8cf696ef8fafd9d4",
"start": {
"timestamp": 1708844400,
"timezone": "Asia/Jerusalem"
},
"end": {
"timestamp": 1708876800,
"timezone": "Asia/Jerusalem"
},
"jobId": "cc6e0b98-1f9a-4e3f-8535-c02d55a362d8",
"shiftAttachments": []
}
}admin_declined_request - time_off
{
"userId": 145,
"timeClockId": 67,
"activityType": "time_off",
"eventType": "admin_declined_request",
"timeActivityId": "65d4a72e0fa9ac7f730c91be"
}Updated 20 days ago
