A minimal JSON Web Token
Project description
Simple JWT
Abstract
Simple JWT is a JSON Web Token authentication plugin for the Django REST
Framework
For full documentation, visit django-rest-framework-simplejwt.readthedocs.io
二次开发的Simple JWT
Installation
You can use this command to install this package:
pip3 install djangorestframework_simplejwt_captcha
Usage
from djangorestframework_simplejwt_captcha.views import TokenObtainPairView,TokenRefreshView,ImageInfo
urlpatterns = [
path('api/token/', TokenObtainPairView.as_view(), name='token_obtain_pair'),
path('api/token/refresh/', TokenRefreshView.as_view(), name='token_refresh'),
path('api/images_captcha/',ImageInfo.as_view(), name='images_captcha'),
]
- api/images_captcha 是获取图片base64和uuid
- api/token/是登录获取jwt
传入4个参数
- username
- password
- uuid # 获取上一个api 的uuid
- captcha # 图片验证码
- api/token/refresh 刷新token
For more information, see here
验证码有效期是120秒
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for djangorestframework_simplejwt_captcha-1.1.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd29f889e4d0aa6ba93da9e332ed369ea67e4fc2fee72a96a236f6a6ee28bb8b |
|
MD5 | 2a14be9be0b647dc2e1eafef8ddc580d |
|
BLAKE2b-256 | aec27cc778cd2f681d7d97111e1890d07d1f3e0a696f60a901e694290af6d3cb |
Close
Hashes for djangorestframework_simplejwt_captcha-1.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a44ee5622f5e1fc434c1a9dfef5a2a0c7b37b2424f5432762dc37634193c84f4 |
|
MD5 | 4e1c6ee7c78f95560bdb8b92569ac359 |
|
BLAKE2b-256 | be044542356d2bd89823530d3cba4ec54e4dff6f4a0ab998c191ba291c8768b9 |