# Gradle Setup This file explains every dependency and plugin you need, plus why it exists. ## Step 1: Add Google Services plugin File: `app/build.gradle.kts` ```kotlin plugins { id("com.android.application") id("org.jetbrains.kotlin.android") id("com.google.gms.google-services") } ``` Google Services Plugin The Google Services plugin reads `google-services.json` and generates resources used by Firebase. ## Step 2: Add Bubbl + Firebase dependencies File: `app/build.gradle.kts` ```kotlin dependencies { // Firebase BOM keeps all Firebase libs on compatible versions implementation(platform("com.google.firebase:firebase-bom:33.3.0")) // FCM for push notifications implementation("com.google.firebase:firebase-messaging-ktx") // Bubbl SDK implementation("tech.bubbl:bubbl-sdk:2.0.9") // Required: location + background work implementation("com.google.android.gms:play-services-location:21.2.0") implementation("androidx.work:work-runtime-ktx:2.10.0") } ``` ## Why each line exists - `firebase-bom`: prevents version conflicts between Firebase libraries. - `firebase-messaging-ktx`: receives Bubbl push notifications. - `bubbl-sdk`: the SDK itself. - `play-services-location`: gets last known location and handles background location updates. - `work-runtime-ktx`: schedules background refresh jobs.