Skip to main content

Tasks

GET WorkspaceProjectTasks

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks

Get project tasks for given workspace.

curl  https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks \
-H "Content-Type: application/json" \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project

Response

{
"active": {
"type": "boolean"
},
"at": {
"type": "string"
},
"estimated_seconds": {
"type": "integer"
},
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"project_id": {
"type": "integer"
},
"server_deleted_at": {
"type": "string"
},
"tracked_seconds": {
"type": "integer"
},
"user_id": {
"type": "integer"
},
"workspace_id": {
"type": "integer"
}
}

POST WorkspaceProjectTasks

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks

Post project tasks for given workspace.

curl -X POST https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks \
-H "Content-Type: application/json" \
-d '{"active":"boolean","estimated_seconds":"integer","name":"string","postedFields":["string"],"project_id":"integer","user_id":"integer","workspace_id":"integer"}' \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project

Body

nametypedescription
activeboolean-
estimated_secondsinteger-
namestring-
postedFieldsArray of string-
project_idinteger-
user_idinteger-
workspace_idinteger-

Response

{
"active": {
"type": "boolean"
},
"at": {
"type": "string"
},
"estimated_seconds": {
"type": "integer"
},
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"project_id": {
"type": "integer"
},
"server_deleted_at": {
"type": "string"
},
"tracked_seconds": {
"type": "integer"
},
"user_id": {
"type": "integer"
},
"workspace_id": {
"type": "integer"
}
}

PUT WorkspaceProjectTasks

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_ids}

Put project tasks for given workspace.

curl -X PUT https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_ids} \
-H "Content-Type: application/json" \
-d '{"active":"boolean","estimated_seconds":"integer","name":"string","postedFields":["string"],"project_id":"integer","user_id":"integer","workspace_id":"integer"}' \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project
task_idsstringtrueNumeric IDs of project tasks separated by comma

Body

nametypedescription
activeboolean-
estimated_secondsinteger-
namestring-
postedFieldsArray of string-
project_idinteger-
user_idinteger-
workspace_idinteger-

Response

{
"active": {
"type": "boolean"
},
"at": {
"type": "string"
},
"estimated_seconds": {
"type": "integer"
},
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"project_id": {
"type": "integer"
},
"recurring": {
"type": "boolean"
},
"server_deleted_at": {
"type": "string"
},
"tracked_seconds": {
"type": "integer"
},
"user_id": {
"type": "integer"
},
"workspace_id": {
"type": "integer"
}
}

PATCH WorkspaceProjectTasks

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_ids}

Patch project tasks for given workspace.

curl -X PATCH https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_ids} \
-H "Content-Type: application/json" \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project
task_idsstringtrueNumeric IDs of project tasks separated by comma

Response

{
"failure": {
"items": [
{
"id": {
"type": "integer"
},
"message": {
"type": "string"
}
}
]
},
"success": {
"type": [
"integer"
]
}
}

GET WorkspaceProjectTask

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_id}

Get project task for given task id.

curl  https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_id} \
-H "Content-Type: application/json" \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project
task_idintegertrueNumeric ID of the task

Response

{
"active": {
"type": "boolean"
},
"at": {
"type": "string"
},
"estimated_seconds": {
"type": "integer"
},
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"project_id": {
"type": "integer"
},
"server_deleted_at": {
"type": "string"
},
"tracked_seconds": {
"type": "integer"
},
"user_id": {
"type": "integer"
},
"workspace_id": {
"type": "integer"
}
}

DELETE WorkspaceProjectTask

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_id}

Delete projects task for given workspace.

curl -X DELETE https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/projects/{project_id}/tasks/{task_id} \
-H "Content-Type: application/json" \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace
project_idintegertrueNumeric ID of the project
task_idintegertrueNumeric ID of the task

Response

Successful operation.

GET Tasks

https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/tasks

List Workspace tasks.

curl  https://api.track.toggl.com/api/v9/workspaces/{workspace_id}/tasks \
-H "Content-Type: application/json" \
-u <email>:<password>

Parameters

Path

nametyperequireddescription
workspace_idintegertrueNumeric ID of the workspace

Response

{
"data": {
"items": [
{
"active": {
"type": "boolean"
},
"at": {
"type": "string"
},
"estimated_seconds": {
"type": "integer"
},
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"project_id": {
"type": "integer"
},
"recurring": {
"type": "boolean"
},
"server_deleted_at": {
"type": "string"
},
"tracked_seconds": {
"type": "integer"
},
"user_id": {
"type": "integer"
},
"workspace_id": {
"type": "integer"
}
}
]
},
"page": {
"type": "integer"
},
"per_page": {
"type": "integer"
},
"sort_field": {
"type": "string"
},
"sort_order": {
"type": "string"
},
"total_count": {
"type": "integer"
}
}
© 2022 Toggl. All rights reserved.