07-08-2019 07:02
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

07-08-2019 07:02
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hello,
We have a web app consuming Fitbit WebAPI activities which uses "Server" style OAuth 2 or Authorization Code Grant Flow coupled with subscriptions. We have configured subscriptions a long time ago and it worked great for all of our users, save the occasional, unexplained 409 error during the Fitbit authorization phase.
Recently, we've observed that even though subscription notifications of activities are received, like so:
{ "_json": [ { "collectionType": "activities", "date": "2019-07-08", "ownerId": "123ABC", "ownerType": "user", "subscriptionId": "12345" }, { "collectionType": "activities", "date": "2019-07-08", "ownerId": "456DEF", "ownerType": "user", "subscriptionId": "67890" } ] }
the actually retrieved data has goals and summary section but no activities:
{ "activities": [ ], "goals": { "activeMinutes": 30, "caloriesOut": 2184, "distance": 5, "floors": 10, "steps": 10000 }, "summary": { "activeScore": -1, "activityCalories": 7, "caloriesBMR": 499, "caloriesOut": 506, "distances": [ { "activity": "total", "distance": 0.04 }, { "activity": "tracker", "distance": 0.04 }, { "activity": "loggedActivities", "distance": 0 }, { "activity": "veryActive", "distance": 0 }, { "activity": "moderatelyActive", "distance": 0 }, { "activity": "lightlyActive", "distance": 0.04 }, { "activity": "sedentaryActive", "distance": 0 } ], "elevation": 0, "fairlyActiveMinutes": 0, "floors": 0, "lightlyActiveMinutes": 3, "marginalCalories": 3, "sedentaryMinutes": 0, "steps": 105, "veryActiveMinutes": 0 } }
Note the empty activities stanza. Our users do have activities they track, like swim or bike that have shown up in the past, but for s subset of our users no activities has shown up when subscriptions were being retrieved. When we requested those users to check activity log on Fitbit, it showed Bikes and Swims activities.
Any idea what might be going wrong?
Thank you,
Pawel Osiczko
Run The Edge

- Labels:
-
Subscriptions API
07-09-2019 14:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post



07-09-2019 14:13
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hi @PawelRTE,
I'm sorry to hear that you're not seeing activities from users despite receiving a notification for it.
So that I can investigate further, can you private message me your Client ID and the User ID(s) of which you are seeing activity notifications for, but no activities are logged?
Let me know if you have any questions in the meantime. Thanks!

