Let the lead keep notes on how its user works

This commit is contained in:
Ian Gulliver
2026-10-16 10:50:29 -07:00
parent 919e1f8002
commit d6f73a1560
18 changed files with 759 additions and 208 deletions
+18
View File
@@ -52,6 +52,24 @@ func (s *Server) MessageLead(w http.ResponseWriter, r *http.Request) {
writeJSON(w, http.StatusAccepted, sess)
}
func (s *Server) ListLeadNotes(w http.ResponseWriter, r *http.Request) {
notes, err := s.store.LeadNotes(r.Context(), actor(r))
if err != nil {
writeStoreError(w, err)
return
}
writeJSON(w, http.StatusOK, notes)
}
func (s *Server) DeleteLeadNote(w http.ResponseWriter, r *http.Request, noteId string) {
err := s.agents.DeleteLeadNote(r.Context(), actor(r), noteId)
if err != nil {
writeAgentError(w, err)
return
}
w.WriteHeader(http.StatusNoContent)
}
func (s *Server) GetFocus(w http.ResponseWriter, r *http.Request) {
f, err := s.store.GetFocus(r.Context(), actor(r))
if err != nil {