class User(BaseModel):
id: int
name: str
email: Optinal[str]
age: int
place1: str
place2: str
This is my model class and here place1 and place2 are two fields i need compulsorily one field but either place1 or place2. so if i have get place1 then no need place2 and vice versa how to validate this.
thanks for all inputs.