summaryrefslogtreecommitdiff
path: root/venv/lib/python3.11/site-packages/litestar/openapi/spec/paths.py
blob: 682664ebf88e2d49df2c4c020d6ba7cf1f03dd2d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
from __future__ import annotations

from typing import TYPE_CHECKING, Dict

if TYPE_CHECKING:
    from litestar.openapi.spec import PathItem

Paths = Dict[str, "PathItem"]
"""Holds the relative paths to the individual endpoints and their operations. The path is appended to the URL from the.

`Server Object <https://spec.openapis.org/oas/v3.1.0#serverObject>`_ in order to construct the full URL.

The Paths MAY be empty, due to
`Access Control List (ACL) constraints <https://spec.openapis.org/oas/v3.1.0#securityFiltering>`_.

Patterned Fields

/{path}: PathItem

A relative path to an individual endpoint. The field name MUST begin with a forward slash (``/``). The path is
**appended** (no relative URL resolution) to the expanded URL from the
`Server Object <https://spec.openapis.org/oas/v3.1.0#serverObject>`_ 's ``url`` field in order to construct the full
URL. `Path templating <https://spec.openapis.org/oas/v3.1.0#pathTemplating>`_ is allowed. When matching URLs, concrete
(non-templated) paths would be matched before their templated counterparts. Templated paths with the same hierarchy but
different templated names MUST NOT exist as they are identical. In case of ambiguous matching, it's up to the tooling to
decide which one to use.
"""