Skip to content

Instantly share code, notes, and snippets.

@kashifo
Created October 11, 2025 03:15
Show Gist options
  • Save kashifo/b9012a0d744d87eaf67fa0fa60d642e7 to your computer and use it in GitHub Desktop.
Save kashifo/b9012a0d744d87eaf67fa0fa60d642e7 to your computer and use it in GitHub Desktop.
{
notification: {
title: `🚨 Emergency alert from ${name}`,
body: "Click to view details",
},
data: {
route: "sos",
payload: JSON.stringify(data || {}),
click_action: "FLUTTER_NOTIFICATION_CLICK"
},
tokens: allTokens,
android: {
notification: {
channelId: "sos_alerts",
sound: "siren",
},
priority: "high",
ttl: 3600,
},
apns: {
headers: {
"apns-priority": "10",
},
payload: {
aps: {
sound: "siren.wav",
category: "sos_alerts",
"mutable-content": 1,
"content-available": 1
},
},
},
}
@kashifo
Copy link
Author

kashifo commented Oct 11, 2025

{
"aps": {
"alert": {
"title": "🚨 Emergency alert from new test 6",
"body": "Click to view details"
},
"sound": "siren.wav",
"category": "sos_alerts",
"mutable-content": 1,
"content-available": 1
},
"route": "sos",
"payload": {
"emergencyContactIds": ["Y8KccYRslTNNCv6XbQCHO5Ot9oG2"],
"userId": "3GpE93Zf0TO5UES98QWlJ05P81K3",
"name": "new test 6",
"phone": "1234",
"email": "[email protected]",
"location": {
"latitude": 13.131313,
"longitude": 80.131313,
"gpsAddress": "push test"
},
"timestamp": "2025-10-04T02:14:03.309941"
},
"click_action": "FLUTTER_NOTIFICATION_CLICK"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment