Rana's avatar
Level 1

tymon/jwt-auth for laravel 5.4 refresh token

I recently using laravel 5.4 and i want to use tymon/jwt-auth package to secure my APIs by sending the access token but my issues happened when token expired i can't refresh it before expired and i expected the token will be refreshed automatically

0 likes
2 replies
bobbybouwmann's avatar

So the token is not refreshed automatically. Normally with a JWT API you get two tokens. One for access, the access_token and one to refresh the token a refresh_token. You use the access_token for requests as the authenticated user. However that token might expire. If you then want a new access_token you use the refresh_token to obtain a new access_token. I believe this is also gives you back a new refresh_token, but that depends on your implementation ;)

Rana's avatar
Level 1

i received only one token , and i can't call refresh token if the token is expired , i received error message contains this token in blacklist

Please or to participate in this conversation.