feat: add conversation retrieve api & return section id field in chat… (#2408)

This commit is contained in:
junwen-lee
2025-10-29 17:29:24 +08:00
committed by GitHub
parent 504f094728
commit bfd69ac17d
10 changed files with 925 additions and 3 deletions

View File

@ -209,3 +209,23 @@ func DeleteConversationApi(ctx context.Context, c *app.RequestContext) {
c.JSON(consts.StatusOK, resp)
}
// RetrieveConversationApi .
// @router /v1/conversation/retrieve [GET]
func RetrieveConversationApi(ctx context.Context, c *app.RequestContext) {
var err error
var req conversation.RetrieveConversationApiRequest
err = c.BindAndValidate(&req)
if err != nil {
invalidParamRequestResponse(c, err.Error())
return
}
resp, err := application.ConversationSVC.RetrieveConversation(ctx, &req)
if err != nil {
internalServerErrorResponse(ctx, c, err)
return
}
c.JSON(consts.StatusOK, resp)
}