{"_id":"56c41d9e4f0aed1700afabac","project":"56bc8e679afb8b0d00d62dcf","__v":2,"user":"56b98db7bb36440d0001f492","category":{"_id":"56c4184c28bd680d005e7ac7","__v":5,"project":"56bc8e679afb8b0d00d62dcf","pages":["56c41d876063071700500d06","56c41d92bb64720d00552b94","56c41d9e4f0aed1700afabac","56c41dafc0c4630d004e86c3","56c41dbbc0c4630d004e86c5"],"version":"56bc8e689afb8b0d00d62dd2","sync":{"url":"","isSync":false},"reference":true,"createdAt":"2016-02-17T06:50:52.926Z","from_sync":false,"order":6,"slug":"push","title":"Push"},"version":{"_id":"56bc8e689afb8b0d00d62dd2","project":"56bc8e679afb8b0d00d62dcf","__v":18,"createdAt":"2016-02-11T13:36:40.146Z","releaseDate":"2016-02-11T13:36:40.146Z","categories":["56bc8e689afb8b0d00d62dd3","56c3c837bc41330d009f25ed","56c3c83e521f350d00d348eb","56c3c8452d97560d00e23cd8","56c3c85234df460d00c2beb8","56c4180d70187b17005f43b4","56c418162d97560d00e23cf6","56c4181cc4796b0d007ef039","56c4182370187b17005f43b5","56c418292e75e01700986052","56c4183328bd680d005e7ac6","56c4183bbb64720d00552b88","56c418414040602b0064cea0","56c4184754b6030d00ec29a1","56c4184c28bd680d005e7ac7","56c4185370187b17005f43b6","56c4185b6063071700500cfc","582a98b6f8c0a0190053d7a5"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"parentDoc":null,"updates":[],"next":{"pages":[],"description":""},"createdAt":"2016-02-17T07:13:34.697Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":2,"body":"### Obtaining a GCM API key\nBuddy supports pushing to Google Android Devices with Google Play Services installed via GCM. \n\n> This guide covers how to set up your Buddy app to send pushes using GCM. For an introduction to using GCM in\n> your app, see [Implementing GCM Client](http://developer.android.com/google/gcm/client.html)\n\nVisit the [Google Developers Console](https://console.developers.google.com) and create a project for your app if you haven't created on already. Make note of the Project Number as this will become your `SenderID` when your app registers for push notifications with GCM. Find \"Google Cloud Messaging for Android\" and enable it:\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/fzopO1T8QGOVGZZrSo20_push_getting_started_gcm_1.png\",\n        \"push_getting_started_gcm_1.png\",\n        \"1456\",\n        \"89\",\n        \"\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\nSelect credentials and click \"Create new key\". When prompted, select \"Server key\" from the group of options and you will be presented with the following screen.\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/si9p0lgnTyCkrhnrTmad_push_getting_started_gcm_2.png\",\n        \"push_getting_started_gcm_2.png\",\n        \"693\",\n        \"356\",\n        \"\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\nLeave the allowed IP addresses blank and select Create.\n\n###Sending your GCM API key to Buddy\nCopy the resulting value and navigate to [buddyplatform.com](https://buddyplatform.com/).\n\nFind your app. Select _Push_ under the primary navigation window and you'll see a screen that looks like this:\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/aQSMVfJgQ5eLd8NjBVKS_push_getting_started_gcm_3.png\",\n        \"push_getting_started_gcm_3.png\",\n        \"397\",\n        \"240\",\n        \"#0d4a9e\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\nClick _Add GCM API Key_, paste in your key and select _OK_. Now you're ready to send pushes to Android using Buddy.","excerpt":"","slug":"getting-started-gcm","type":"basic","title":"Getting Started - GCM"}

Getting Started - GCM


### Obtaining a GCM API key Buddy supports pushing to Google Android Devices with Google Play Services installed via GCM. > This guide covers how to set up your Buddy app to send pushes using GCM. For an introduction to using GCM in > your app, see [Implementing GCM Client](http://developer.android.com/google/gcm/client.html) Visit the [Google Developers Console](https://console.developers.google.com) and create a project for your app if you haven't created on already. Make note of the Project Number as this will become your `SenderID` when your app registers for push notifications with GCM. Find "Google Cloud Messaging for Android" and enable it: [block:image] { "images": [ { "image": [ "https://files.readme.io/fzopO1T8QGOVGZZrSo20_push_getting_started_gcm_1.png", "push_getting_started_gcm_1.png", "1456", "89", "", "" ] } ] } [/block] Select credentials and click "Create new key". When prompted, select "Server key" from the group of options and you will be presented with the following screen. [block:image] { "images": [ { "image": [ "https://files.readme.io/si9p0lgnTyCkrhnrTmad_push_getting_started_gcm_2.png", "push_getting_started_gcm_2.png", "693", "356", "", "" ] } ] } [/block] Leave the allowed IP addresses blank and select Create. ###Sending your GCM API key to Buddy Copy the resulting value and navigate to [buddyplatform.com](https://buddyplatform.com/). Find your app. Select _Push_ under the primary navigation window and you'll see a screen that looks like this: [block:image] { "images": [ { "image": [ "https://files.readme.io/aQSMVfJgQ5eLd8NjBVKS_push_getting_started_gcm_3.png", "push_getting_started_gcm_3.png", "397", "240", "#0d4a9e", "" ] } ] } [/block] Click _Add GCM API Key_, paste in your key and select _OK_. Now you're ready to send pushes to Android using Buddy.