Simple JWT¶
A JSON Web Token authentication plugin for the Django REST Framework.
Simple JWT provides a JSON Web Token authentication backend for the Django REST Framework. It aims to cover the most common use cases of JWTs by offering a conservative set of default features. It also aims to be easily extensible in case a desired feature is not present.
Acknowledgments¶
This project borrows code from the Django REST Framework as well as concepts from the implementation of another JSON web token library for the Django REST Framework, django-rest-framework-jwt. The licenses from both of those projects have been included in this repository in the “licenses” directory.
Contents¶
- Getting started
- Settings
ACCESS_TOKEN_LIFETIME
REFRESH_TOKEN_LIFETIME
ROTATE_REFRESH_TOKENS
BLACKLIST_AFTER_ROTATION
UPDATE_LAST_LOGIN
ALGORITHM
SIGNING_KEY
VERIFYING_KEY
AUDIENCE
ISSUER
JWK_URL
LEEWAY
AUTH_HEADER_TYPES
AUTH_HEADER_NAME
USER_ID_FIELD
USER_ID_CLAIM
USER_AUTHENTICATION_RULE
AUTH_TOKEN_CLASSES
TOKEN_TYPE_CLAIM
JTI_CLAIM
TOKEN_USER_CLASS
SLIDING_TOKEN_LIFETIME
SLIDING_TOKEN_REFRESH_LIFETIME
SLIDING_TOKEN_REFRESH_EXP_CLAIM
CHECK_REVOKE_TOKEN
REVOKE_TOKEN_CLAIM
- Customizing token claims
- Creating tokens manually
- Token types
- Blacklist app
- Stateless User Authentication
- Development and contributing
drf-yasg
Integration- rest_framework_simplejwt package