seller_central_backend/api/urls.py
vickytechkey 010dc0352e
All checks were successful
Build and Deploy Beta / build-and-push (push) Successful in 1m31s
Build and Deploy Beta / deploy (push) Successful in 12s
adding api urls and testing framework
2026-08-09 11:42:43 +05:30

23 lines
1,018 B
Python

from django.urls import path, include
from rest_framework.routers import DefaultRouter
from .views import (
RegisterView, LoginView, VerifyOtpView, ProfileView,
ProductViewSet, BulkUploadView, OrderViewSet, ReturnRequestViewSet,
WalletView, WithdrawView
)
router = DefaultRouter()
router.register(r'products', ProductViewSet, basename='product')
router.register(r'orders', OrderViewSet, basename='order')
router.register(r'returns', ReturnRequestViewSet, basename='return')
urlpatterns = [
path('auth/register/', RegisterView.as_view(), name='register'),
path('auth/login/', LoginView.as_view(), name='login'),
path('auth/verify-otp/', VerifyOtpView.as_view(), name='verify-otp'),
path('profile/', ProfileView.as_view(), name='profile'),
path('products/bulk-upload/', BulkUploadView.as_view(), name='bulk-upload'),
path('wallet/', WalletView.as_view(), name='wallet'),
path('wallet/withdraw/', WithdrawView.as_view(), name='withdraw'),
path('', include(router.urls)),
]