feat: add private S3 attachments and safe reconciliation

This commit is contained in:
Vladislav Agapov
2026-10-29 16:27:20 +03:00
parent ec540a1a72
commit aca4c4eea9
217 changed files with 15042 additions and 44 deletions
+26
View File
@@ -0,0 +1,26 @@
package fiber
// initRoutes registers health endpoints and authenticated application routes.
func (ctrl *Controller) initRoutes() {
ctrl.server.Get("/metrics", ctrl.handleMetrics)
ctrl.server.Get("/health/live", ctrl.handleLive)
ctrl.server.Get("/health/ready", ctrl.handleReady)
ctrl.server.Use(ctrl.admit)
ctrl.server.Post("/api/v1/users", ctrl.HandleUsersCreate)
ctrl.server.Post("/api/v1/auth/sessions", ctrl.HandleLogin)
api := ctrl.server.Group("/api/v1", ctrl.requireIdentity)
api.Delete("/auth/sessions/current", ctrl.HandleLogout)
api.Get("/users/me", ctrl.HandleUsersGetMe)
api.Post("/chats", ctrl.HandleChatsCreate)
api.Get("/chats", ctrl.HandleChatsGetPage)
api.Get("/chats/:chat_id", ctrl.HandleChatsGetByID)
api.Post("/chats/:chat_id/attachments", ctrl.handleUpload)
api.Get("/attachments/:id", ctrl.handleAttachment)
api.Get("/attachments/:id/content", ctrl.handleContent)
api.Post("/chats/:chat_id/messages", ctrl.HandleMessagesCreate)
api.Get("/chats/:chat_id/messages", ctrl.HandleMessagesGetPage)
ctrl.server.Use(ctrl.handleNotFound)
}