08-17-2021 00:34
08-17-2021 00:34
I know this already has a topic, but wanted to ask my own question. We are building an application to sync users' logged activities to our server. We only want to sync logged activities, and have no use for updated step counts or the like. With the activity subscription enabled, we are receiving 15 minute updates for a single user. Each of these updates contains minimal information, and requires a further call to the API to find out that the ping was simply because of updated step information throughout the day. Often in a day, a user will not log any activities, and yet, the system is pinged throughout the day.
As a further API call is needed to check that there are no new logged activities to sync, we have to stagger our API calls, especially as we take on more and more users. The documentation for the subscription states that the solution to this is to mark the user "dirty" on our server, and then poll for updates at a time when they log back onto the server. However, this is not applicable in our scenario, we need up to date information for all users at all times. Currently, when I get a subscription ping about a user, I am logging the last time that a user's activities were synced, and if that is more than 6 hours ago, I make a request for further information. However, as the server gets pinged every 15 minutes about the users step updates, this no different from manually polling the server every 6 hours. Surely the whole point of webhooks/subscriptions or whatever you want to call them, should be that we only have to make a request from the API at the time when there is new relevant information, and I know that they work perfectly in other activity tracking services.
Does anyone have any suggestions?
08-20-2021 13:11 - edited 08-26-2021 16:17
08-20-2021 13:11 - edited 08-26-2021 16:17
Hi @niallmccune.
Thanks for sharing your idea and reasoning behind it. This is definitely something we're looking into improving but unfortunately do not have a timeline for it. In the meantime, I recommend visiting the feature suggestions post for this idea and share your comments there (or upvote it) so we can continue to track interest for it: https://community.fitbit.com/t5/Feature-Suggestions/Web-API-Notification-collection-for-Exercise-Fit...
As interest grows for this idea, it may be considered and prioritized in our future roadmaps.
Let me know if you have any additional questions.
08-23-2021 01:38
08-23-2021 01:38
Thanks John for your response, much appreciated.
No problem. I did upvote the original feature suggestion, and will add a comment to it too, just wanted to check whether there was something I was missing.
P.S. apologies if my initial comment seemed a little passive aggressive, which I realised it might have sounded as I read it back after I posted it! That was not my intention. I tried to edit it, but couldn't see where I could edit the posted comment.
Regardless, thanks again for your response.