DEV Community

Discussion on: How do you handle role/permissions updates with JWT?

Collapse
 
sebastiandg7 profile image
Sebastián Duque G • Edited

Thanks a lot for sharing!

I tend to handle it this way. The user's authorization data is queried with a REST endpoint (/api/users/me). The main challenge with this approach is knowing what kind of user interaction triggers an authorization data update in order to have new changes as "real time" as possible. Usually, this interaction is related to users navigation in the app menu.

EDIT:

Your driving license analogy is great!