File size: 1,051 Bytes
bf2bf0e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
from typing import Optional

from pydantic import BaseModel, Field


class UpdatePromptsRequest(BaseModel):
    prompts: dict = Field(..., description="Prompts")


class RefreshRequest(BaseModel):
    refresh_token: str = Field(..., description="Refresh token")


class UserExistsRequest(BaseModel):
    email: Optional[str] = Field(None, description="email")
    phone: Optional[str] = Field(None, description="phone")


class LoginRequest(BaseModel):
    email: str = Field(..., description="Email address")
    password: str = Field(..., description="Password")


class LoginPasswordlessRequest(BaseModel):
    phone: str = Field(..., description="Phone number")


class VerifyPasswordlessRequest(BaseModel):
    phone: str = Field(..., description="Phone number")
    token: str = Field(..., description="otp")


class RegisterRequest(BaseModel):
    first_name: str
    last_name: str
    email: str
    phone: str
    # password_hash: str
    uuid: Optional[str] = Field(None, description="uuid")


class VerifyRequest(BaseModel):
    uuid: str