forked from openapi-generators/openapi-python-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathresponses.py
More file actions
21 lines (16 loc) · 809 Bytes
/
responses.py
File metadata and controls
21 lines (16 loc) · 809 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
from .reference import ReferenceOr
from .response import Response
Responses = dict[str, ReferenceOr[Response]]
"""
A container for the expected responses of an operation.
The container maps a HTTP response code to the expected response.
The documentation is not necessarily expected to cover all possible HTTP response codes
because they may not be known in advance.
However, documentation is expected to cover a successful operation response and any known errors.
The `default` MAY be used as a default response object for all HTTP codes
that are not covered individually by the specification.
The `Responses Object` MUST contain at least one response code, and it
SHOULD be the response for a successful operation call.
References:
- https://swagger.io/docs/specification/describing-responses/
"""