spark-server/internal/infrastructure/push/push.go
zhr ae9a71034d feat: implement Spark IM V3 modular monolith
Add HTTP /v1 MVC, TCP send path, groups with server-side member-avatar collage, object-storage upload, and friends/favorites around the architecture-v3 layout.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-17 19:52:11 +08:00

26 lines
642 B
Go

package push
import "context"
// Notification is a system push. Mute is decided in Deliver Worker, not gnet.
// Title/Body must be localized with i18n.Notify using the recipient device language.
type Notification struct {
UserID int64
DeviceID uint64
ConversationID int64
Type string
Title string
Body string
Badge int
CollapseKey string
}
type Notifier interface {
Notify(ctx context.Context, n *Notification) error
}
// Noop satisfies V3: the interface exists; APNS/FCM can wait.
type Noop struct{}
func (Noop) Notify(context.Context, *Notification) error { return nil }