Skip to content
ClockLap Developers
API reference clocklap.com Get an API key

API reference

Custom fields

3 endpoints. Click one to see its parameters, fields and an example. Code samples use the region you pick.

GET/v1/custom-fieldsThe workspace’s custom fields for people, locations, projects and time entries

The workspace’s custom fields for people, locations, projects and time entries

Staff see only the fields shown to them. Values appear as custom_fields on each record, keyed by key.

Query parameters

NameTypeDescription
entity"person" | "location" | "project" | "time_entry"
include_archivedboolean

Example

curl "https://ca-api.clocklap.com/v1/custom-fields" \
  -H "Authorization: Bearer $CLOCKLAP_API_KEY"

Responses

200

POST/v1/custom-fieldsAdd a custom field (people who edit time rules)

Add a custom field (people who edit time rules)

Body (JSON)

NameTypeDescription
entityrequired"person" | "location" | "project" | "time_entry"
keystring
labelrequiredstring
typerequired"text" | "number" | "boolean" | "choice" | "date"
optionsarray of string
requiredboolean
visible_to_staffboolean
helpstring or null
positioninteger

Example

curl -X POST "https://ca-api.clocklap.com/v1/custom-fields" \
  -H "Authorization: Bearer $CLOCKLAP_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"entity":"person","label":"string","type":"text"}'

Responses

200

PATCH/v1/custom-fields/{id}Rename, reorder, change choices, require, hide from staff or archive a field (its key and type stay)

Rename, reorder, change choices, require, hide from staff or archive a field (its key and type stay)

Path parameters

NameTypeDescription
idrequiredstring

Body (JSON)

NameTypeDescription
labelstring
optionsarray of string
requiredboolean
visible_to_staffboolean
helpstring or null
positioninteger
archivedboolean

Example

curl -X PATCH "https://ca-api.clocklap.com/v1/custom-fields/{id}" \
  -H "Authorization: Bearer $CLOCKLAP_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Responses

200