视频会议保存

This commit is contained in:
duoaohui
2026-05-18 19:42:55 +08:00
parent 315884685f
commit ac8ec4c903
41 changed files with 5069 additions and 39 deletions

View File

@@ -9,7 +9,13 @@ import (
// RegisterRoutes 注册 meeting 模块的全部前台路由
// 所有接口统一挂载在 /api/v1/meeting/* 前缀下,均需 JWT 认证
// 设计文档 §6.2 的 12 个接口 Task 4 骨架阶段仅搭路由层,业务实现留待 Task 5/6/7
func RegisterRoutes(r *gin.Engine, ctrl *controller.MeetingController, jwtAuth gin.HandlerFunc) {
// Phase B 新增录制三接口POST/DELETE/GET /rooms/:code/recordings*
func RegisterRoutes(
r *gin.Engine,
ctrl *controller.MeetingController,
recordingCtrl *controller.MeetingRecordingController,
jwtAuth gin.HandlerFunc,
) {
authed := r.Group("/api/v1/meeting")
authed.Use(jwtAuth)
{
@@ -29,5 +35,15 @@ func RegisterRoutes(r *gin.Engine, ctrl *controller.MeetingController, jwtAuth g
authed.POST("/rooms/:code/chats", ctrl.SendChat)
authed.GET("/rooms/:code/chats", ctrl.ListChats)
// 会议录制Phase B 引入)
authed.POST("/rooms/:code/recordings", recordingCtrl.StartRecording)
authed.DELETE("/rooms/:code/recordings/:id", recordingCtrl.StopRecording)
authed.GET("/rooms/:code/recordings", recordingCtrl.ListRecordings)
}
// 内部 webhookPhase B watchdogmedia-server 异常退出回调
// 鉴权由 controller 内部用 X-Internal-Secret header + INTERNAL_WEBHOOK_SECRET 校验
// 不走 JWT因为调用方是 media-server 而非用户
r.POST("/internal/meeting/recordings/failure", recordingCtrl.MediaServerFailureWebhook)
}