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

Auto-fill email field and password field while login using the Implicit Grant Flow

Hi,

 

How can i auto-fill email field and password field while login using the Implicit Grant Flow. As my app requirement is not to share the password with the customer. So i have to fill the email and password field when the page is fully loaded. I am able to enter the data but the login button is not able and if somehow i enable the login button then the validation message appears saying 'Please enter the valid data.' 

 

So please suggest a way out. 

 

Thanks.

Best Answer
0 Votes
4 REPLIES 4

Please fitbit team reply on the query. I need this implementation asap. It is happing with chrome autofill but not with the coding.

 

Thanks 

Best Answer
0 Votes

Hi @harsh-sqm,

 

I'm sorry for the delayed response, and I'll be happy to assist you.

 

It sounds like you may be trying to enter a password and email for your users to provide consent to your application using the Implicit Grant Flow. Please know that consent flow requires that the user enter their own Fitbit account credentials in order to give consent to your application to access their data. See below:

 

  1. Your application redirects the user to Fitbit's authorization page. See Authorization Page.

  2. Upon user consent (using their own email and password associated to their Fitbit account), Fitbit redirects the user back to your application's redirect URL with an access token as a URL fragment.

  3. Your application stores the access token client side. It will use the access token to make requests to the Fitbit API.

For more information on the Implicit Grant Flow, please see our documentation here. I hope this helps!

 

 

Best Answer
0 Votes

Hi John,

 

You are right. But here the user(patient) cannot remember his credentials. And also one more thing, we have created the account for him in the first place. He only has to wear the fitbit device and has to come bi-weekly to sync his fitbit data with our servers. So over here we are taking about 1000+ user. So clinic administrator people hard to keep track of there fitbit account credentials. Thats why we want to save the credentials to our server in encrypted format and when at the time or login in our app the implicit grant flow proceeds and the credentials will auto fill in the page. So that they have to just press login button on that page.

 

That is the whole functionality of the app. Please understand and let me know a solution.

 

Thank you

Best Answer
0 Votes

Hi @harsh-sqm,

 

Thanks for clarifying that information.

 

Your users will need to log into the account that was created for them each time to sync their data (whether using the implicit grant flow or authorization code grant flow).

 

If the user had forgotten the credentials provided to them, the only suggestion I can provide is having them go through the password reset process outlined in the 'How do I change or reset my Fitbit password?' article. If the email address is unknown, you may need to create a new account for the user (or have them create an account themselves so they have access to it) and ensure that they keep track of the credentials moving forward. 

 

Additionally, most devices/browsers offer users to save their account credentials to avoid having to enter their information each time. 

 

Lastly, per the 'How do Fitbit devices sync their data?' article, certain devices can only store minute to minute data for up to 7 days. If your users are coming in on a biweekly basis, you may be losing data. I recommend allowing the user to sync their data more frequently through the app on a mobile device, or a personal computer, or have them come in more often to avoid losing data. 

 

I hope this information helps. Please let me know if you have any additional questions.

Best Answer
0 Votes