Checkpoint: v4.0 media service, compose deploy, and verified docs

这个提交包含在:
cryptocommuniums-afk
2026-03-14 21:45:31 +08:00
父节点 27083d5af9
当前提交 d5431aee0e
修改 41 个文件,包含 4056 行新增883 行删除

查看文件

@@ -258,6 +258,32 @@ ${recentScores.length > 0 ? `- 用户最近的分析数据: ${JSON.stringify(rec
return { videoId, url };
}),
registerExternal: protectedProcedure
.input(z.object({
title: z.string().min(1).max(256),
url: z.string().min(1),
fileKey: z.string().min(1),
format: z.string().min(1).max(16),
fileSize: z.number().optional(),
duration: z.number().optional(),
exerciseType: z.string().optional(),
}))
.mutation(async ({ ctx, input }) => {
const videoId = await db.createVideo({
userId: ctx.user.id,
title: input.title,
fileKey: input.fileKey,
url: input.url,
format: input.format,
fileSize: input.fileSize ?? null,
duration: input.duration ?? null,
exerciseType: input.exerciseType || "recording",
analysisStatus: "completed",
});
return { videoId, url: input.url };
}),
list: protectedProcedure.query(async ({ ctx }) => {
return db.getUserVideos(ctx.user.id);
}),