I'm currently integrating Moengage into my Flutter application, but I'm encountering an issue specifically on Android. I've followed the setup instructions provided in the documentation, and while the application is running without errors, the events fired from the application are not appearing on the Moengage dashboard.
Interestingly, I've also implemented Moengage in a similar manner for iOS, and it seems to be working fine on that platform. However, on Android, I'm facing this problem consistently.
Here's a summary of what I've done:
Followed the integration steps outlined in the Moengage documentation for Flutter. Ensured that the SDK is initialized correctly in the Flutter app. Verified that events are being triggered from the application code.
Despite these efforts, I'm unable to see any events reflected on the Moengage dashboard for Android.
Could someone please provide insights or suggestions on what might be causing this issue? Has anyone encountered a similar problem while integrating Moengage with a Flutter app on Android? Any help would be greatly appreciated. Thank you!
Setup Code :
MainActivity.kt
import com.moengage.flutter.MoEInitializer
import com.moengage.core.MoEngage
import com.moengage.core.DataCenter
import android.os.Bundle
import io.flutter.app.FlutterApplication
class MainActivity: FlutterApplication() {
override fun onCreate() {
super.onCreate()
val moEngage: MoEngage.Builder = MoEngage.Builder(this, "TOKEN HERE",DataCenter.DATA_CENTER_1)
MoEInitializer.initialiseDefaultInstance(applicationContext, builder = moEngage)
}
}
build.gradle
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar', "*.aar"])
implementation(platform("com.google.firebase:firebase-bom:32.2.3"))
implementation("com.google.firebase:firebase-analytics-ktx")
implementation ("com.moengage:moe-android-sdk:13.00.00")
implementation("androidx.core:core:1.6.0")
implementation("androidx.appcompat:appcompat:1.3.1")
implementation("androidx.lifecycle:lifecycle-process:2.4.0")
implementation ("androidx.lifecycle:lifecycle-viewmodel-ktx:2.4.0")
}
Update:
The events are not visible in recent events section but they are visible in user's profile.