Custom events in Firebase - firebase

I know this has been discussed a lot on SO, but even based on the previous questions and answers I still can't quite understand the details of how event logging is really supposed to work in Firebase.
Let's say somewhere in my code I have this:
FirebaseAnalytics mFirebaseAnalytics = FirebaseAnalytics.getInstance(this);
Bundle bundle = new Bundle();
bundle.putInt("card_id", 912);
mFirebaseAnalytics.logEvent("card_open", bundle);
Do I understand correctly that the "card open" even should now appear in Firebase Console with the "card_id" parameter?
Then I click More > Edit parameter reporting, enter the name of the parameter I added in my code, and it should appear on the list.
I have read the docs several times, but I still can't get it. Can I not even use any of the events and parameters provided by FirebaseAnalytics.Param and FirebaseAnalytics.Event and just send custom events/parameters (within the known limits, of course).
Another question is whether the limit on the number of global parameters force you to use Big Query?
Thank you!

You're correct. You should see the card_open event with card_id parameter in the analytics console.
Note that there's a delay in the analytics reporting, about 4 to 6 hours after it was logged and uploaded by the device.
Just to ensure that your implementation is correct. I mean, to verify that the events, parameters and user properties are logged in the right time and the right place correctly, use the DebugView console.
I also believe that you should be able see the card_id parameter in the custom reporting for card_open event, considering the delay in the reporting.
For your last question, the parameter limit is on a project level perspective now, compared before that it was per app. Parameters with the same name across different apps will be counted as 1. Not sure, maybe Firebase would like us (developers) to use the parameters accordingly.

Related

Using event as view exclude filter in Google Analytics

I have an event that triggers from my tag manager every time someone clicks a certain URL link. This event appears to be tracking properly in GA. However, I am attempting to create a filtered view that excludes traffic that triggers this event. When I use the Filter Verification I get:
"This filter would not have changed your data. Either the filter configuration is incorrect, or the set of sampled data is too small."
Indeed it does not change my data. I am using the event label as the field field/pattern if that makes a difference. Any suggestions?
Ok, there are issues with this question. But first, the answer is: filters aren't meant to remove more than particular hits. They aren't meant to remove sessions or users. Only hits. But there's a hackaround.
Now, more points:
You don't exclude "traffic". Traffic is not precise enough to be useful here. You have to decide what you want to exclude: an event, a session or a user. Or something inbetween, but then you need to define it properly.
A session in Google's understanding is really a bit different from what it seems like. It is custom to believe that a session is a series of interactional events with less than 30 minutes (configurable) inbetween. Not quite. If your source changes, that's a new session. Bear with me.
You... can hack around it if you really need to. By "painting" users or sessions. You do it by setting a specific custom dimension (user- or session-level) and then delete all events that have that custom dimension set using a view filter. The CD will be backfilled, so the filter should clean stuff close to how you expect it to do.
However! GA is... a little bit odd with how they record sessions and users. There may occur a situation when you end up having users or sessions with no events in them. However, if you find this issue at play, you still can export the data to BQ and query it properly. You may find that export cleaner.

Metrics and dimensions are not showing up for hits of type 'event'

