mirror of
https://github.com/coder/coder.git
synced 2025-07-03 16:13:58 +00:00
feat(coderd): add mark-all-as-read endpoint for inbox notifications (#16976)
[Resolve this issue](https://github.com/coder/internal/issues/506) Add a mark-all-as-read endpoint which is marking as read all notifications that are not read for the authenticated user. Also adds the DB logic.
This commit is contained in:
@ -1395,6 +1395,7 @@ func New(options *Options) *API {
|
||||
r.Use(apiKeyMiddleware)
|
||||
r.Route("/inbox", func(r chi.Router) {
|
||||
r.Get("/", api.listInboxNotifications)
|
||||
r.Put("/mark-all-as-read", api.markAllInboxNotificationsAsRead)
|
||||
r.Get("/watch", api.watchInboxNotifications)
|
||||
r.Put("/{id}/read-status", api.updateInboxNotificationReadStatus)
|
||||
})
|
||||
|
Reference in New Issue
Block a user