Microsoft Azure PlayFab logo
    • Multiplayer
    • LiveOps
    • Data & Analytics
    • Add-ons
    • For Any Role

      • Engineer
      • Designer
      • Executive
      • Marketer
    • For Any Stage

      • Build
      • Improve
      • Grow
    • For Any Size

      • Solo
      • Indie
      • AAA
  • Runs on PlayFab
  • Pricing
    • Blog
    • Forums
    • Contact us
  • Sign up
  • Sign in
  • Ask a question
  • Spaces
    • PlayStream
    • Feature Requests
    • Add-on Marketplace
    • Bugs
    • API and SDK Questions
    • General Discussion
    • LiveOps
    • Topics
    • Questions
    • Articles
    • Ideas
    • Users
    • Badges
  • Home /
  • API and SDK Questions /
avatar image
Question by andre-vgm · Jun 30, 2016 at 03:31 AM · Push Notifications

Can't get Android Push to work [Unity SDK],Cannot get Android Push to work [Unity SDK]

Hey I have spent couple of hours to get the Android Push to work but I can't :(

I have followed several guides but the "_RegistrationReadyCallback" doesn't get called...

  • I have the latest Unity SDK imported from the Asset Store and unpacked the Android Plugin...
  • I've set up a Google Project and copied the Sender ID to be used for initializing the Android plugin
  • I adapted my AndroidManifest file (like this one)
  • but the _RegistrationReadyCallback won't get fired...

Have I missed something? Am I right that I do not have to be logged in as PlayFab client to get a token?

Hope you can help ;)

    ,

    Hey, I have spent the last couple of hoursto get Android Push to work, but I can't :(

    I have followed all steps of the documentation (https://api.playfab.com/docs/push-for-android) and the guide on GitHub. I do not get the "_RegistrationReadyCallback" event called. That is really strange because I have unpacked the Android Push Package for Unity and the latest SDK for Unity from the Asset Store... I hope you can help ;)

    Comment

    People who like this

    0 Show 1
    10 |1200 characters needed characters left characters exceeded
    ▼
    • Viewable by all users
    • Viewable by moderators
    • Viewable by moderators and the original poster
    • Advanced visibility
    Viewable by all users
    avatar image andre-vgm · Jun 30, 2016 at 12:17 AM 0
    Share

    Sorry for the mess xD I had to write my question twice... but now there are duplicates in my post :P

    1 Reply

    · Add your reply
    • Sort: 
    avatar image
    Best Answer

    Answer by Brendan · Jun 30, 2016 at 03:34 AM

    Can you try giving the Push Notification Debugger a try, and see what the results are of the "test push" option"? It provides an example of getting the token as well as testing whether the Admin setup part of the process has been completed successfully.

    https://github.com/PlayFab/PlayFab-Samples/tree/master/TestingTools/PushNotifications

    Comment

    People who like this

    0 Show 3 · Share
    10 |1200 characters needed characters left characters exceeded
    ▼
    • Viewable by all users
    • Viewable by moderators
    • Viewable by moderators and the original poster
    • Advanced visibility
    Viewable by all users
    avatar image andre-vgm · Jun 30, 2016 at 07:57 AM 0
    Share

    I've given it a try and I am able to register for push :P ...do I have to be logged in as a client before I am able to retrieve a token? Currently I request a token before logged in, save the token and then push it to PlayFab after my login process. But in my projects the registrationreadycallback never gets called

    avatar image andre-vgm · Jun 30, 2016 at 08:21 AM 0
    Share

    Ok I figured it out: I replaced "void OnGCMReady(bool status)" with "public static void OnGCMReady(bool status)" and it worked now! The devil lies in the detail...

    Thank you for your help!

    avatar image Brendan ♦♦ andre-vgm · Jun 30, 2016 at 08:25 AM 1
    Share

    Excellent - glad to hear you're no longer blocked!

    Your answer

    Hint: You can notify a user about this post by typing @username

    Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

    Navigation

    Spaces
  • General Discussion
  • API and SDK Questions
  • Feature Requests
  • PlayStream
  • Bugs
  • Add-on Marketplace
  • LiveOps
  • Follow this Question

    Answers Answers and Comments

    No one has followed this question yet.

    Related Questions

    Can I use FCM? 1 Answer

    Is it acceptable to put AndroidPushID (and iOSPushID) in TitleData so it can be modified remotely? 2 Answers

    ProfileAPI SetProfileLanguage randomly returning NotAuthorized 1 Answer

    Confirmation that PlayFab Push for Android is Asynchronous? 1 Answer

    Could not find RSA key text in PEM file 1 Answer

    PlayFab

    • Multiplayer
    • LiveOps
    • Data & Analytics
    • Runs on PlayFab
    • Pricing

    Solutions

    • For Any Role

      • Engineer
      • Designer
      • Executive
      • Marketer
    • For Any Stage

      • Build
      • Improve
      • Grow
    • For Any Size

      • Solo
      • Indie
      • AAA

    Engineers

    • Documentation
    • Quickstarts
    • API Reference
    • SDKs
    • Usage Limits

    Resources

    • Forums
    • Contact us
    • Blog
    • Service Health
    • Terms of Service
    • Attribution

    Follow us

    • Facebook
    • Twitter
    • LinkedIn
    • YouTube
    • Sitemap
    • Contact Microsoft
    • Privacy & cookies
    • Terms of use
    • Trademarks
    • Safety & eco
    • About our ads
    • © Microsoft 2020
    • Anonymous
    • Sign in
    • Create
    • Ask a question
    • Create an article
    • Post an idea
    • Spaces
    • PlayStream
    • Feature Requests
    • Add-on Marketplace
    • Bugs
    • API and SDK Questions
    • General Discussion
    • LiveOps
    • Explore
    • Topics
    • Questions
    • Articles
    • Ideas
    • Users
    • Badges