diff --git a/src/Infrastructure/BotSharp.OpenAPI/Controllers/ConversationController.cs b/src/Infrastructure/BotSharp.OpenAPI/Controllers/ConversationController.cs index 76425dfe..e45a29de 100644 --- a/src/Infrastructure/BotSharp.OpenAPI/Controllers/ConversationController.cs +++ b/src/Infrastructure/BotSharp.OpenAPI/Controllers/ConversationController.cs @@ -483,7 +483,7 @@ public class ConversationController : ControllerBase } [HttpPost("/agent/{agentId}/conversation/{conversationId}/upload")] - public async Task UploadConversationMessageFiles([FromRoute] string agentId, [FromRoute] string conversationId, [FromBody] InputMessageFiles input) + public async Task UploadConversationMessageFiles([FromRoute] string agentId, [FromRoute] string conversationId, [FromBody] InputMessageFiles input) { var convService = _services.GetRequiredService(); convService.SetConversationId(conversationId, input.States); @@ -491,7 +491,7 @@ public class ConversationController : ControllerBase var fileStorage = _services.GetRequiredService(); var messageId = Guid.NewGuid().ToString(); var isSaved = fileStorage.SaveMessageFiles(conv.Id, messageId, FileSource.User, input.Files); - return isSaved ? messageId : string.Empty; + return Ok(new { messageId = isSaved ? messageId : string.Empty }); } [HttpGet("/conversation/{conversationId}/files/{messageId}/{source}")]