Prerequisites
Creating an app
Let's get going!
The very first step is to go to Batch's dashboard and create a new Android app.
Now let's generate your push keys and put them in Batch's dashboard.
Getting your Server API Key
Here are the two steps you need to take to find your Server API Key.
First, go to the Firebase console. Once you are logged in, select your existing project or create a new one.
Then, click the ⚙ next to your project name and "Project settings". Click the "Cloud Messaging" tab.
If the "Cloud Messaging API (Legacy)" is marked as disabled, you will need to enable it:
- Click on the 3 dots next to "Cloud Messaging API (Legacy)"
- Select "Manage API on Google Cloud Console"
- A new tab will open. Click on "Enable"
- Wait until the page reloads with a different content. A "DISABLE API" button should appear
- Close the tab, go back on the Firebase settings and refresh the page
- The token should be now available
Finally, copy the Sender ID and Server Key under "Cloud Messaging API".
Important: Make sure you choose an existing project instead of creating a new one if you are migrating from an other push provider.
Configuring Batch Push
Now go to ⚙ Settings → General on Batch's dashboard and fill the Sender ID and Server API Key fields in ⚙️ Settings → Push settings.
License Attribution
As Batch uses open-source software, you must include attribution text in your application. This usually goes in a "Legal Notices" or "About" screen.
You can get the attribution text here.
Note: Batch provides the license text in the maven central artifact metadata. If you use a gradle plugin that automatically extract attributions from your dependencies, check if it didn't automatically add the attributions.