05-22-2015 10:37
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-22-2015 10:37
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Hi,
With the new support for multiple trackers for a given user, I am wondering how does this affect the api and push notifications. Say a user has two devices A and B. If my application receives push notifications for this user how can I determine which device is reporting activity?
Similarly if want to fetch the latest sleep data for device A how would one formulate this query?
Subscription API. I've setup my users for push notifications but it seems that when I subscribe for all events the notification collection type always report "activities". So I have no clue which activity actually reported new data ie hr, steps, sleep?? - I understand I can add subsriptions for each individual activity but I would like to be able to say notify me when a new activity is reported and expect the notification to contain a clue as to which activity actually changed. Lastly if a user update her profile it doesn't seem that this event triggers a notification?

- Labels:
-
OAuth 2.0
-
Subscriptions API
05-22-2015 10:48
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


05-22-2015 10:48
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Activity type basically means one of following things changed for user:
steps, calories, elevation, distance.
When you get notification with activities type I'd just suggest to make activities request for that date.
For sleep you'll get different notification type.
See more details at: https://wiki.fitbit.com/display/API/Fitbit+Subscriptions+API
Senior Software Developer at Fitbit

05-26-2015 10:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 10:31
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Makes sense. Thank you! - Can you also answer the other questions that are part of the original post ie tracking push notifications when multiple devices for a given user are at play.
Thanks!

05-26-2015 10:34
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


05-26-2015 10:34
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I'm confused with your last post.
To answer this question:
[ Lastly if a user update her profile it doesn't seem that this event triggers a notification?]
Yes this is correct. We do not send push notifications when user updates his profile.
Senior Software Developer at Fitbit

05-26-2015 11:20
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 11:20
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Sorry. That was indeed confusing. Let me rephrase...
Say a user has 2 trackers A and B. User registers with fibit for push notifications.
1) How do I know which of the 2 devices trigger the notification? ie steps activity was collected for device A or B.
2) Once I get a notification. How does one request metric data for a given device?
ie I want to get steps/sleep/hr for device A or B.
I am not seeing in the api where one would request steps data for a specific device. What am I missing?

05-26-2015 11:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


05-26-2015 11:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
This is currently not possible.
Senior Software Developer at Fitbit

05-26-2015 11:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 11:44
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Thanks for the reply. Can u elaborate? This feature is available in the dashboard. I can see metrics reported for each of my devices. Is this feature coming in the API or will not at all be supported?

05-26-2015 11:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


05-26-2015 11:55
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
We currently have no plans on supporting it. It may change in future though. No promises or estimations yet.
Senior Software Developer at Fitbit

05-26-2015 12:02
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 12:02
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Woa! This is surprising. Just to make sure we're on the same page here.
Are you saying that this announcement https://blog.fitbit.com/sync-multiple-trackers-to-your-fitbit-account-with-multi-tracker-support/ will NOT be supported or planned to be supported by the API?
Sorry to beat this dead horse if so.
Thanks!

05-26-2015 12:04
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


05-26-2015 12:04
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
I'm saying that there is no plans for API push notifications to be saying what device the push notification belongs to.
I'm also saying that it may change. I just don't want to give any promises.
Senior Software Developer at Fitbit

05-26-2015 12:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 12:24
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Understood - So to be clear, since there are 2 separate use cases here: Outside of the push notification is there a way to request a given metric for a given device then? Or is this not supported either?

05-26-2015 13:39
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

05-26-2015 13:39
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
@derailed wrote:Thanks for the reply. Can u elaborate? This feature is available in the dashboard. I can see metrics reported for each of my devices. Is this feature coming in the API or will not at all be supported?
@derailed How do you see the data in the dashboard separately for your two trackers? (The whole point of Fitbits multi-tracker support is that you only wear one Fitbit at a time and the data is combined automatically so you only see one set of data for all of your trackers.)
I certainly can't find any way to see just the data for one of my trackers linked to my account through the dashboard.

05-28-2015 17:27 - edited 05-28-2015 17:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post



05-28-2015 17:27 - edited 05-28-2015 17:27
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
@derailed wrote:
Sorry. That was indeed confusing. Let me rephrase...
Say a user has 2 trackers A and B. User registers with fibit for push notifications.
1) How do I know which of the 2 devices trigger the notification? ie steps activity was collected for device A or B.
The device sync itself doesn't trigger the notification—the change in data triggers the notification. A change in data could come from a tracker or a manual log. The Subscriptions API doesn't currently give a reason for the change in data.
@derailed wrote:
2) Once I get a notification. How does one request metric data for a given device?
ie I want to get steps/sleep/hr for device A or B.
I am not seeing in the api where one would request steps data for a specific device. What am I missing?
Fitbit intelligently combines data from multiple devices and sensors. The data is available in a unified manner, not per device.
