-
Notifications
You must be signed in to change notification settings - Fork 93
Open
Description
Problem
Push notifications on iOS arrive silently (banner appears, no sound). All settings enabled:
- Admin dashboard: "Enable Push Notifications" — ON
- App profile: "Enable Notifications" — ON
- iOS Settings → Databag → Notifications → Sounds — ON
Root Cause
In net/repeater/internal/api_notify.go, the FCM message is sent without platform-specific configuration:
notification := &messaging.Notification{ Title: msg.Title, Body: msg.Body }
message := &messaging.Message{
Notification: notification,
Token: msg.Token,
}Per Apple documentation, iOS requires an explicit "sound" field in the APNs aps payload to play a notification sound.
Without it, notifications are delivered silently.
References:
- Apple APNs Payload Key Reference: https://developer.apple.com/library/archive/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/PayloadKeyReference.html
- Firebase FCM cross-platform messages: https://firebase.google.com/docs/cloud-messaging/customize-messages/cross-platform
- Firebase Go SDK
messaging.Apsstruct (Sound field): https://pkg.go.dev/firebase.google.com/go/v4/messaging#Aps - Firebase Go SDK
messaging.AndroidNotificationstruct (Sound field): https://pkg.go.dev/firebase.google.com/go/v4/messaging#AndroidNotification
Suggested Fix
In net/repeater/internal/api_notify.go, replace the message construction (around line 44) with:
notification := &messaging.Notification{ Title: msg.Title, Body: msg.Body }
message := &messaging.Message{
Notification: notification,
Token: msg.Token,
Android: &messaging.AndroidConfig{
Notification: &messaging.AndroidNotification{
Sound: "default",
},
},
APNS: &messaging.APNSConfig{
Payload: &messaging.APNSPayload{
Aps: &messaging.Aps{
Sound: "default",
},
},
},
}All struct types (AndroidConfig, AndroidNotification, APNSConfig, APNSPayload, Aps) are from the firebase.google.com/go/v4/messaging package already imported in the file. No new dependencies required.
Additional Notes
- A
Payloadstruct with aSoundfield is defined innet/server/internal/api_setPushEvent.gobut is dead code — never used in the actual push flow - The real push path is:
SendPushEvent()→ HTTP POST torepeater.coredb.org/notify→Notify()in repeater → FCM SDK - Previously reported in Discussion Feature Request: iOS App Notification Sound #20. A fix was committed but the issue persists on
balzack/databag:latestas of Feb 2026
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels