# This file defines the URL patterns for the customs app in a Django project. from django.urls import path, include from rest_framework.routers import DefaultRouter # import necessary viewsets # from .views import YourViewSet # Import your viewsets here from .views import (DocumentViewSet , ProtectedDocumentDownloadView , BulkDownloadZipView , GetFuenteView , DocumentTypeView , ExpedienteZipDownloadView , MultiPedimentoZipDownloadView , PedimentoDocumentViewSet , TriggerPedimentoCompletoView) # Create a router and register your viewsets with it router = DefaultRouter() # Register your viewsets with the router he -fre # Example: # from .views import MyViewSet # router.register(r'myviewset', MyViewSet, basename='myviewset') router.register(r'documents', DocumentViewSet, basename='Document') # No registres ProtectedDocumentDownloadView en el router, solo como path individual urlpatterns = [ path('documents/bulk-download/', BulkDownloadZipView.as_view(), name='bulk-download-documents'), path('documents/descargar//', ProtectedDocumentDownloadView.as_view(), name='descargar-documento'), path('fuente/', GetFuenteView.as_view(), name='get-fuente'), path('document-type/', DocumentTypeView.as_view(), name='document-type-list-create'), path('documents/expediente-zip/', ExpedienteZipDownloadView.as_view(), name='expediente-zip-download'), path('documents/multi-pedimento-zip/', MultiPedimentoZipDownloadView.as_view(), name='multi-pedimento-zip-download'), path('pedimento-documents/', PedimentoDocumentViewSet.as_view({'get': 'list'}), name='pedimento-document-list'), path('microservice/pedimento-completo/', TriggerPedimentoCompletoView.as_view(), name='trigger-pedimento-completo'), path('', include(router.urls)), ]