Is there a way to see logs of the request being sent to firebase from Gamesparks?
I went to API stream and all I could find was this:
{ "@class":".ScriptMessage", "data":{ "body":"Login now to collect your resources.", "title":"A New Message" }, "extCode":"MyScriptMessageExtension", "messageId":"5b7ef67907420b0521ac09dd", "notification":true, "playerId":"5b7df17280299a889b4da020", "summary":"Login now to collect your resources.", "title":"A New Message" }
If I set to send via socket to true, I am able to receive messages in game with the app running as expected. But with the app closed, I dont get push notifications unless I send from the Firebase console.
This post mentions a 'capture-push-record'? Where can I find that?
https://support.gamesparks.net/support/discussions/topics/1000085225
I finally decided to try using the Legacy Server Key from Firebase..... and it worked.
Notification is now being sent from gamesparks.
Jared Seeders
Pushing notifications with the Firebase console works.
However, I do not receive any notifications on the Android device when using messages from GameSparks.
Google Integration FCM Template
MyScriptMessageExtension FCM Template
in addition to these templates, I've also tried ${title} and ${summary}, to no avail.
Cloud Code that accepts pId as playerId to send message to.
PushRegistrationRequest Code:
Checked the player record I'm using, and see I get a token:
player.deviceRegIds: d8lkl...w2A: "FCM"
When sending the message using Test Harness, I have tried:
1. Having the app running in the background.
2. Swiping the app off the Recent Apps screen.
3. Restarting the phone and not running the app.
4. Turning off/on wifi
5. Turning off battery saver.
Apparently force closing can cause the app to not receive notifications, so I have tried all of the above to rule that out.
1 person has this question