Is there dry_run functionality in FCM? - google-cloud-messaging

GCM has dry_run functionality:
This parameter, when set to true, allows developers to test a request
without actually sending a message.
GCM is being deprecated in favor of FCM, but I don't see a similar feature in FCM.
Does FCM allow you to do a dry run?

AL's answer is based on the FCM Legacy.
For FCM v1, this option is called validate_only
You can see the documentation here: Firebase docs

Yes. The dry_run feature is still available for FCM (Legacy).

Related

How does WhatsApp notifications bypass Doze if it uses XMPP?

I'm trying to work out how WhatsApp notifications work. First of all, does it use XMPP or FCM messaging? Many online sources say it uses XMPP but the WhatsApp FAQ has hints towards FCM (https://faq.whatsapp.com/en/android/20887936/?category=5245260 at the very bottom of page it says "it is possible that you are not receiving updates from Google's push notification service.")
If WhatsApp does use XMPP, how does it bypass Doze? Because surely WhatsApp needs FCM high-priority to bypass Doze? Does this mean WhatsApp may use a combination of FCM and XMPP?
Many thanks.

GCM migration to FCM

I am confused about GCM to FCM migration.
I was sending data only, so I could wake up my app when it was closed, and got into onmessagereceive.
With my migration to FCM, it no longer works, and saw following :
A service extending GcmListenerService is now required only for the following use cases:
receiving messages with data payload only.
WHat exactly needs to be maintained from the GCM part. Do I need to have both FCM and GCM in my manifest, and do I need to have both FCMlistenerservice AND GCMlistenerservice ?
If only GCMlistenerservice is required, what is then the use of the FCM migration , and why is this data payload only not integrated in the FCM ?
Thanks in advance
Best regards
Ludo Kustermans

In Codename One which is supported either GCM or FCM?

As per this link, FCM is the new version of GCM under the Firebase brand. In Codename One, which is supported? GCM or FCM?
We currently use GCM internally. We can switch to FCM but there is no real reason. Google has no intention of removing GCM as FCM (and a lot of apps) depend on it.
They are pushing FCM to push firebase. This provides no advantage to Codename One users as the easier API isnt' relevant (we abstract away the pains of GCM).
Bottom line is that you don't need to worry, if there is a need to switch to FCM we will do it for you and it will be seamless.
I'm not too familiar with Codename One so I decided to go ahead and look into their site. I found this Codename One page that guides about Push Notifications, but noticed that it's an old guide since this was still using the Developer Console when generating the Server Key (used for GCM/FCM).
With that, I went ahead and asked the Codename One chat support (lower-right side of the page). Chat history below:
Me:
Hey guys. I was wondering what Push Notification Services do you Support?
I've seen this link -- https://www.codenameone.com/how-do-i---use-push-notification-send-server-push-messages.html
Do you have your own Push Notification Service? Or are you guys using GCM? Is it already integrated with FCM too?
Lianna (Chat Support):
Hi,
we use the native push notifications for the respective platforms GCM, Firefox, Chrome, Microsoft and ipns.
Currently we use GCM and not FCM as the advantages given by FCM are mostly for API usage (which isn't applicable) and not very portable (available only for Android). When/if we switch to FCM this would be seamless thanks to our abstraction of the service.
FYI that video is a bit out of date, there is more up to date coverage in our developer guide.
Credit goes to Lianna (Kudos! :)). I think this here is the developer guide she was referring to.

google Gcm can't switch to google Fcm

I used rpush Gcm to send notification, Now I want to Change Google Gcm to new version of Google Fcm, Then I install rpush version 2.7.0,this version is to use Fcm to send notification,however the file "delivery.rb" still be the old link "https://gcm.googleapis.com",not new version link "https://fcm.googleapis.com",what's the matter with the issue?need your help,thanks!
As stated in this thread, updating endpoints is not strictly required, as Google will continue to support the existing GCM endpoints. Also based from this documentation, be noted of that the new FCM version of gcm-http.googleapis.com/gcm/ is fcm.googleapis.com/fcm/ (without "http").

PushSharp - GCM Authorization Failed

Using v4.0.10 of Pushsharp (nuget package), I am getting error GCM Authorization Failed when sending push notifications to Android devices.
Seems the bug raised in issue 574 (https://github.com/Redth/PushSharp/issues/574 ) has been compiled into the nuget package, yet I'm still getting this error.
Could this be related to the introduction of Firebase Cloud Messaging?
Does anyone still have success using GCM?
As of right now, GCM is still usable. However, it is highly encouraged for new users to use FCM instead. Either way, for both GCM and FCM, you must use a Server Key generated from the Firebase Console. There is a visible note in the GCM docs saying:
Starting from Sept. 2016 new server key can only be created in the Firebase Console using the Cloud Messaging tab of the Settings panel. Existing projects that need to create a new server key can be imported in the Firebase console without affecting their existing configuration.
The Authorization error has been encountered by number of users, some also had an old project. See my answer here for more details.
The sender id used in the app code needs to match the sender id Firebase Cloud Message Console and its corresponding "Firebase Cloud Messaging token".
Thank you #AL for your help.