问题
I want to use GCM for my project and so i create a project at google console and wanted to add an api key. Now i have different options:
- Server Key
- Browser Key
- Android Key
- iOS Key
What i actually want to do is sending GCM Messages from my Apache Server using PHP to my Android devices. So which kind of key do i need now? The Server Key? The Browser Key or the Android Key?
I know that all i need at my Android Client side is the SENDER_ID
which is the id of my project. I just need the API key serverside.
回答1:
You need the Server Key. Using it you can send push notifications to Android Devices using cURL
in PHP
.
回答2:
Check official web site: Setting up API keys
来源:https://stackoverflow.com/questions/36236376/gcm-api-key-confusion