Time tracking
Upsert Timesheet Entry
Records or corrects one day's work times in the employee's timezone and recalculates period compliance.
POSThttps://api.toku.com/hris/upsert-timesheet-entry
Not available to API keys yet. It will need time:write.
curl --request POST \
--url 'https://api.toku.com/hris/upsert-timesheet-entry' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"roleInOrgID": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"workDate": "string",
"startTime": "string",
"endTime": "string",
"clockStartAt": "string",
"clockEndAt": "string",
"clockBreakMinutes": 0,
"clockExpectedUpdatedAt": "string",
"breakStartTime": "string",
"breakEndTime": "string",
"breaks": [
{
"start": "string",
"end": "string",
"kind": "BREAK",
"paid": true,
"worked": true
}
],
"note": "string"
}'200 response
{}Authorizations
AuthorizationstringheaderrequiredBearer authentication header of the form Bearer <token>, where <token> is an access token from a Toku sign-in. See Authentication in the API reference.
Body
application/json
roleInOrgIDstring<uuid>workDatestringrequiredAllowed: matches ^\d{4}-\d{2}-\d{2}$
startTimestringrequiredAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
endTimestringrequiredAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
clockStartAtstringclockEndAtstringclockBreakMinutesintegerAllowed: 0 to 1500
clockExpectedUpdatedAtstringbreakStartTimestring | nullAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
breakEndTimestring | nullAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
breaksobject[]Allowed: at most 6 items
Show child attributes
startstringrequiredAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
endstringrequiredAllowed: matches ^([01]\d|2[0-3]):[0-5]\d$
kindstringrequiredAvailable options: BREAK, LUNCH
paidbooleanworkedbooleannotestring | nullAllowed: at most 1000 characters
Response
200Successful response
400Bad request
401Unauthorized
403Forbidden
404Not found
409Conflict
429Response 429
Was this page helpful? Suggest edits