After #414 and #457 we still have some API responses missing in the generated api-paths.ts.
The POST /api/projects is an example this.
|
@router.post("/") |
|
async def create_project(req: ProjectCreateRequest): |
|
""" |
|
Creates a project, and a directory in the filesystem |
|
""" |
|
user_id = "user1" |
|
project_id = str(uuid4()) |
|
project_path = service.create_project( |
|
user_id, project_id, req.project_name, req.project_path |
|
) |
|
return { |
|
project_id: { |
|
"project_name": req.project_name, |
|
"project_path": project_path, |
|
} |
|
} |
|
create_project_api_projects__post: { |
|
requestBody: { |
|
content: { |
|
'application/json': ProjectCreateRequest; |
|
}; |
|
}; |
|
responses: { |
|
/** @description Successful Response */ |
|
200: { |
|
content: { |
|
'application/json': unknown; |
|
}; |
|
}; |
|
/** @description Validation Error */ |
|
422: { |
|
content: { |
|
'application/json': HTTPValidationError; |
|
}; |
|
}; |
|
}; |
|
}; |
After #414 and #457 we still have some API responses missing in the generated
api-paths.ts.The
POST /api/projectsis an example this.refstudio/python/sidecar/projects/router.py
Lines 27 to 42 in 28e9047
refstudio/src/api/api-paths.ts
Lines 602 to 622 in 28e9047