jason0x43 / alfred-toggl

Alfred Workflow for interacting with the Toggl time tracking service
MIT License
367 stars 16 forks source link

Anyway to create a timer when offline and sync later? #30

Open godbout opened 7 years ago

godbout commented 7 years ago

Hi there, I've installed Toggle just because of your workflow! I'm trying to find an app that can track time even when not having a connection. The Toggle desktop app can do that and sync once online, but would it be possible through the APIs and your workflow? I'm trying to make a workflow myself which starts the Toggle app with some args but I can't make it work, gonna contact the Toggle guys too. Just digging!

jason0x43 commented 7 years ago

It's certainly possible. There are a couple of ways to go about it. Probably the simplest thing for a workflow to do would be to simply cache the information for locally created time entries when no connection is available, then post them to toggl.com the next time a connection is available.

Currently when a user accesses this workflow, it will refresh it's local cache from toggl.com if the last refresh was more than 5 minutes ago. That would be a reasonable point at which to post any local-only data as well.

godbout commented 7 years ago

Todo list? :D I'd be happy to give a hand but Go? No go. I'll check later if I can do something in PHP. Your workflow works very well, and I'm still playing with both Harvest and Toggl, so I'm updating the outdated Harvest workflow. Might be back here soon. Thanks for the answer!