How can I renew access token in SPA+PKCE setup

Hi I’ve setup SPA+PKCE for getting code and access token. I wanted to validate access token for every REST API call. If the access token expires, I want to request for new token without any error or login details. The problem that I see with prompt=none, it errors saying JWT expired.

Appreciate any help.

com.okta.jwt.JwtVerificationException: Failed to parse token
at com.okta.jwt.impl.jjwt.TokenVerifierSupport.decode(TokenVerifierSupport.java:67)
at com.okta.jwt.impl.jjwt.JjwtAccessTokenVerifier.decode(JjwtAccessTokenVerifier.java:45)
at com.tagnosys.ui.restcontroller.JWTUtil.validateOktaJWT(JWTUtil.java:187)
at com.tagnosys.ui.restcontroller.JWTUtil.main(JWTUtil.java:202)
Caused by: io.jsonwebtoken.ExpiredJwtException: JWT expired at 2020-07-24T14:59:03Z. Current time: 2020-07-27T12:09:37Z, a difference of 248914201 milliseconds. Allowed clock skew: 120000 milliseconds.
at io.jsonwebtoken.impl.DefaultJwtParser.parse(DefaultJwtParser.java:439)
at io.jsonwebtoken.impl.DefaultJwtParser.parse(DefaultJwtParser.java:541)
at com.okta.jwt.impl.jjwt.TokenVerifierSupport.decode(TokenVerifierSupport.java:61)