21 lines
509 B
Python
21 lines
509 B
Python
"""
|
|
API v1 URL configuration.
|
|
|
|
All API endpoints are versioned under /api/v1/
|
|
"""
|
|
|
|
from apps.core.views import BackgroundJobListView, BackgroundJobStatusView
|
|
from django.urls import include, path
|
|
|
|
app_name = "api_v1"
|
|
|
|
jobs_urlpatterns = [
|
|
path("", BackgroundJobListView.as_view(), name="job-list"),
|
|
path("<str:task_id>/", BackgroundJobStatusView.as_view(), name="job-status"),
|
|
]
|
|
|
|
urlpatterns = [
|
|
path("users/", include("apps.user.urls")),
|
|
path("jobs/", include((jobs_urlpatterns, "jobs"))),
|
|
]
|