We have an application that uses firebase authentication for logging users into an android app. The problem is that when the user closes the app and later returns, the firebase token id is expired and the current user returns null.
I have read many articles and found that the Firebase refresh token can be used to get a new firebase token ID. However, I am struggling to find how to extract or get the firebase refresh token when a user logs in to the app.
I have two questions there.
Is there any way that when a user opens the app after a few days, the firebase token Id is automatically refreshed? Currently, it seems to have expired and does not get a new one.
I have read articles that you can make a call to get the new firebase token id. However, the API requires an API key and refresh token in the parameters. I need help to find out how do we get the firebase refresh token during the sign-in? Is it returned by default as a response to the authentication or do we need to make a separate call for getting the user's refresh token?