Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Where to find the Google Project Number
Started by akao Aug 24 2018 04:04 PM

4 replies to this topic
onesignal plugin android sdk
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

akao

[GLOBAL: userInfoPane.html]
akao
  • Contributor

  • 347 posts
  • Corona SDK

I must be missing something obvious. In the setup document, it refers to a "Google Project Number" for Google Play: https://documentation.onesignal.com/docs/corona-sdk-setup but I can't find it. 

 

I went through the documentation and setup FireBase (https://documentation.onesignal.com/docs/generate-a-google-server-api-key), but don't see a Google Project Number. I also noticed that the Android native SDK's documentation sets the Google Project Number simply as "REMOTE" (https://documentation.onesignal.com/docs/android-sdk-setup). Is that what I should do? What should i be setting this to? 

 

thx!

 



[TOPIC: post.html]
#2

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 974 posts
  • Corona SDK

A couple of things.

  •  Hopefully, you are building for iOS if not the current OneSignal plugin for Android has a nasty crash bug. They are working on it and a new plugin is on way. If you can't wait I provided code to set up OneSignal on Android just using a rest request.
  • Now for the Project Number. It is the Google Play Console ->  Game Services -> Click on your game -> And then the number is right under the title. If you don't have a "Game Project" just create one. Follow the steps and make sure you add the correct game/app.

Adrian

 

Attached File  first.png   31.49KB   0 downloads

 

Attached File  second.png   34.69KB   0 downloads



[TOPIC: post.html]
#3

akao

[GLOBAL: userInfoPane.html]
akao
  • Contributor

  • 347 posts
  • Corona SDK

@agramonte Thank you so much for the pointer! Yes, we are trying to test Android right now, and I see the other post. We'll try to wait for the fix from OneSignal. If they don't come through, then we'll test your approach.

 

Also - could you give me some more pointer on Android configuration? One Signal's document is rather lacking. 

 

- Until I saw your screenshot, I didn't realize I had to configure GameServices as well. Do you know when I can find a step-by-step on that? I tried configuring mine, but ran into SHA1 issue while trying to link my app.

 

- I also saw from this link (https://support.magplus.com/hc/en-us/articles/204972667-Android-Enabling-Google-Cloud-Messaging-Firebase-in-Your-Android-Apps) that you are suppose to put the Firebase project's API Key into the App's "Services & API"->"Google Cloud Messaging". Should I be doing that? 

 

This whole thing has been rather confusing. Many thanks!

Andrew



[TOPIC: post.html]
#4

agramonte

[GLOBAL: userInfoPane.html]
agramonte
  • Contributor

  • 974 posts
  • Corona SDK

I have not done a GameServices config in a very long time and I don't have one planned for at least a few months (might be next year) since my next few releases are just updates to existing apps (4th quarter season is upon us). To get the SH1 key it depends if you are using google signing or your own signing. For google signing just copy the SHA1 key from the dashboard. If you are doing your own signing then you need to find the command to pull that out of your keyStory/key. Do a search on google for "Android keystore SHA1 command.

 

Originally you didn't have to do Firebase API thing, but I noticed when I did the rest only code that you had to do it. So yes I believe you will have to. It is fairly straightforward, but if you run into problems let me know I should be able to help you with that since I just did it.

 

 

Adrian



[TOPIC: post.html]
#5

akao

[GLOBAL: userInfoPane.html]
akao
  • Contributor

  • 347 posts
  • Corona SDK

Thx @agramonte. I'll give it a try on Monday. 




[topic_controls]
[/topic_controls]