1

I would like to create a report for one Clockify project (I do know its ID) agregated by users. The result would be like this:

Project XY

User 1: XX (grouped duration) User 2: YY (grouped duration) User 3: ZZ (grouped duration) etc.

Is there any better way than iterating through all users calling this API?

/workspaces/{$workspace_id}/user/{$user_id}/time-entries?project={$project_id}&start={$start}&end={$end}

This is too slow and the request return only 50 time entries. Our projects have hundreds (some projects even thousends) of entries.

Petr
  • 111
  • 7

1 Answers1

1

From the documentation if you go down to Find time entries for user on workspace you can see that the page-size parameter has a default value of 50. So if you change it to 10000 let's say, you can get away with just 1 query per user.

Stefanos Chrs
  • 2,228
  • 3
  • 19
  • 46
  • 1
    It works, thank you! This is probably a new parametr. Or it missed it before... – Petr Mar 29 '20 at 17:29
  • 1
    I've created this simple tool https://github.com/stefanoschrs/clockify the other day which does this aggregation if you want to check out the calls. – Stefanos Chrs Mar 30 '20 at 07:40