<div dir="ltr"><div><div>Hi,<br>I made an app use bearer authentication with Keycloak . I have another app which wants to use this REST api.<br></div>As I know until now, It needs to get token from Keycloak server (I use POST method), then add this token to the request It needs to send.<br><br></div>But, there's one important issue. This client want to have assess hundreds time each minute. Is there any tools for Keycloak to help me update the token when it's required? I mean keep the token for example for 15 minutes (validation time) then renew it when it's required. I made a statefull class which get configuration and has getToken() method. Then when the other classes ask for new token, if it expired this method synchronously will get new one and return it (Direct grant). Is it right? Is there anything standard inside of the Keycloak lib already?<br clear="all"><div><div><div><br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Best regards,<br></div><div>Hamed<br></div></div></div></div></div>
</div></div></div></div>