toggl / toggl_api_docs

Documentation for the Toggl API
1.39k stars 235 forks source link

Why doesn't the Detailed report return a client_id #335

Closed MarkGrenville closed 5 years ago

MarkGrenville commented 5 years ago

Would it be possible to return the client_id for the Detailed report? This really seems like an oversight.

webervin commented 5 years ago

You can use returned project id value (pid:integer) to find out client id for this given project in api v8.

MarkGrenville commented 5 years ago

Unfortunately, in my case, that means 50 extra API calls.

webervin commented 5 years ago

you can implement local cache, that maps project id to client id and lasts say 1 day, so you would need to do new request only for projects that you did not see in past.

or maybe you can invert logic, and filter detailed report by client_ids, iterating over list of known client id's, it all depends on how time entries are distributed among clients in your workspace(s).