Use with SimpleJWT

Quick update, I’ve managed to make it work by subclassing the Token class in rest_framework_simplejwt.tokens.

Basically, I’ve replaced self.payload = token_backend.decode(token, verify=verify) in the constructor by my own decoding backend using jwt (also what is recommended in Auth0’s Django API quickstart).

Instead of getting the verifying key (which is basically the public_key in the quickstart) from a static settings.py variable (in SIMPLE_JWT), I’m retrieving it from an Auth0 endpoint.

4 Likes