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

Key stats for an activity do not match website or reconcile with each other

I'm trying to exactly match the stats between what is presented on your interface and what is returned through the API data with the activity endpoint and TCX file endpoint. These are for running type activities particularly those with pauses.

 

Referencing this example with LogId: 22070431737

 

Fitbit interface

interface.png

 

API

duration1260000ms  = 21:00

distance: 3.256906km

speed: 10.4706 = 5:43min/km

implied duration from speed and distance: 3.256906 / 10.4706 * 60 = 18:39

 

TCX File From API

duration from laps: 561 + 572 + 84 = 1217 = 20:17

distance from laps: 1609.344 + 1609.344 + 225.30816 = 3443.99616

 

So there's a few issues:

  • The duration, distance, and speed returned for the activity don't match the recorded values.
  • The speed, distance and duration returned from activity response don't reconcile with each other (D = R * T)
  • The TCX file returns data which almost but doesn't exactly match.

Given the rate limits Fitbit has in place, it's not feasible to poll every TCX file for each of a user's runs to get (nearly) correct pace, distance, duration values. My question is where do these activity endpoint API values come from, and why don't they match the recorded values? It seems highly unlikely that Fitbit would internally maintain the correct values, and also an entirely different set of values to provide through the API for a given activity, so I think must be missing something fundamental. 

 

Can you help me to understand how to calculate values that match those provided on the Fitbit website by using the response from activity list endpoint?

 

Thanks,

Chris

 

JSON response for reference:
json.png

 

 

Best Answer
0 Votes
5 REPLIES 5

Hi @smashrun,

 

I'm sorry to hear that you're running into these inconsistencies with the data you are gathering from the TCX files.

 

So that I can investigate, can you PM me the user ID that you are seeing these discrepancies on?

 

Thanks!

Best Answer
0 Votes

I PMed you the userId.

 

Note: The TCX file is correct, or at least nearly correct. It's the activity endpoint which is far off. Of course, ideally I'd like to match to the second and meter what is displayed on the Fitbit website/app.

 

Best Answer
0 Votes

Hi @JohnFitbit,

 

Any update on this?

 

Thanks!

Best Answer
0 Votes

Hi @smashrun,

 

I replied to you via PM. Let me know when you've taken a look.

 

Thanks!

Best Answer
0 Votes

No worries. I just wanted to make sure it was on your radar.

 

We're currently in the middle of beta testing our new integration, and fielding issues from users. This one I was able to replicate with my own data. Thanks for your attentiveness and time.

 

(I'm unable to reply via PM because "I reached the max number of private messages I could send at this time" ...which is currently one, presumably because my account is new(ish)?)

Best Answer
0 Votes