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 rest_framework_simplejwt.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秒
Release files for djangorestframework-simplejwt-captcha 1.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| djangorestframework_simplejwt_captcha-1.1.6.tar.gz | 23.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| djangorestframework_simplejwt_captcha-1.1.6-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 70.5 kB
Release files / djangorestframework_simplejwt_captcha-1.1.6.tar.gz
| Download URL | djangorestframework_simplejwt_captcha-1.1.6.tar.gz |
|---|---|
| Size | 23.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9921ed7e9b46c10d3a7bf8efe96018dc3f74aa7e7fa9d6f1d760a34558aaa7f9
|
|
BLAKE2b-256 checksum How to use checksums |
7192d84325d12a70b2906c1ffb93ca1badca7703e2fd7bfffa86c7e5b796470d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.6.3
|
Release files / djangorestframework_simplejwt_captcha-1.1.6-py3-none-any.whl
| Download URL | djangorestframework_simplejwt_captcha-1.1.6-py3-none-any.whl |
|---|---|
| Size | 47.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8283a3259fb082792598a418544e79594e9f6d28c797a43ec619d385dc97591c
|
|
BLAKE2b-256 checksum How to use checksums |
6639dc56fb6832cc0213ecdcfed144b38e6403e7fa002360bfe74e27e1331e11
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.6.3
|