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

Access public user data without OAuth?

ANSWERED

Heyhey,

 

I understand from the doc's page "API get user info" that public profile data requests do not require an OAuth-token.

 

However, when I use the API explorer with "Get User Info" from my own profile (everything public there!) with "No Auth", I get a bad request, i.e. OAuth error (see screen shot below).

 

Am I doing something wrong or can the public profile data simply not be accessed without OAuth?

 

I'd be very happy about any hint here 🙂

 

Screen shot of API explorer

 

 

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Get User Info will return public profile data when only signed with client credentials. You would only pass your consumer key without a user access token and sign the request with your consumer secret without a user access token secret.

 

This probably won't work in the API Explorer, as I think that app requires a user authorization in order to sign the request at all.

 

However, client-only access to the FItbit API is likely to be removed in the future and relying on this functionality is strongly discouraged. You should only ever make requests to the Fitbit API on behalf of an authorized user.

View best answer in original post

Best Answer
0 Votes
2 REPLIES 2
It will work if you authenticate with any account, even if it doesn't have a device setup for it. So with my account signed in with oAuth I can see from your public profile: "displayName": "Jessica", and date of birth, and badges, etc. That might not be a great explaination but "No Auth" might not be available right now and should really say "Public when Authed as anyone"
Best Answer
0 Votes

Get User Info will return public profile data when only signed with client credentials. You would only pass your consumer key without a user access token and sign the request with your consumer secret without a user access token secret.

 

This probably won't work in the API Explorer, as I think that app requires a user authorization in order to sign the request at all.

 

However, client-only access to the FItbit API is likely to be removed in the future and relying on this functionality is strongly discouraged. You should only ever make requests to the Fitbit API on behalf of an authorized user.

Best Answer
0 Votes