# Path: knox_project/views.py
# class RootView(APIView):
#     authentication_classes = (TokenAuthentication,)
#     permission_classes = (IsAuthenticated,)
# 
#     def get(self, request):
#         return Response("api root")


from django.urls import include, re_path
from .views import RootView


urlpatterns = [
    re_path(r'^api/', include('knox.urls')),
    re_path(r'^api/$', RootView.as_view(), name="api-root"),

# Path: knox_project/views.py
# class RootView(APIView):
#     authentication_classes = (TokenAuthentication,)
#     permission_classes = (IsAuthenticated,)
# 
#     def get(self, request):
#         return Response("api root")


# Path: knox_project/urls.py
from django.urls import include, re_path
from .views import RootView



urlpatterns = [
    re_path(r'^api/', include('knox.urls')),
    re_path(r'^api/$', RootView.as_view(), name="api-root"),

]