01-30-2016 18:32 - edited 01-30-2016 18:34
01-30-2016 18:32 - edited 01-30-2016 18:34
Heyo
Having an issue today (this wasn't happening previously) where the api server does not like my Authorization header for a token request (exchanging a code for a access and refresh token).
Was previously working before today, code hasn't changed. Just using the documentation that states:
"Base64 encoded string, Y2xpZW50X2lkOmNsaWVudCBzZWNyZXQ=, is decoded as "client_id:client secret""
But am getting back a 400 Bad Request with this error:
{"errors":[{"errorType":"invalid_grant","message":"Authorization code invalid: 45d0a55a61b69d400e14daa52d4784a5204fa151 Visit https://dev.fitbit.com/docs/oauth2 for more information on the Fitbit Web API authorization process."}],"success":false}And yes... before anyone asks... I am using my own client_id and client secret 😛
01-31-2016 11:20
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.
01-31-2016 11:20
invalid_grant isn't about your Authorization header. It's telling you that the authorization 'code' you're sending in the Access Token request is not valid.
Best Answer