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

Api doesn't return sleep log data

I have a lot of sleep data in my iOS app this week, but when I call the api for data:

 

https://api.fitbit.com/1/user/-/sleep/minutesAsleep/date/today/1w.json, or

https://api.fitbit.com/1/user/-/sleep/startTime/date/today/1w.json, or even

https://api.fitbit.com/1/user/[user-id]/sleep/date/2016-10-14.json

 

all I get is zero values.

 

Edit:

 

I was logged in with incorrect user credentials, coming from a cookie from a another user of my phone. I had to add prompt-parameter to authorize url to get rid of this cookie in the webview.

 

Best Answer
0 Votes
1 REPLY 1

@henkiejan wrote:

 

Edit:

I was logged in with incorrect user credentials, coming from a cookie from a another user of my phone. I had to add prompt-parameter to authorize url to get rid of this cookie in the webview.

 


@henkiejan I assume that means you're getting correct values now? If not, let me know.

Andrew | Community Moderator, Fitbit

What motivates you?

Best Answer
0 Votes