Token expiry #58
-
I note in the docs that the bot will warn you when your token is going to expire. Is there some way we can monitor that programmatically? |
Beta Was this translation helpful? Give feedback.
Answered by
isFakeAccount
Jun 22, 2024
Replies: 1 comment
-
In version 2.0.0 I made it easier to get the refresh token expiration time. See the documentation psn = PSNAWP(getenv("NPSSO_CODE", "NPSSO_CODE"))
print(psn.authenticator.refresh_token_expiration_time) This should work and you can write code to notify you at this time. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
isFakeAccount
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In version 2.0.0 I made it easier to get the refresh token expiration time. See the documentation
https://psnawp.readthedocs.io/en/latest/psnawp_api.core.html#psnawp_api.core.authenticator.Authenticator.refresh_token_expiration_time
This should work and you can write code to notify you at this time.