Changeset View
Changeset View
Standalone View
Standalone View
swh/web/api/apiurls.py
# Copyright (C) 2017-2019 The Software Heritage developers | # Copyright (C) 2017-2019 The Software Heritage developers | ||||
# See the AUTHORS file at the top-level directory of this distribution | # See the AUTHORS file at the top-level directory of this distribution | ||||
# License: GNU Affero General Public License version 3, or any later version | # License: GNU Affero General Public License version 3, or any later version | ||||
# See top-level LICENSE file for more information | # See top-level LICENSE file for more information | ||||
import functools | import functools | ||||
from typing import Dict | from typing import Dict | ||||
from rest_framework.decorators import api_view | from rest_framework.decorators import api_view | ||||
from swh.web.common.urlsindex import UrlsIndex | from swh.web.common.urlsindex import UrlsIndex | ||||
from swh.web.common import throttling | from swh.web.api import throttling | ||||
class APIUrls(UrlsIndex): | class APIUrls(UrlsIndex): | ||||
""" | """ | ||||
Class to manage API documentation URLs. | Class to manage API documentation URLs. | ||||
- Indexes all routes documented using apidoc's decorators. | - Indexes all routes documented using apidoc's decorators. | ||||
- Tracks endpoint/request processing method relationships for use in | - Tracks endpoint/request processing method relationships for use in | ||||
▲ Show 20 Lines • Show All 70 Lines • Show Last 20 Lines |