We are mainly using the id token.
In our current configuration the id token expires after 30 days, then the client should make a /token GET request which returns a new id token (using openidScopeBackwardCompatibility: true) which is valid for the next 30 days.
Our refresh tokens expire after 5 years.
We would like to run a custom script whet this GET /token is executed, or when an id JWT token is created.