tsk-54: Tweak instant message endpoint to save contact and message identification (#56)

Closes #54

Reviewed-on: phoenix/textsender-api#56
Co-authored-by: phoenix <kundeng00@pm.me>
Co-committed-by: phoenix <kundeng00@pm.me>
This commit is contained in:
phoenix
2025-12-22 22:39:29 +00:00
committed by phoenix
parent f5f753fe02
commit 6fa5ede358
10 changed files with 45 additions and 28 deletions
+3
View File
@@ -110,6 +110,9 @@ func (s *SendInstantMessageHandler) Send(w http.ResponseWriter, r *http.Request)
mer.Response = data
mer.UserId = req.UserId
mer.Sent = parsedTime
mer.Status = message.Message_Event_Response_Status_Instant
mer.ContactId = c.Id
mer.MessageId = &msg.Id
if err := s.MERStore.Create(ctx, &mer); err != nil {
statusCode = http.StatusInternalServerError
resp.Message = err.Error()