I am having a bit of trouble authenticating my users.
I post here to request the tokens.
POST /oauth/request_token
oauth_token and oauth_verifier are returned. I pass these to the next function that returns profile XML.
But then when I try and call the profile I get this error message...
Fatal error: Uncaught exception 'FitBitException' with message 'Fitbit request failed. Code: 401' in /var/www/html/MODULES/fitbitphp-master/fitbitphp.php:325 Stack trace: #0 /var/www/html/MODULES/Fitness_Devices/fitbit_profile.php(37): FitBitPHP->getProfile() #1 {main} thrown in /var/www/html/MODULES/fitbitphp-master/fitbitphp.php on line 325
When I check the authentication of the user with the system says that the user is not authenticated. But I clearly went to the fitbit login section and the proper keys were returned.
Can anyone see what I am doing wrong?
Thanks.
Best Answer
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
As message says you'r probably using invalid signature OR/AND token
Best Answer
Best Answer
Fitbit Developers oversee the SDK and API forums. We're here to answer questions about Fitbit developer tools, assist with projects, and make sure your voice is heard by the development team.
Try to generate CURL string and make request from this page: https://dev.fitbit.com/apps/oauthtutorialpage
Best AnswerAre you aware of any way to see what keys are valid keys without passing them to the API? Perhaps some type of console that lists the available keys. Even if it is just pulic keys, it would make debugging much easier.
Thanks.
Best Answer