summaryrefslogtreecommitdiff
path: root/venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py
diff options
context:
space:
mode:
Diffstat (limited to 'venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py')
-rw-r--r--venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py b/venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py
new file mode 100644
index 0000000..920d095
--- /dev/null
+++ b/venv/lib/python3.11/site-packages/litestar/openapi/spec/oauth_flows.py
@@ -0,0 +1,28 @@
+from __future__ import annotations
+
+from dataclasses import dataclass
+from typing import TYPE_CHECKING
+
+from litestar.openapi.spec.base import BaseSchemaObject
+
+if TYPE_CHECKING:
+ from litestar.openapi.spec.oauth_flow import OAuthFlow
+
+__all__ = ("OAuthFlows",)
+
+
+@dataclass
+class OAuthFlows(BaseSchemaObject):
+ """Allows configuration of the supported OAuth Flows."""
+
+ implicit: OAuthFlow | None = None
+ """Configuration for the OAuth Implicit flow."""
+
+ password: OAuthFlow | None = None
+ """Configuration for the OAuth Resource Owner Password flow."""
+
+ client_credentials: OAuthFlow | None = None
+ """Configuration for the OAuth Client Credentials flow. Previously called ``application`` in OpenAPI 2.0."""
+
+ authorization_code: OAuthFlow | None = None
+ """Configuration for the OAuth Authorization Code flow. Previously called ``accessCode`` in OpenAPI 2.0."""