Skip to Main Content


[APEX] Refresh a token or generate a new - Web credentials

merciergMar 16 2021

Hello everyone,
I have a question regarding the refresh token mechanism.I have an application with an authentication scheme based on a web credentials. This web credentials is configured on an Azure OpenId.
When the user logs into the application, there is a consent before accessing to the application. The generated token is available during one hour and i use it in several web services when the use navigates from pages to pages.
Every hour, web services calls failed because the token is expired. When i generate the token, i dont get any "refresh-token" after the connexion so i am not sure to be able to refresh the expired token.
I tried to generate a new token directly by using the token url/client id/client secret through pl/sql with apex_webservice.make_rest.Currently the only way the user has is to log in again every hour but its not sufficient and user friendly.
For information, i use APEX 18.2/Oracle 12.1
Any help appreciated,

Post Details
Added on Mar 16 2021