REST-API

The clockodo API allows you to connect clockodo to other systems. Accounting and project management applications or proprietary shell scripts are examples of useful mash-ups with clockodo.

api/users: Manage co-workers


Object type „user“

Parameter Type Description
id integer ID of the co-worker
name string Name of the co-worker
number string|null Personnel number
email string E-mail-address of the co-worker
role string Role of the co-worker
active boolean Is the co-worker active?
timeformat_12h boolean Is the co-worker using the 12h time format?
weekstart_monday boolean Does the week start on Monday for the co-worker? If not, the week starts on Sunday
weekend_friday boolean Is the weekend Friday and Saturday for the co-worker? If not, it is Saturday and Sunday
language string The co-worker's language Allowed values: 'de', 'en', 'fr'
timezone string The co-worker's timezone e.g. 'Europe/Berlin'
wage_type integer|null Only relevant for the DATEV export Allowed values: 1 (salary), 2 (hourly wage)
can_generally_see_absences boolean Is the co-worker allowed to see other co-workers' absences? Only editable for co-workers with the role 'worker'
can_generally_manage_absences boolean Is the co-worker allowed to edit other co-workers' absences? Only editable for co-workers with the role 'manager'
can_add_customers boolean Is the co-worker allowed to add customers? Only editable for co-workers with the role 'worker'
edit_lock string|null Fixed edit lock for this co-worker null (No edit lock)
YYYY-MM-DD (Not editable until)
edit_lock_dyn integer|null Dynamic edit lock for this co-worker null (No edit lock)
1 (Today editable)
2 (Today and yesterday editable)
3 (Today and 2 days retroactively editable)
5 (Today and 4 days retroactively editable)
8 (Today and one week retroactively editable)
15 (Today and 2 weeks retroactively editable)
31 (Today and 30 days retroactively editable)
46 (Today and 45 days retroactively editable)
91 (Today and 90 days retroactively editable)
edit_lock_sync boolean|null Can future changes to the company-wide edit lock overwrite the edit lock for this co-worker?
worktime_regulation_id integer|null The worktime regulation applicable to the co-worker "0" if the co-worker has no worktime regulation
"null" if the company default is applicable

List co-workers

Request
GET /api/users
Response
{
  "users": 
  {
    [object of type user],
    [object of type user], ...
  }
}

Get co-worker

Request
GET /api/users/[ID]
Response
{
  "user": [object of type user]
}

Add co-workers

Request
POST /api/users
Required parameters name, email, role

The parameter mail_to_user determines whether an e-mail should be sent to the new co-worker (default: false).

Optional parameters mail_to_user, number, timeformat_12h, weekstart_monday, weekend_friday, language, timezone, wage_type, can_generally_see_absences, can_generally_manage_absences, can_add_customers, edit_lock_sync
Response
{
  "user": [object of type user]
}

Edit co-workers

Request
PUT /api/users/[ID]
Required parameters none
Optional parameters name, number, active, role, timeformat_12h, weekstart_monday, weekend_friday, language, timezone, wage_type, can_generally_see_absences, can_generally_manage_absences, can_add_customers, edit_lock, edit_lock_dyn, edit_lock_sync
Response
{
  "user": [object of type user]
}

Deactivate co-workers

Request
DELETE /api/users/[ID]
Response
{
  "user": [object of type user]
}