2024-04-25 10:56:22 +00:00
|
|
|
__package__ = 'archivebox.api'
|
|
|
|
|
|
|
|
from django.urls import path
|
|
|
|
from django.views.generic.base import RedirectView
|
|
|
|
|
2024-04-25 12:49:37 +00:00
|
|
|
from .v1_api import urls as v1_api_urls
|
2024-04-25 10:56:22 +00:00
|
|
|
|
|
|
|
urlpatterns = [
|
2024-04-25 12:49:37 +00:00
|
|
|
path("", RedirectView.as_view(url='/api/v1')),
|
2024-04-25 10:56:22 +00:00
|
|
|
|
2024-04-25 12:49:37 +00:00
|
|
|
path("v1/", v1_api_urls),
|
2024-04-25 10:56:22 +00:00
|
|
|
path("v1", RedirectView.as_view(url='/api/v1/docs')),
|
2024-04-25 12:49:37 +00:00
|
|
|
|
|
|
|
# ... v2 can be added here ...
|
|
|
|
# path("v2/", v2_api_urls),
|
|
|
|
# path("v2", RedirectView.as_view(url='/api/v2/docs')),
|
2024-04-25 10:56:22 +00:00
|
|
|
]
|