I had a query regarding refreshing and updating an authentication token. I have a microservice backend that receives a keycloak token from the client side, and I'm using keycloak-connect to apply the middleware and protect the calls to this microservice, but I need to update this token, is it possible to get a new token using keycloak-connect?
I had a look at other suggestions in this group and one user posted this call that we can make:
An HTTP Post to auth/realms/{realmName}/protocol/openid-connect/token
With x-www-form-urlencoded body containing
grant-type=refresh_token
client_id={yourClientId}
refresh_token={your refresh token}
However I'm not passing down to the microservice the refresh_token, I only have the access_token.
Any suggestions on how I can tackle this issue?
Thanks