Hi Dinesh,
Thanks for posting your question in the Microsoft Q&A forum.
With the token store approach, you can retrieve tokens (Link) from the store when needed, and you can instruct App Service to refresh them automatically when they become invalid (Link). This approach is commonly used with Easy Auth in Azure App Service.
To accomplish this, you can follow the guidance provided in the documentation. Essentially, you leverage the Easy Auth feature of Azure App Service, which handles authentication and token management for you.
As described in the documentation, one way to avoid token expiration is by making a GET call to the /.auth/refresh endpoint of your application. This endpoint triggers a token refresh process, ensuring that your application always has up-to-date and valid authentication tokens.
Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful