Update your project's AndroidManifest.xml
file to include the INTERNET
and ACCESS_NETWORK_STATE
permissions
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.analytics">
android:name="android.permission.INTERNET"/>
android:name="android.permission.ACCESS_NETWORK_STATE"/>
android
- Add the dependency to your project's top-level
build.gradle
:classpath 'com.google.gms:google-services:1.0'
- Add the plugin to your app-level
build.gradle
:apply plugin: 'com.google.gms.google-services'
Now, you need to add a dependency for Google Play Services. Inside your app's build.gradle
add:
compile 'com.google.android.gms:play-services-analytics:7.3.0'