API AccessToken/RefreshToken change expire time

Is there any possibility to change the expire time of these 2 token?

Thanks.

I assume you could via the php.ini or server configuration atho not sure where it’s tied in. Threads like these may help https://stackoverflow.com/questions/30849864/oauth2-php-change-expiration-time