Files
danyang-match/docs/api/API_INVENTORY.md
T

175 lines
5.2 KiB
Markdown
Raw Normal View History

2026-09-09 22:05:00 +08:00
# API 接口清单
## 用户端 /api/v1/
### 认证
| Method | Path | 描述 |
|---|---|---|
| POST | /auth/wechat/login | 微信登录 |
| POST | /auth/phone/bind | 绑定手机号 |
| POST | /auth/refresh | 刷新 Token |
| POST | /auth/logout | 登出 |
| GET | /me/status | 获取当前用户状态 |
### 用户资料
| Method | Path | 描述 |
|---|---|---|
| GET | /me/profile | 获取本人资料 |
| PUT | /me/profile | 更新本人资料 |
| GET | /me/preferences | 获取择偶条件 |
| PUT | /me/preferences | 更新择偶条件 |
| GET | /me/photos | 获取照片列表 |
| POST | /me/photos/upload-token | 获取上传凭证 |
| GET | /me/privacy-settings | 获取隐私设置 |
| PUT | /me/privacy-settings | 更新隐私设置 |
| GET | /me/review-status | 获取审核状态 |
### 实名认证
| Method | Path | 描述 |
|---|---|---|
| POST | /verification/submit | 提交实名认证 |
| GET | /verification/status | 查询认证状态 |
### 推荐
| Method | Path | 描述 |
|---|---|---|
| GET | /recommendations | 获取今日推荐 |
| GET | /recommendations/{id} | 获取推荐详情 |
### 搜索
| Method | Path | 描述 |
|---|---|---|
| GET | /discover | 搜索用户 |
| GET | /users/{id} | 查看用户详情 |
### 关系
| Method | Path | 描述 |
|---|---|---|
| POST | /relations/{userId}/like | 表达喜欢 |
| DELETE | /relations/{userId}/like | 取消喜欢 |
| POST | /relations/{userId}/pass | 表示不合适 |
| POST | /relations/{userId}/block | 拉黑用户 |
| DELETE | /relations/{userId}/block | 解除拉黑 |
| GET | /relations/mutual | 获取互相喜欢列表 |
| GET | /relations/liked | 获取喜欢的列表 |
| GET | /relations/likers | 获取喜欢我的人 |
### 匹配
| Method | Path | 描述 |
|---|---|---|
| GET | /matches | 获取我的匹配列表 |
| POST | /matches/{id}/unmatch | 解除匹配 |
| POST | /matches/{id}/success/request | 发起成功牵手请求 |
| POST | /matches/{id}/success/confirm | 确认成功牵手 |
### 关系状态
| Method | Path | 描述 |
|---|---|---|
| PUT | /me/relationship/pause | 暂停寻找 |
| PUT | /me/relationship/resume | 恢复寻找 |
| PUT | /me/relationship/getting-to-know | 设置为正在了解 |
### 聊天
| Method | Path | 描述 |
|---|---|---|
| GET | /conversations | 获取会话列表 |
| GET | /conversations/{id} | 获取会话详情 |
| POST | /conversations/{id}/messages | 发送消息 |
| GET | /conversations/{id}/messages | 获取消息历史 |
| GET | /conversations/{id}/unread | 获取未读数 |
### 通知
| Method | Path | 描述 |
|---|---|---|
| GET | /notifications | 获取通知列表 |
| PUT | /notifications/{id}/read | 标记已读 |
| PUT | /notifications/read-all | 全部已读 |
| GET | /notifications/unread-count | 未读数 |
### 活动
| Method | Path | 描述 |
|---|---|---|
| GET | /activities | 活动列表 |
| GET | /activities/{id} | 活动详情 |
| POST | /activities/{id}/register | 报名活动 |
| GET | /my-activities | 我的活动 |
| POST | /activities/{id}/feedback | 提交活动反馈 |
| POST | /activities/{id}/interests | 提交活动互选 |
### 红娘
| Method | Path | 描述 |
|---|---|---|
| POST | /matchmaker/services | 申请红娘服务 |
| GET | /matchmaker/services | 我的服务列表 |
| GET | /matchmaker/services/{id} | 服务详情 |
| GET | /matchmaker/recommendations | 红娘推荐列表 |
### 举报
| Method | Path | 描述 |
|---|---|---|
| POST | /reports | 提交举报 |
| GET | /my-reports | 我的举报 |
---
## 后台 /api/v1/operator/
### 审核
| Method | Path | 描述 |
|---|---|---|
| GET | /reviews/pending | 待审核列表 |
| POST | /reviews/{id}/claim | 领取审核任务 |
| POST | /reviews/{id}/approve | 审核通过 |
| POST | /reviews/{id}/need-edit | 需修改 |
| POST | /reviews/{id}/reject | 拒绝 |
### 用户管理
| Method | Path | 描述 |
|---|---|---|
| GET | /users | 用户列表 |
| GET | /users/{id} | 用户详情 |
| GET | /users/{id}/sensitive-identity | 查看敏感身份(需权限)|
| PUT | /users/{id}/status | 修改用户状态 |
### 活动管理
| Method | Path | 描述 |
|---|---|---|
| GET | /activities | 活动列表 |
| POST | /activities | 创建活动 |
| PUT | /activities/{id} | 更新活动 |
| DELETE | /activities/{id} | 取消活动 |
| GET | /activities/{id}/registrations | 报名列表 |
| POST | /activities/{id}/registrations/{rid}/review | 审核报名 |
### 红娘管理
| Method | Path | 描述 |
|---|---|---|
| GET | /matchmaker/services | 服务列表 |
| POST | /matchmaker/services/{id}/assign | 分配红娘 |
| GET | /matchmaker/services/{id} | 服务详情 |
### 举报管理
| Method | Path | 描述 |
|---|---|---|
| GET | /reports | 举报列表 |
| GET | /reports/{id} | 举报详情 |
| POST | /reports/{id}/process | 处理举报 |
### 权限管理
| Method | Path | 描述 |
|---|---|---|
| GET | /operators | 操作员列表 |
| POST | /operators | 创建操作员 |
| PUT | /operators/{id} | 更新操作员 |
| GET | /roles | 角色列表 |
| POST | /roles | 创建角色 |
| GET | /permissions | 权限列表 |
### 统计
| Method | Path | 描述 |
|---|---|---|
| GET | /analytics/dashboard | 工作台数据 |
| GET | /analytics/users | 用户统计 |
| GET | /analytics/matches | 匹配统计 |
| GET | /analytics/activities | 活动统计 |