from rest_framework import permissions
from drf_yasg.views import get_schema_view
from drf_yasg import openapi
from rest_framework.permissions import AllowAny


from django.urls import re_path
from django.contrib import admin
from django.urls import path
 
from .views import userView 
from .views import spaceView 
from .views import AssetBundle 
from .views import teamView 
from .views import meetingView 
from django.urls import include, path
from django.conf import settings
from django.conf.urls.static import static




schema_view = get_schema_view(
    openapi.Info(
        title="Your API Title",
        default_version='v1',
        description="API documentation",
    ),
    public=True,
    permission_classes=(AllowAny,),
    authentication_classes=[],  # Leave this empty here
)




urlpatterns = [


    

    path('admin/', admin.site.urls),


    # Swagger
 
    path('redoc/', schema_view.with_ui('redoc', cache_timeout=0), name='schema-redoc'),
    path('swagger/', schema_view.with_ui('swagger', cache_timeout=0), name='schema-swagger-ui'),


    # re_path(r'^signup/$', userView.signup, name="signup"),
 
    re_path('signup', userView.signup , name="signup"),
    re_path('login', userView.login),
    re_path('test_token', userView.test_token),

    re_path('editProfile/', userView.editProfile, name='edit-profile'),
    re_path('resetPassword/', userView.resetPassword, name='reset-password'),


    re_path('getInfo', userView.getInfo),

    re_path('sendSmsVerification', userView.sendSmsVerification),
    re_path('sendEmailVerification', userView.sendEmailVerification),
    re_path('submitEmailVerification', userView.submitEmailVerification),
    re_path('submitSmsVerification', userView.submitSmsVerification),


    re_path('sendForgetPasswordCode', userView.sendForgetPasswordCode),
    re_path('sendCodeAndNewPassword', userView.sendCodeAndNewPassword),
 
    re_path('requestResetCode', userView.requestResetCode),
    re_path('verifyResetCode', userView.verifyResetCode),


    

    re_path('uploadImage/', userView.upload_image , name='upload_image'),
    re_path('uploadGlb/', userView.upload_glb , name='upload_glb'),
    re_path('uploadVideo/', userView.upload_video , name='upload_video'),
    re_path('uploadPdf/', userView.upload_pdf , name='upload_pdf'),
    
    re_path('add_subscription', userView.addSubscription),
    re_path('add_teamMember', userView.addTeamMember),
    re_path('get_team_member_info', userView.get_team_member_info),
    re_path('add_space', spaceView.addSpace),

    re_path('get_space', spaceView.getSpaces),
    re_path('get_assigned_assetbundle_rooms', AssetBundle.getAssignedAssetBundleRooms , name='get_assigned_assetbundle_rooms'),
   


    re_path('add_team', teamView.addTeam),
    re_path('get_team', teamView.getTeams),
    re_path('get_all_team_members', teamView.get_all_team_members),

    path('add_meeting', meetingView. addMeeting, name='add_meeting'),

   
]+ static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)


 