Demo
This commit is contained in:
0
app/schemas/__init__.py
Normal file
0
app/schemas/__init__.py
Normal file
5
app/schemas/token.py
Normal file
5
app/schemas/token.py
Normal file
@@ -0,0 +1,5 @@
|
||||
from pydantic import BaseModel
|
||||
|
||||
class TokenInfo(BaseModel):
|
||||
access_token: str
|
||||
token_type: str
|
||||
10
app/schemas/user.py
Normal file
10
app/schemas/user.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from pydantic import BaseModel, EmailStr, ConfigDict
|
||||
|
||||
|
||||
class UserSchema(BaseModel):
|
||||
model_config = ConfigDict(strict=True)
|
||||
|
||||
username: str
|
||||
password: bytes
|
||||
email: EmailStr | None = None
|
||||
active: bool = True
|
||||
Reference in New Issue
Block a user