mirror of
https://github.com/cnlimiter/codex-register.git
synced 2026-05-13 17:29:43 +08:00
refactor(registration): 调整响应模型顺序以提升代码可读性
This commit is contained in:
@@ -82,13 +82,6 @@ class BatchRegistrationRequest(BaseModel):
|
||||
interval_max: int = 30 # 最大间隔秒数
|
||||
|
||||
|
||||
class BatchRegistrationResponse(BaseModel):
|
||||
"""批量注册响应"""
|
||||
batch_id: str
|
||||
count: int
|
||||
tasks: List[RegistrationTaskResponse]
|
||||
|
||||
|
||||
class RegistrationTaskResponse(BaseModel):
|
||||
"""注册任务响应"""
|
||||
id: int
|
||||
@@ -107,6 +100,13 @@ class RegistrationTaskResponse(BaseModel):
|
||||
from_attributes = True
|
||||
|
||||
|
||||
class BatchRegistrationResponse(BaseModel):
|
||||
"""批量注册响应"""
|
||||
batch_id: str
|
||||
count: int
|
||||
tasks: List[RegistrationTaskResponse]
|
||||
|
||||
|
||||
class TaskListResponse(BaseModel):
|
||||
"""任务列表响应"""
|
||||
total: int
|
||||
|
||||
Reference in New Issue
Block a user