feat: Firebase Cloud Messaging push notifications
Backend: - New user_fcm_tokens table (migration 010) for storing device tokens - FCMService sends push via Firebase HTTP legacy API (server key from .env) - POST /api/fcm/register endpoint for Android to register its FCM token - AdminController::sendNotification() triggers FCM push after DB insert - FCM config added to config.php Android: - Firebase Cloud Messaging service (ServerManagerFirebaseService) receives push notifications and shows them via NotificationHelper - FCM token registered with backend on new token and on login - google-services.json template (must be replaced with real Firebase config) - firebase-setup.sh script with configuration instructions - FCM dependency + google-services plugin added to Gradle - Bump to v1.8.0 (versionCode 12)
This commit is contained in:
35
android/app/google-services.json
Normal file
35
android/app/google-services.json
Normal file
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"project_info": {
|
||||
"project_number": "000000000000",
|
||||
"project_id": "servermanager-placeholder",
|
||||
"storage_bucket": "servermanager-placeholder.appspot.com"
|
||||
},
|
||||
"client": [
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:000000000000:android:0000000000000000",
|
||||
"android_client_info": {
|
||||
"package_name": "com.devlab.app"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "PLACEHOLDER_API_KEY_REPLACE_IN_FIREBASE_CONSOLE"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"analytics_service": {
|
||||
"status": 0
|
||||
},
|
||||
"appinvite_service": {
|
||||
"status": 0
|
||||
},
|
||||
"google_cast_service": {
|
||||
"status": 0
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"configuration_version": "1"
|
||||
}
|
||||
Reference in New Issue
Block a user