Getting the list of active timers through API: get_timers
Sample get_timers request
?action=get_timers
Returns running timers info
*their ID, start time, timer value and who started them
*their ID, start time, timer value and who started them
Returned data:
- id — timer ID
- time — timer value (at the moment of sending the request)
- date_started — timer start date and time
- user_from — info on who started the timer
- task — dataset on a project and task, where the timer is running (see get_task method for details on returned parameters meaning)
Sample JSON response
If the request succeeds, the response will contain ok status and the following data:
{ "status": "ok", "data": [ { "id": "TIMER_ID", "time": "HH:II:SS", "date_started": "YYYY—MM—DD HH:II", "user_from": {
"id": "USER_ID",
"email": "USER_EMAIL", "name": "USER_NAME" }, "task": { "id": "TASK_ID", "name": "TASK_NAME", "page": "/project/PROJECT_ID/TASK_ID/", "status": "active", "priority": "1", "user_from": { "email": "USER_EMAIL", "name": "USER_NAME" }, "user_to": { "email": "USER_EMAIL", "name": "USER_NAME" }, "project": { "id": "PROJECT_ID", "name": "PROJECT_NAME", "page": "/project/PROJECT_ID/" },
"text": "TASK_TEXT", "date_added": "YYYY—MM—DD HH:II",
"date_start": "YYYY—MM—DD", "date_end": "YYYY—MM—DD",
"time_end": "HH:II", "max_time": 20, "max_money": 500,
"tags": {
"TAG_ID": "TAG_NAME_1",
"TAG_ID": "TAG_NAME_2"
}
} },
{
"id": "TIMER_ID",
"time": "HH:II:SS",
... ... ... } ]}
Was this article helpful?
Yes, thank you!
No