API reference
Tasks
5 endpoints. Click one to see its parameters, fields and an example. Code samples use the region you pick.
GET/v1/tasksTasks, with estimate vs hours tracked. Anyone can list them (the phone picks from them); bill rates only for people who see rates.
Tasks, with estimate vs hours tracked. Anyone can list them (the phone picks from them); bill rates only for people who see rates.
Query parameters
| Name | Type | Description |
|---|---|---|
project_id | string | |
status | "open" | "done" | |
include_archived | boolean | |
assignee_id | string | |
search | string |
Example
curl "https://ca-api.clocklap.com/v1/tasks" \
-H "Authorization: Bearer $CLOCKLAP_API_KEY"Responses
200
POST/v1/tasksAdd a task to a project
Add a task to a project
Body (JSON)
| Name | Type | Description |
|---|---|---|
project_idrequired | string | |
namerequired | string | |
estimate_hours | number or null | |
assignee_ids | array of string | |
status | "open" | "done" | |
billable_rate_cents | integer or null |
Example
curl -X POST "https://ca-api.clocklap.com/v1/tasks" \
-H "Authorization: Bearer $CLOCKLAP_API_KEY" \
-H "Content-Type: application/json" \
-d '{"project_id":"pro_01J…","name":"Example"}'Responses
200
GET/v1/tasks/{id}Get one task
Get one task
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | string |
Example
curl "https://ca-api.clocklap.com/v1/tasks/{id}" \
-H "Authorization: Bearer $CLOCKLAP_API_KEY"Responses
200
PATCH/v1/tasks/{id}Edit a task, mark it done (status) or archive it (archived: false restores it)
Edit a task, mark it done (status) or archive it (archived: false restores it)
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | string |
Body (JSON)
| Name | Type | Description |
|---|---|---|
name | string | |
estimate_hours | number or null | |
assignee_ids | array of string | |
status | "open" | "done" | |
billable_rate_cents | integer or null | |
archived | boolean | |
position | integer |
Example
curl -X PATCH "https://ca-api.clocklap.com/v1/tasks/{id}" \
-H "Authorization: Bearer $CLOCKLAP_API_KEY" \
-H "Content-Type: application/json" \
-d '{}'Responses
200
DELETE/v1/tasks/{id}Archive a task. Time already tracked on it keeps it.
Archive a task. Time already tracked on it keeps it.
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | string |
Example
curl -X DELETE "https://ca-api.clocklap.com/v1/tasks/{id}" \
-H "Authorization: Bearer $CLOCKLAP_API_KEY"Responses
200