31 lines
1.4 KiB
Python
31 lines
1.4 KiB
Python
from django.urls import path
|
|
|
|
from api.main.views import FAQView, NewsView, TelegramMessageView
|
|
|
|
from api.auth.views import (
|
|
RegisterViewSet,
|
|
LoginViewSet,
|
|
LogoutView,
|
|
RefreshTokenView)
|
|
|
|
from api.account.client.views import UserDataView, AccountActionsView, CityView, CountryView
|
|
|
|
urlpatterns = [
|
|
path("v1/faq/", FAQView.as_view(), name='faqMain'),
|
|
path("v1/news/", NewsView.as_view(), name="newsmain"),
|
|
path("v1/send-message", TelegramMessageView.as_view(), name='send_message'),
|
|
|
|
path("auth/refresh/", RefreshTokenView.as_view(), name="token-refresh"),
|
|
path("register/clients/", RegisterViewSet.as_view({'post': 'register_client'}), name="register-client"),
|
|
path("auth/login/clients/", LoginViewSet.as_view({'post': 'login_client'}), name="login-client"),
|
|
path("v1/logout", LogoutView.as_view(), name="logout"),
|
|
|
|
path ("v1/user/", UserDataView.as_view({'get': 'user_data'}), name="user"),
|
|
|
|
path("v1/account/change_main_data/", AccountActionsView.as_view({'patch':'change_data_main_tab'}), name='change_data_main_tab'),
|
|
path("v1/account/routes/", AccountActionsView.as_view({'get':'user_routes'}), name='user_routes'),
|
|
path("v1/account/create_route/", AccountActionsView.as_view({'post':'create_route'}), name='create_route'),
|
|
|
|
path("v1/cities/", CityView.as_view({'get':'get_cities'}), name='get_cities'),
|
|
path("v1/countries/", CountryView.as_view({'get':'get_countries'}), name='get_countries')
|
|
] |