firebase-notifications

How to track FCM push notifications send form server side or Rest Client? [duplicate]

荒凉一梦 提交于 2019-11-29 14:19:46
This question already has an answer here: Firebase notification records/log API 1 answer Is it possible to track push notification from firebase console which is send from server-side or Rest client. See duplicate post. No. Currently, only messages sent through the Firebase Notifications Console are visible in the console. Messages sent through the API could be tracked in the Diagnostics Tool , keeping in mind that this doesn't include messages sent to topics . 来源: https://stackoverflow.com/questions/44697015/how-to-track-fcm-push-notifications-send-form-server-side-or-rest-client

Send URL in push notification Firebase

折月煮酒 提交于 2019-11-29 11:40:55
My application is currently receiving Text, Image and both as a push notification from Firebase console. I want to send a URL too as a notification from my Firebase console to the app user. On clicking the notification. user shall be redirected to the specific URL, e.g. www.google.com .How can I do this in following code? package com.example.khan.andronotification; /** * Created by AndroidBash on 20-Aug-16. */ import android.app.NotificationManager; import android.app.PendingIntent; import android.content.Context; import android.content.Intent; import android.graphics.Bitmap; import android

Firebase Cloud Messaging Doesn't Create Push Notifications but Gets Information

人走茶凉 提交于 2019-11-29 11:03:11
问题 I was working through this tutorial (https://www.youtube.com/watch?v=JsWHzU1DxjM) to try and put push notifications into my iOS app. I was able to successfully get the certificate for APNS and set the "push notification" and "background modes" capabilities to on. Also, Firebase is able to get the info from the notification when I send one from the firebase console. However, when the app is running in the background the banner notifications never appear. I feel like I may have had a problem

FCM Notification in iOS doesn't play sound when received

拈花ヽ惹草 提交于 2019-11-29 06:20:00
I am using Firebase push notifications in my iOS Application. Although I am able to send the notification by sending below payload, it doesn't play a sound when received. { "to": "myToken", "notification": { "body": "test", "title": "test" }, "priority": "high" "sound": "default" } If I send the test message from console, it works well and plays notification sound. Note : My Authorization code is correct I am sending http request to https://fcm.googleapis.com/fcm/send I have tested it on IPhone 4 , IPhone 6 and IPhone 6S, All recieve notifications without sound your JSON "sound" : "default"

Firebase on Android - I want to disable firebase notifications on Android client

不问归期 提交于 2019-11-29 06:11:31
I'm using Firebase console to send notifications to users. However I want to let users disable notifications. How can I disable them? I am able to handle (and stop) notifications through FirebaseMessagingService only when the app is in foreground. But I cannot stop notifications when the app is in background. Not sure why this happens to you (code snippet maybe?), but there is a heavy weight ultimate solution: define your own c2dm receiver in the manifest and set the priority high (>0) then stop the notification from processing. GCM messages are processed as ordered broadcasts, so you can stop

Firebase send push notification twice

末鹿安然 提交于 2019-11-29 03:49:53
I wrote a very simple android app to test firebase push notification and I get one notification twice. this is the manifest service: <service android:name="com.google.firebase.messaging.FirebaseMessagingService"> <intent-filter> <action android:name="com.google.firebase.MESSAGING_EVENT"/> </intent-filter> </service> <service android:name="com.google.firebase.iid.FirebaseInstanceIdService"> <intent-filter> <action android:name="com.google.firebase.INSTANCE_ID_EVENT"/> </intent-filter> </service> this is the app gradle: compile 'com.google.android.gms:play-services:9.0.0' compile 'com.google

Firebase Notifications through server-side code

北慕城南 提交于 2019-11-29 01:57:31
问题 The new Firebase notifications service allows us to use a Console UI to post notifications to all mobile app users. But I could not find any REST API for the Firebase Notifications Service. I want to send notifications to mobile users automatically through server-side code based on an event. Does Firebase Notifications Service have an API that can be accessed over HTTP/S? 回答1: Yes,you can. 1) Firstly, get the server key of your firebase project: Project Settings -> Cloud Messaging Tab -> Copy

Firebase notifications when app is closed

故事扮演 提交于 2019-11-28 21:16:42
I have implemented Firebase notification in my Android application. When my app is running, notification is displayed with my custom layout, but when application is not running, the notification is displayed with the default layout. How can I change the notification layout to my layout when application is not running. Also, I store shared preferences to let user toggle notifications. But when app is not running the notification is displayed anyways. How can achieve that? @Override public void onMessageReceived(RemoteMessage remoteMessage) { if(SettingsFragment.getReceiceNotification()){ //if

FCM - Setting badge in onMessageReceived

好久不见. 提交于 2019-11-28 19:53:52
I have an Android application, where I'm using some method to show notification number on app icon. Now I want to set that number when notification is received. I thought that I should set the number when notification received so I set it inside onMessageReceived method. But, my problem is when my app is in background, onMessageReceived method not called, so the notification number isn't set. Following is my code. I set the number inside onMessageReceived . I already tested setBadge method and can verify that it is working. The problem is onMessageReceived is not called so setBadge is also not

APNS Firebase Notification failed to fetch token

社会主义新天地 提交于 2019-11-28 17:48:54
For Swift3 / iOS10 see this link: ios10, Swift 3 and Firebase Push Notifications (FCM) I'm trying to use the Firebase for Notifications and I integrated it exactly as described in the docs. But I don't understand why is doesn't work. When I build my project I see this line: 2016-05-25 16:09:34.987: <FIRInstanceID/WARNING> Failed to fetch default token Error Domain=com.firebase.iid Code=0 "(null)" This my AppDelegate: func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { FIRApp.configure() FIRDatabase.database()