I have a fully functional and working code (written in C#) which purpose is to track some hits to the specified GA property. This code has been tested and still works successfully. It adds some predefined dimensions (like App Version) to each hit and a several custom metrics to a certain hit types (like event with a certain Event Action).
So far so good everything works flawlessly when taking into account the first property to which these hits are being sent. Also everything is fine when I set up a brand new GA property and track my hits to it - that is, I'm able to see events in Realtime reports, and events show up in custom reports after a while so that I can see my custom metrics.
The issue is that when I try to send absolutely the same hits to the existing property which had been created and configured ages ago - there is no both dimensions (even predefined) and custom metrics in my custom reports. I see these events in realtime and behavior reports, and I'm even able to create a custom report against events count - but that's it. I'm able to use for example Day of the month as a primary dimension, but when I try to use App Version as a dimension or my custom metrics as report metrics - it says "There is no data for this view.".
I've already tried everything I could, have read almost every post about custom definitions in Google and viewed almost each related SO question and answer - still with no luck.
We use measurement protocol
There is a correct User Agent being sent with each hit
17 days has passed since my first attempt to track these hits with existing property
There is no filters and segments at all
There is only one view
For me it looks like a property misconfiguration, but I've inspected each configuration page (I have all possible rights granted) and have not found anything related.
Will appreciate any help with this issue.
UPD: The hit itself (with the sensitive data replaced):
t=event&ec=session&ea=connection_end&el=b225d53a-6bb2-8021-f7b5-ae7004ae0a00&cm1=174960&cm2=1751494&cm3=479033&tid=UA-XXXXXXX-X&cid=4119e77f-be87-4530-04d3-33882f8eea77&v=1&av=XX.XX.99.555&an=my-awesome-app&aid=app.awesome.my
UPD: Here is what I'm trying to achieve (screenshot was made at the test property, where everything works like a charm):

Firebase Analytics Custom Event Parameter Reporting has (not set)

So we've integrated Firebase Analytics and Crashlytics with our mobile app (both Android and iOS) and it works. Well it sort of works. So we don't have any problems with crashlytics but we have an issue with how our custom events are being reported.
If you see the picture above, we have a huge amount of (not set) being recorded. We aren't sending anything custom that isn't being recorded (meaning the big blue box there is all we chose to record) yet we still get (not set) being reported. Is there a way to know what this is or how to remove it? I thought at first it would be firebase_event_origin or something similar to that but it isn't as the numbers still keep increasing after we added the said property in parameter reporting.
This is what my parameter reporting looks like for the first image:
For sending data to firebase analytics we just did what was outlined in the docs like:
Bundle params = new Bundle();
params.putString("image_name", name);
params.putString("full_text", text);
mFirebaseAnalytics.logEvent("share_image", params);
I know this questions is opened 2,5 years ago, but still if someone else needs info about this issue...
According to other people experiencing the same issue, including myself. It's most likely the value for a custom dimension you set, is not in use anymore (a previously event parameter). Although, there are multiple reasons this could happen.
Take a look at this case, likely the cause is listed somewhere here.

Firebase Analytics, Are prescribed event parameters also counted as custom parameters?

I'm setting up Firebase analytics for my app for both android and ios. I just learned that there's a 50 custom parameters limit I can create, also learned there are prescribed event parameters that firebase suggests with recommended events.
My question is, are these prescribed parameters counted as custom parameters when used?
My guess is yes, but I want to be clear before I actually start coding and possibly mess up with the number of parameters.
By "custom parameters" do you mean custom parameters in event? If that's the case then limit is 25 per event.
Maybe you thought about custom parameters in reporting? Then the limit is indeed 50, but it is only for reporting.
If you ask about user properties then the limit is 25 per app and no - predefined/default user properties don't count, so you can add 25 user properties yourself.
As a general rule - usually default stuff doesn't count for limits.
For more info on up-to-date limits see here: https://support.google.com/firebase/answer/9237506

How to delete an Analytics Event from Firebase

How can I delete an Analytics Event from Firebase?
While I am testing I wrote some events in Firebase Analytics. Firebase by default orders all events alphabetically. So these testing events interrupts with original events.
I could arrange them by count to push all the testing events to last. But it makes difficult to find the main events since those are not alphabetically sorted.
I didn't find any options in Firebase dashboard to delete a event. Is there a way to delete the old events from firebase?
There is currently no way to delete events once they are logged into Firebase Analytics that I am aware of. However, the events will drift out of the default view (which is set to "last 30 days") as time goes on, or you can switch the time period to a shorter time. As you mentioned, you can also click a column header to sort by some other value or "add filter" to filter by an audience or user property.
You can create a new Firebase project if you want to start from scratch. It's also a fairly common practice to use one project for experimentation and validation of your analytics implementation and then to switch to your production Firebase project when everything looks good.
It is not possible to delete analytics events AFAIK, but on some views you can set up the time interval with the filter at the right-top corner to limit the listed events. In the audience set up you need to rely on typing, I am afraid.
As of 31 May 2018, there is an API for this. Doesn't delete individual events, but you should be able to use it to delete all the events collected by a particular app instance:
User Deletion API v3 (UserDeletion.userDeletionRequest)
It was introduced in this blog post and the intended purpose (user privacy) is described here (last paragraph).
Unfortunately, based on my own question, no one seems to have figured out how to get it to work :(
EDIT
Turns out that, according to Google, this API does delete events (which technically is what the OP was asking), but since the aggregate total remains visible on the Firebase console, it won't help with the OP's specific use case.
As Steve Ganem suggested the simplest thing you can do to reset the Firebase Analytics data is to register new Firebase project and that in your app. You can also keep the old project around for debugging/development.

Resources