"""app URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/4.0/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-based views 1. Add an import: from other_app.views import Home 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') Including another URLconf 1. Import the include() function: from django.urls import include, path 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) """ from django.conf import settings from django.conf.urls.static import static from django.contrib import admin from django.contrib.auth.views import LogoutView from django.urls import include, path from two_factor.urls import urlpatterns as tf_urls from core.views import ( ais, base, compose, groups, identifiers, instagram, manipulations, messages, notifications, osint, people, personas, queues, sessions, signal, whatsapp, workspace, ) urlpatterns = [ path("__debug__/", include("debug_toolbar.urls")), path("", base.Home.as_view(), name="home"), path("admin/", admin.site.urls), # 2FA login urls path("", include(tf_urls)), path("accounts/signup/", base.Signup.as_view(), name="signup"), path("accounts/logout/", LogoutView.as_view(), name="logout"), # Notifications path( "notifications//update/", notifications.NotificationsUpdate.as_view(), name="notifications_update", ), path( "services/signal/", signal.Signal.as_view(), name="signal", ), path( "services/whatsapp/", whatsapp.WhatsApp.as_view(), name="whatsapp", ), path( "services/instagram/", instagram.Instagram.as_view(), name="instagram", ), path( "services/signal//", signal.SignalAccounts.as_view(), name="signal_accounts", ), path( "services/whatsapp//", whatsapp.WhatsAppAccounts.as_view(), name="whatsapp_accounts", ), path( "services/instagram//", instagram.InstagramAccounts.as_view(), name="instagram_accounts", ), path( "services/signal//contacts//", signal.SignalContactsList.as_view(), name="signal_contacts", ), path( "services/signal//chats//", signal.SignalChatsList.as_view(), name="signal_chats", ), path( "services/signal//messages///", signal.SignalMessagesList.as_view(), name="signal_messages", ), path( "services/signal//add/", signal.SignalAccountAdd.as_view(), name="signal_account_add", ), path( "services/whatsapp//add/", whatsapp.WhatsAppAccountAdd.as_view(), name="whatsapp_account_add", ), path( "services/instagram//add/", instagram.InstagramAccountAdd.as_view(), name="instagram_account_add", ), path( "compose/page/", compose.ComposePage.as_view(), name="compose_page", ), path( "compose/workspace/", compose.ComposeWorkspace.as_view(), name="compose_workspace", ), path( "compose/widget/", compose.ComposeWidget.as_view(), name="compose_widget", ), path( "compose/workspace/widget/contacts/", compose.ComposeWorkspaceContactsWidget.as_view(), name="compose_workspace_contacts_widget", ), path( "compose/send/", compose.ComposeSend.as_view(), name="compose_send", ), path( "compose/drafts/", compose.ComposeDrafts.as_view(), name="compose_drafts", ), path( "compose/summary/", compose.ComposeSummary.as_view(), name="compose_summary", ), path( "compose/quick-insights/", compose.ComposeQuickInsights.as_view(), name="compose_quick_insights", ), path( "compose/engage/preview/", compose.ComposeEngagePreview.as_view(), name="compose_engage_preview", ), path( "compose/engage/send/", compose.ComposeEngageSend.as_view(), name="compose_engage_send", ), path( "compose/thread/", compose.ComposeThread.as_view(), name="compose_thread", ), path( "compose/widget/contacts/", compose.ComposeContactsDropdown.as_view(), name="compose_contacts_dropdown", ), # AIs path( "ai/workspace/", workspace.AIWorkspace.as_view(), name="ai_workspace", ), path( "ai/workspace//contacts/", workspace.AIWorkspaceContactsWidget.as_view(), name="ai_workspace_contacts", ), path( "ai/workspace//person//", workspace.AIWorkspacePersonWidget.as_view(), name="ai_workspace_person", ), path( "ai/workspace//person//timeline/", workspace.AIWorkspacePersonTimelineWidget.as_view(), name="ai_workspace_person_timeline", ), path( "ai/workspace//person//insights/graphs/", workspace.AIWorkspaceInsightGraphs.as_view(), name="ai_workspace_insight_graphs", ), path( "ai/workspace//person//information/", workspace.AIWorkspaceInformation.as_view(), name="ai_workspace_information", ), path( "ai/workspace//person//insights/help/", workspace.AIWorkspaceInsightHelp.as_view(), name="ai_workspace_insight_help", ), path( "ai/workspace//person//insights//", workspace.AIWorkspaceInsightDetail.as_view(), name="ai_workspace_insight_detail", ), path( "ai/workspace//person//run//", workspace.AIWorkspaceRunOperation.as_view(), name="ai_workspace_run", ), path( "ai/workspace//person//send/", workspace.AIWorkspaceSendDraft.as_view(), name="ai_workspace_send", ), path( "ai/workspace//person//queue/", workspace.AIWorkspaceQueueDraft.as_view(), name="ai_workspace_queue", ), path( "ai/workspace//person//mitigation/create/", workspace.AIWorkspaceCreateMitigation.as_view(), name="ai_workspace_mitigation_create", ), path( "ai/workspace//person//mitigation/" "/chat/", workspace.AIWorkspaceMitigationChat.as_view(), name="ai_workspace_mitigation_chat", ), path( "ai/workspace//person//mitigation/" "/export/", workspace.AIWorkspaceExportArtifact.as_view(), name="ai_workspace_mitigation_export", ), path( "ai/workspace//person//mitigation/" "/artifact/create//", workspace.AIWorkspaceCreateArtifact.as_view(), name="ai_workspace_mitigation_artifact_create", ), path( "ai/workspace//person//mitigation/" "/artifact///save/", workspace.AIWorkspaceUpdateArtifact.as_view(), name="ai_workspace_mitigation_artifact_save", ), path( "ai/workspace//person//mitigation/" "/artifact///delete/", workspace.AIWorkspaceDeleteArtifact.as_view(), name="ai_workspace_mitigation_artifact_delete", ), path( "ai/workspace//person//mitigation/" "/artifact//delete-all/", workspace.AIWorkspaceDeleteArtifactList.as_view(), name="ai_workspace_mitigation_artifact_delete_all", ), path( "ai/workspace//person//mitigation/" "/engage/share/", workspace.AIWorkspaceEngageShare.as_view(), name="ai_workspace_mitigation_engage_share", ), path( "ai/workspace//person//mitigation/" "/auto/", workspace.AIWorkspaceAutoSettings.as_view(), name="ai_workspace_mitigation_auto", ), path( "ai/workspace//person//mitigation/" "/fundamentals/save/", workspace.AIWorkspaceUpdateFundamentals.as_view(), name="ai_workspace_mitigation_fundamentals_save", ), path( "ai/workspace//person//mitigation/" "/meta/save/", workspace.AIWorkspaceUpdatePlanMeta.as_view(), name="ai_workspace_mitigation_meta_save", ), path( "ai//", ais.AIList.as_view(), name="ais", ), path( "search//", osint.OSINTSearch.as_view(), name="osint_search", ), path( "ai//create/", ais.AICreate.as_view(), name="ai_create", ), path( "ai//update//", ais.AIUpdate.as_view(), name="ai_update", ), path( "ai//delete//", ais.AIDelete.as_view(), name="ai_delete", ), # People path( "person//", people.PersonList.as_view(), name="people", ), path( "person//create/", people.PersonCreate.as_view(), name="person_create", ), path( "person//update//", people.PersonUpdate.as_view(), name="person_update", ), path( "person//delete//", people.PersonDelete.as_view(), name="person_delete", ), # Groups path( "group//", groups.GroupList.as_view(), name="groups", ), path( "group//create/", groups.GroupCreate.as_view(), name="group_create", ), path( "group//update//", groups.GroupUpdate.as_view(), name="group_update", ), path( "group//delete//", groups.GroupDelete.as_view(), name="group_delete", ), # Personas path( "persona//", personas.PersonaList.as_view(), name="personas", ), path( "persona//create/", personas.PersonaCreate.as_view(), name="persona_create", ), path( "persona//update//", personas.PersonaUpdate.as_view(), name="persona_update", ), path( "persona//delete//", personas.PersonaDelete.as_view(), name="persona_delete", ), # Manipulations path( "manipulation//", manipulations.ManipulationList.as_view(), name="manipulations", ), path( "manipulation//create/", manipulations.ManipulationCreate.as_view(), name="manipulation_create", ), path( "manipulation//update//", manipulations.ManipulationUpdate.as_view(), name="manipulation_update", ), path( "manipulation//delete//", manipulations.ManipulationDelete.as_view(), name="manipulation_delete", ), # Sessions path( "session//", sessions.SessionList.as_view(), name="sessions", ), path( "session//create/", sessions.SessionCreate.as_view(), name="session_create", ), path( "session//update//", sessions.SessionUpdate.as_view(), name="session_update", ), path( "session//delete//", sessions.SessionDelete.as_view(), name="session_delete", ), # Identifiers path( "person//identifiers//", identifiers.PersonIdentifierList.as_view(), name="person_identifiers", ), path( "person//identifiers/create/", identifiers.PersonIdentifierCreate.as_view(), name="person_identifier_create", ), path( "person//identifiers/update///", identifiers.PersonIdentifierUpdate.as_view(), name="person_identifier_update", ), path( "person//identifiers/delete///", identifiers.PersonIdentifierDelete.as_view(), name="person_identifier_delete", ), # Messages path( "session//messages//", messages.MessageList.as_view(), name="messages", ), path( "session//messages/create/", messages.MessageCreate.as_view(), name="message_create", ), path( "session//messages/update///", messages.MessageUpdate.as_view(), name="message_update", ), path( "session//messages/delete///", messages.MessageDelete.as_view(), name="message_delete", ), # API # Queues path( "api/v1/queue/message/accept//", queues.AcceptMessageAPI.as_view(), name="message_accept_api", ), path( "api/v1/queue/message/reject//", queues.RejectMessageAPI.as_view(), name="message_reject_api", ), path( "queue//", queues.QueueList.as_view(), name="queues", ), path( "queue//create/", queues.QueueCreate.as_view(), name="queue_create", ), path( "queue//update//", queues.QueueUpdate.as_view(), name="queue_update", ), path( "queue//delete//", queues.QueueDelete.as_view(), name="queue_delete", ), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)