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

Authorizationstringheaderrequired

Bearer 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>
workDatestringrequired

Allowed: matches ^\d{4}-\d{2}-\d{2}$

startTimestringrequired

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

endTimestringrequired

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

clockStartAtstring
clockEndAtstring
clockBreakMinutesinteger

Allowed: 0 to 1500

clockExpectedUpdatedAtstring
breakStartTimestring | null

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

breakEndTimestring | null

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

breaksobject[]

Allowed: at most 6 items

Show child attributes
startstringrequired

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

endstringrequired

Allowed: matches ^([01]\d|2[0-3]):[0-5]\d$

kindstringrequired

Available options: BREAK, LUNCH

paidboolean
workedboolean
notestring | null

Allowed: at most 1000 characters

Response

200Successful response
400Bad request
401Unauthorized
403Forbidden
404Not found
409Conflict
429Response 429
Was this page helpful? Suggest edits