20 lines
382 B
Python
20 lines
382 B
Python
from pydantic import BaseModel, Field
|
|
|
|
|
|
class CreateUploadTokenRequest(BaseModel):
|
|
biz_type: str
|
|
biz_id: int = Field(gt=0)
|
|
file_name: str
|
|
file_type: str
|
|
file_size: int = Field(gt=0)
|
|
|
|
|
|
class SaveAttachmentRequest(BaseModel):
|
|
biz_type: str
|
|
biz_id: int = Field(gt=0)
|
|
file_name: str
|
|
file_url: str
|
|
file_type: str
|
|
file_size: int = Field(gt=0)
|
|
|