aboutsummaryrefslogtreecommitdiffstats
path: root/python/fatcat_web/types.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/fatcat_web/types.py')
-rw-r--r--python/fatcat_web/types.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/python/fatcat_web/types.py b/python/fatcat_web/types.py
new file mode 100644
index 00000000..f5182d71
--- /dev/null
+++ b/python/fatcat_web/types.py
@@ -0,0 +1,14 @@
+from typing import Any, Tuple, Union
+
+from flask import Response as FlaskResponse
+from werkzeug.wrappers import Response as WerkzeugResponse
+
+# type to represent any of the used/plausible return types
+AnyResponse = Union[
+ FlaskResponse,
+ str,
+ Tuple[str, int],
+ WerkzeugResponse,
+ Tuple[FlaskResponse, int],
+ Tuple[WerkzeugResponse, int],
+]