matomo-org / matomo-sdk-android

SDK for Android to measure your apps with Matomo. Works on Android phones, tablets, Fire TV sticks, and more!
BSD 3-Clause "New" or "Revised" License
388 stars 162 forks source link

Matomo analytics not showing data on admin panel in android #270

Closed AbhijeetDandiwal closed 4 years ago

AbhijeetDandiwal commented 4 years ago

Hello Team,

We are working on Matomo analytics integration in android application. Below is the sdk we have used :- a. ) implementation group: 'org.matomo.sdk', name: 'tracker', version: '4.1.0'

And we used below code :- MainActivity.java

Tracker tracker = ((MatomoApplication) getApplication()).getTracker(); TrackHelper.track().screen("/java/com.example.matomo/MainActivity").title("Yipee").with(tracker); TrackHelper.track().goal(2).with(tracker); TrackHelper.track().download().with(tracker);


App.Java In public class App extends MatomoApplication{ @Override public TrackerBuilder onCreateTrackerConfig() { return TrackerBuilder.createDefault("https://******.com/matomo/index.php?", 2); } }


In Menifest added below line: android:name=".App"


After doing so, we are unable to track user activities. Please help us ASAP.

Thanks & Regards, Abhijeet Singh.

Ponsen commented 4 years ago

Hi,

I'm having a similar issue. I've updated from piwik 2.X to Matomo 4.1.0 and couldn't see any entries in matomo backend (3.13.0). Android Studio Profiler shows the requests are working with reponse code 200 but nothing in the backend. I've just tested downgrading to piwik 3.0.3 and it's working again. During the tests with 4.1.0 i've activated the matomo logs, but it wasn't loggin any 4.1.0 requests.

Any suggestions?

d4rken commented 4 years ago

Have you checked the v3 -> v4 hints?

https://github.com/matomo-org/matomo-sdk-android/wiki/Migration#v30-to-v40

I think you most likely need to correct the URL, and append either piwik.php or matomo.php which was previously done by the SDK.

Ponsen commented 4 years ago

I must have missed that. It's working now. Thank you very much.