urls.py
570 Bytes
from django.urls import path, include
from . import views
from rest_framework.authtoken.views import obtain_auth_token
from rest_framework import routers
router = routers.DefaultRouter()
router.register(r'users', views.UserViewSet)
router.register(r'sequences', views.SequenceViewSet)
urlpatterns = [
path('', include(router.urls)),
path('hello/', views.Users.as_view(), name='hello'),
path('api-token-auth/', obtain_auth_token, name='api_token_auth'),
path("submit_sequence",views.submit_sequence_with_json, name="api_submit_sequence"),
] + router.urls