Coverage for crateweb/anonymise_api/urls.py: 100%
4 statements
« prev ^ index » next coverage.py v7.8.0, created at 2026-01-06 10:22 -0600
« prev ^ index » next coverage.py v7.8.0, created at 2026-01-06 10:22 -0600
1"""
2crate_anon/crateweb/anonymise_api/anonymiser/urls.py
4===============================================================================
6 Copyright (C) 2015, University of Cambridge, Department of Psychiatry.
7 Created by Rudolf Cardinal (rnc1001@cam.ac.uk).
9 This file is part of CRATE.
11 CRATE is free software: you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
16 CRATE is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with CRATE. If not, see <https://www.gnu.org/licenses/>.
24===============================================================================
26**Django URL configuration for CRATE anonymisation API.**
28"""
30from django.urls import path, re_path
32from drf_spectacular.views import (
33 SpectacularAPIView,
34 SpectacularRedocView,
35)
37from crate_anon.crateweb.anonymise_api.views import HomeView, ScrubView
39urlpatterns = [
40 re_path("^$", HomeView.as_view(), name="anon_api_home"),
41 path("scrub/", ScrubView.as_view(), name="anon_api"),
42 path("schema/", SpectacularAPIView.as_view(), name="anon_api_schema"),
43 path(
44 "schema/doc/",
45 SpectacularRedocView.as_view(url_name="anon_api_schema"),
46 name="anon_api_doc",
47 ),
48]