08-10-2017 04:16
08-10-2017 04:16
We are using v1.2 API and we have found that Sleep stages individual values added does not match the Total Sleep value provided in API response. Following is an example:
{ "sleep": [ { "dateOfSleep": "2017-07-29", "duration": 9000000, "efficiency": 89, "endTime": "2017-07-29T23:30:00.000", "infoCode": 2, "isMainSleep": true, "levels": { "data": [ { "dateTime": "2017-07-29T21:00:00.000", "level": "asleep", "seconds": 7860 }, { "dateTime": "2017-07-29T23:11:00.000", "level": "restless", "seconds": 120 }, { "dateTime": "2017-07-29T23:13:00.000", "level": "awake", "seconds": 660 }, { "dateTime": "2017-07-29T23:24:00.000", "level": "restless", "seconds": 240 }, { "dateTime": "2017-07-29T23:28:00.000", "level": "asleep", "seconds": 60 }, { "dateTime": "2017-07-29T23:29:00.000", "level": "restless", "seconds": 60 } ], "summary": { "asleep": { "count": 0, "minutes": 132 }, "awake": { "count": 1, "minutes": 11 }, "restless": { "count": 3, "minutes": 7 } } }, "logId": 15346188572, "minutesAfterWakeup": 1, "minutesAsleep": 132, "minutesAwake": 17, "minutesToFallAsleep": 0, "startTime": "2017-07-29T21:00:00.000", "timeInBed": 150, "type": "classic" } ], "summary": { "stages": { "deep": 80, "light": 246, "rem": 87, "wake": 49 }, "totalMinutesAsleep": 132, "totalSleepRecords": 1, "totalTimeInBed": 150 } }
Here deep + light + rem from summary does not match with totalMinutesAsleep
Answered! Go to the Best Answer.
08-11-2017 09:32
08-11-2017 09:32
For one thing, the data you have there is not sleep stages. In your example, you'll see that you have:
"type": "classic"
This indicates that for that sleep record, sleep stages were not available. This is most likely due to the fact that the total time for the sleep record (totalTimeInBed) was < 3 hours (150min). In the Sleep Stages help page, it states:
Your tracker needs at least 3 hours of sleep data to estimate your sleep stages, so you won’t see sleep stages for shorter naps.
08-11-2017 09:32
08-11-2017 09:32
For one thing, the data you have there is not sleep stages. In your example, you'll see that you have:
"type": "classic"
This indicates that for that sleep record, sleep stages were not available. This is most likely due to the fact that the total time for the sleep record (totalTimeInBed) was < 3 hours (150min). In the Sleep Stages help page, it states:
Your tracker needs at least 3 hours of sleep data to estimate your sleep stages, so you won’t see sleep stages for shorter naps.
03-03-2022 17:05
03-03-2022 17:05
I just had a poor night's sleep and the Fitbit Restless total was 1 hour 1 min (61 mins). I had a severe insomnia last night and just looked at the blocks of restlessness for time periods and they started with a 31 min, then a period of awake, then 37 min, + more. That was already 68 mins restless in the first 1.5 hours. I have a screen shot of it, but i don't know how to attach that. There are a whole night of short restless periods after this as well. I think i got to 79 mins before 7am. Actually, the awake figure of 17 mins for the night was correct. Does Fitbit top out at 1 hour 1 min? Your thread was the closest thing i could find. Sorry if i have sent this to the wrong person. I know Fitbit is not a diagnostic tool. Sometimes it's more like a toy. Anyway, i don't have too many complaints or problems. I have had the watch for a few years and this is my first comment.