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

Oauth2 issue with Home Assistant integration

ANSWERED

I try to figure out how to get the fitbit integration in home assistant to work. The issue I have is that an link to my fitbit app is created and opened but the redirect_uri parameter is not accepted

Developer information: invalid_request - Invalid redirect_uri parameter value

The link is like this: https://www.fitbit.com/oauth2/authorize?response_type=code&client_id=********&redirect_uri=https://m...

Setting the redirect_uri to "https://my.home-assistant.io" is a home assistant feature to get https for a server that is hosted on the local network where TLS is not always setup. Why is that not accepted by the fitbit server?

Best Answer
0 Votes
1 BEST ANSWER

Accepted Solutions

Hi @guzzzt 

The redirect URL should be an open endpoint where the authorization code can be accepted and processed.   Is that the case with https://my.home-assistant.io or is there another endpoint?   Also, https://my.home-assistant.io needs to be listed in your application settings at https://dev.fitbit.com/apps.

Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google

View best answer in original post

Best Answer
0 Votes
3 REPLIES 3

Hi @guzzzt 

The redirect URL should be an open endpoint where the authorization code can be accepted and processed.   Is that the case with https://my.home-assistant.io or is there another endpoint?   Also, https://my.home-assistant.io needs to be listed in your application settings at https://dev.fitbit.com/apps.

Gordon Crenshaw
Senior Technical Solutions Consultant
Fitbit Partner Engineering & Web API Support | Google
Best Answer
0 Votes

Thank you, changing the redirect URL to https://my.home-assistant.io/redirect/oauth on https://dev.fitbit.com/apps fixed it for me.

Best Answer
0 Votes

An OAuth2 issue with Home Assistant integration could stem from incorrect client credentials, mismatched redirect URIs, or insufficient permissions granted during the authentication process.

Best Answer
0 Votes