You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

32 lines
1.1 KiB

from django.urls import path, re_path
from rest_framework_simplejwt.views import (
TokenRefreshView,
TokenVerifyView,
)
from apps.account.views.auth_views import (
CustomTokenObtainPairView,
RegisterView,
UserMeView,
VerificationDocumentListView,
PasswordRecoverView,
PasswordResetView,
)
urlpatterns = [
# SimpleJWT Token Lifecycle
re_path(r'^token/?$', CustomTokenObtainPairView.as_view(), name='auth_token_obtain_pair'),
re_path(r'^token/refresh/?$', TokenRefreshView.as_view(), name='auth_token_refresh'),
re_path(r'^token/verify/?$', TokenVerifyView.as_view(), name='auth_token_verify'),
# Registration & Profile
re_path(r'^register/?$', RegisterView.as_view(), name='auth_register'),
re_path(r'^me/?$', UserMeView.as_view(), name='auth_me'),
# Verification Documents
re_path(r'^documents/?$', VerificationDocumentListView.as_view(), name='auth_documents'),
# Password Recovery
re_path(r'^recover-password/?$', PasswordRecoverView.as_view(), name='auth_recover_password'),
re_path(r'^reset-password/?$', PasswordResetView.as_view(), name='auth_reset_password'),
]