aboutsummaryrefslogtreecommitdiff
path: root/api/schemas/auth_schemas.py
diff options
context:
space:
mode:
authorParker <contact@pkrm.dev>2024-11-04 00:12:36 -0600
committerParker <contact@pkrm.dev>2024-11-04 00:12:36 -0600
commit8ae8c5c454ba42e8f56f415d33bbaaac7d1a37ec (patch)
treed56704d87f63b79681530ab729d9f54d24f73c80 /api/schemas/auth_schemas.py
parent65fef6274166678f59d6d81c9da68465a7c374bc (diff)
Remove API Keys -> Authenticate with JWT
Diffstat (limited to 'api/schemas/auth_schemas.py')
-rw-r--r--api/schemas/auth_schemas.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/api/schemas/auth_schemas.py b/api/schemas/auth_schemas.py
new file mode 100644
index 0000000..d5b9a88
--- /dev/null
+++ b/api/schemas/auth_schemas.py
@@ -0,0 +1,19 @@
+from pydantic import BaseModel
+
+
+class Token(BaseModel):
+ access_token: str
+ token_type: str
+
+
+class TokenData(BaseModel):
+ username: str | None = None
+
+
+class User(BaseModel):
+ username: str
+ id: int
+
+
+class UserInDB(User):
+ hashed_password: str