Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Device and Companion API

Hello all,

I am new to the community. I just wanted to ask if there is any way in which we can get the data that are stored in Device/Companion API (i.e. gyroscope and accelerometer) via my own application which is created using https://dev.fitbit.com/apps/new.

 

Best Answer
0 Votes
5 REPLIES 5

Yes, but I think you're combining two fairly different environments.

 

The device/companion APIs deal with info that's available on the device and companion. They involve writing programs that run on device/companion.

 

The link you provided was for the Web API. The Web API makes some data available for download (eg, to web sites and programs running on any device). It provides data from Fitbit's servers, which has been obtained from watches after syncing. However, sensor data (such as gyro and accelerometer) isn't synced so isn't available via the Web API.

 

If you want sensor data, ignore the Web API and focus on the device/companion APIs. Be warned: collecting large amounts of data is difficult, and getting it out of the device/companion is even difficulter. 😉 However, it can be done.

Peter McLennan
Gondwana Software
Best Answer
0 Votes

So, we cannot make use of the sensor data outside the Fitbit studio? Also, if we use and develop something with the sensor data, where will the application be hosted/used? 

Best Answer
0 Votes

You definitely CAN make use of the sensor data using Fitbit Studio. Fitbit Studio makes programs that run on your watch and phone (companion), so they have access to the sensor data that you can get via the Device API.

 

The hard part is getting the sensor data from the watch/companion to anywhere else (assuming that's what you want to do). You have to use fetch() or WebSocket on companion to send your sensor data elsewhere.

 

However, if you're happy to make use of the sensor data entirely on the watch, that's easy. And it isn't too hard to get it from watch to companion (see messaging and file transfer APIs).

Peter McLennan
Gondwana Software
Best Answer
0 Votes

Any project/app that I can follow? It will be very helpful.

Best Answer
0 Votes

Hi @getamu ... I moved your post to the Device SDK forum.  This is the best place for discussions on the Device and Companion APIs, and retrieving the sensor data from the devices.

Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google
Best Answer
0 Votes