chore: initialize application scaffold
This commit is contained in:
+25
@@ -0,0 +1,25 @@
|
||||
# 接口文档
|
||||
|
||||
服务根路径:`/api/v1`
|
||||
|
||||
## 用户资源
|
||||
|
||||
### 获取用户列表
|
||||
|
||||
- 请求:`GET /api/v1/users`
|
||||
- 响应:`200 OK`
|
||||
|
||||
```json
|
||||
[{"id":"uuid","name":"示例用户","email":"demo@example.com","createdAt":"2026-08-23T00:00:00.000Z","updatedAt":"2026-08-23T00:00:00.000Z"}]
|
||||
```
|
||||
|
||||
### 创建用户
|
||||
|
||||
- 请求:`POST /api/v1/users`
|
||||
- 请求体:`name` 为 1 至 50 个字符,`email` 必须为邮箱格式。
|
||||
- 响应:`201 Created`
|
||||
- 冲突:邮箱已经存在时返回 `409 Conflict`。
|
||||
|
||||
```json
|
||||
{"name":"示例用户","email":"demo@example.com"}
|
||||
```
|
||||
Reference in New Issue
Block a user