Skip to main content

Configuration Firebase Cloud Messaging on Android

Get a Firebase configuration file

1. The first thing you need to do to get started with Firebase is, sign up for a free account. You can use your Google account to sign in to your Firebase account.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android
2. After clicking on ‘Sign In with Google’, you might be asked to allow the Firebase to view your Email and your basic profile. Click on Allow button to continue.
3. Once you are signed in, Click on Go to your Console button if you are not automatically redirected to your Firebase console. Click on Create New Project button in your Firebase console.
4. Now you can see an overview of your new Firebase project. Now click on Add Firebase to your Android App as shown below.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android
5. Now you need to enter your application details (your application’s package name) and also get SHA-1 finger print and paste it in the field as shown below. Check out the note below on how to get SHA-1 from Android Studio.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android

Click on Add App button. Upon clicking it, a file named google-services.json gets downloaded to your machine.

Note : Following image shows how to get SHA-1 from Android Studio.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android
6. Download the google-services.json file and paste in the app folder of your Android application.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android

Note: If you forget to place google-services.json file under app folder, you will get the following error when you build your app.
https://wolaris.blogspot.com |  Configuration Firebase Cloud Messaging on Android

7. Open the build.gradle (Project level) file of your android application and add classpath ‘com.google.gms:google-services:3.0.0’ in the dependencies section. Your build.gradle (Project level) file will look as shown below.
buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.2.2'
        classpath 'com.google.gms:google-services:3.0.0'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        jcenter()
    }
}

Popular posts from this blog

Single Page Application With Laravel 5.3 And Vue.js 2.1.x

Description: Single Page Application With Laravel 5.3 And Vue.js 2.1.x Single Page Application with Laravel 5.3 and Vue.js 2.1.x. Refer the source code for better understanding. Frameworks and Libraries: - Laravel 5.3 - Vue.js 2.1.x - Vue Router - axios Provides: - CRUD - Single Page Application - Pagination - Sorting by columns - Advance filter - Filter relations - - - Source Code: https://github.com/codekerala/spa-laravel-vuejs - - - You should follow Code .

Laravel 5.4 With Android Firebase Cloud Messaging (FCM)

DOWNLOAD How to Package Aenean lacinia A library that lets you create a beer styled progress view with bubbles and all! (hic). Beer Progress View A cool beer styled progress view with realistic bubbles*. Cheers! Increment progress. Change beer colour. Change wave size. Change bubble colour. (*realism of bubbles not guaranteed) Setup To use BeerProgressView in your projects, simply add the library as a dependency to your build. Gradle dependencies { compile 'uk.co.barbuzz:beerprogressview:0.0.4' } Maven <dependency> <groupId>uk.co.barbuzz.beerprogressview</groupId> <artifactId>beerprogressview</artifactId> <version>0.0.4</version> <type>pom</type> </dependency> Alternatively you can directly import the /library project into your Android Studio project and add it as a dependency in your build.gradle. The library is currently configur...

Apps created on Android

For applications on Android (for beginners) Start - for those of you who love DIY Android and the desire to create their own programs. The study of the application of decisions is not easy, but for a beginner it can be found. Some developers of applications for Android, to provide the tools to create applications for beginners, of course, these tools can be downloaded directly from Google Play on your Android gadget. Here are 5 tools manufacturers Android apps for beginners. 1. Appiventor Basically this program is used by inexperienced developers, and has now received belongs to the Massachusetts Institute of Technology. Tools such as this requires its own understands the language of a program or "coding", but do not worry, because this app also has video lessons. 2. PhoneGap For those of you who are effective using HTML, CSS or JavaScript simply using Fungab. Fungab not only used to create mobile applications for Android, but also for mobile phone application...