12-08-2017 00:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

12-08-2017 00:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Story
I would like to be able to create an app on the Ionic watch that shows the sleep statistics like they are shown on the mobile Fitbit application, ofcourse in a more simplistic way.
I have found that the Web Api is providing the information I need in the sleep section. Although my problem is getting access to the Web Api.
Steps
- I did create an account for the fitbit developer studio
- Registered the application on dev.fitbit.com in order to get the Client ID and the Client Secret.
- I needed to register a callback url, which I don't know how this will work on the Ionic watch.
- Followed the github application: https://github.com/Fitbit/sdk-oauth
- Did not figure out how to do the last step: Fitbit mobile app > Ionic > Developer menu > your app > Settings
- After I created the app exactly like in the github, and start the application on the watch the waiting screen loads but after that nothing happens. I guess this is due the fact that the callback is not working. I could not find the Developer menu in the Fitbit mobile app.
Question
Is there an example project/page that explains me exactly how I would be able to use the Web Api from the Ionic watch so I could receive personal data?
Thanks for your help and time!
Kind regards,
Bruty

12-13-2017 11:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

SunsetRunner
12-13-2017 11:36
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
The callback URL should be https://app-settings.fitbitdevelopercontent.com/simple-redirect.html .
Since, as you wrote, you didn't figure out the settings part of it, the connection to the Web API won't work: the user (in that case, you), needs to give access to the part of the account data your application wants to use, and it's in the companion app settings. If you follow the Fitbit mobile app > Ionic > Developer menu > your app > Settings, you'll find the Login link (if you used the same code as in the SDK-Oauth example).

