25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

urls.py 723 B

12345678910111213141516171819202122
  1. import rest_framework_simplejwt.views
  2. import djoser.views
  3. from django.urls import include, path
  4. from rest_framework.routers import DefaultRouter
  5. from api import views
  6. router = DefaultRouter()
  7. router.register(r"passwords", views.PasswordViewSet, basename="passwords")
  8. router.register(
  9. r"encrypted_password_profiles",
  10. views.EncryptedPasswordProfileViewSet,
  11. basename="encrypted_password_profiles",
  12. )
  13. router.register(r"auth/register", djoser.views.UserViewSet, basename="auth_register")
  14. urlpatterns = [
  15. path("", include(router.urls)),
  16. path("tokens/auth/", views.BackwardCompatibleTokenObtainPairView.as_view()),
  17. path("auth/", include("djoser.urls")),
  18. path("auth/", include("djoser.urls.jwt")),
  19. ]