Open cemo opened 6 years ago
What features would you like to see in a server-side analytics API? Client SDKs primarily support logging analytics events. I don't think there's a use case to support that server-side.
I would like to use firebase analytics as a marketing automation tool. My primary purpose is forwarding all events in our system to firebase and using its audience feature.
I want to do this in server side because it has major advantages.
I believe that it has great potential in server side as well.
Just to clarify, A user does something which you log on your server, you are looking for a way for the server to log the event as the user (would you be passing user specific event attributes? (e.g. user-agent)). is that it?
@avishalom the scenario you are describing is exactly valid. You can consider our server as an agent.
We have the same problem in cloud functions. The cloud function reacts to the client doing something and needs to log an event to analytics on behalf of that user. We don't want to give the client access to the data necessary to log such an event though.
It's the same use cases and motivate: https://developers.google.com/analytics/devguides/collection/protocol/v1/
This appears to be exactly what we need to send data from Firebase to BigQuery using Cloud Functions: From Firestore to BigQuery with Firebase Functions.
@avishalom I'm not able to track revenue because it's not bound to any user action on the client, it's actually an event by the negation of an action. It's not bound by a specific schedule either (it's not subscription model). The only way i could sort of maybe kind of do this is with silent push notifications that trigger a Firebase event, but this error prone. The only thing i can think of is using user properties to track accumulating revenue which will at least provide some context.
Any updates on this feature, or documentation on doing it ourselves (via REST API for example)? I'm rather surprised this isn't a use-case covered by the core library. In server-authoritative applications, there are many use-cases where analytics events are emitted by the server, and not available to the client. In order to have a complete data-set we need to be able to emit analytics events server-to-server.
Is there any solution here? Is there some way to use BigQuery perhaps?
Also interested in this. Any updates?
Please upvote issue as well
For what it's worth, I don't see this happening anytime soon. Google simply doesn't support server side analytics, firebase analytics is exclusively for apps.
Right now I've imported my data into bigquery and am working on adding server side integration with my bigquery table. With this, I should be able to use bq to query data and later use datastudio to display it. I found this video helpful: https://www.youtube.com/watch?v=Ki_F6VCOtXU
Is still there an option to add Firebase Analytics on the server side?
I'll add in that a SaaS analytics product that doesn't support a server-to-server flow today is extremely rare. Google's own "measurement protocol" for Google Analytics is widely adopted. And of course players like Adobe, Amplitude and Mixpanel support it. The value and use-cases for server-side APIs are well enumerated over hundreds of other tools.
That being said - opening up a server-to-server flow is more complicated than just documenting an API - since you have to support all of the "interesting" things folks will use it for. Supporting server data means that customers will try to send in web data, and offline data, and OTT data, etc. How do you accurately link up client-side and server-side identity?
By way of a guess - perhaps Google is in the process of combining GA and Firebase Analytics (frankly the branding is already getting conflated - they're calling it "Google Analytics for Firebase" as of this writing...), in which case it makes sense to hold off on releasing a true server-to-server flow. More conspiratorially, maybe they're deliberately limiting the use-cases for Firebase such that it's basically unusable for the enterprise businesses, who absolutely need a server-to-server flow, but who already are paying for GA 360.
Only time will tell! Either they'll come up with a solution or, in my opinion, Firebase will be relegated as a 2nd-tier analytics offering.
Hey, folks. I'll just chime in to say this is a feature request the Analytics team has certainly heard from customers, and it's something they're looking into, but as usual I can't share any specific plans or roadmap or anything.
Right now, probably your best option would be to import your analytics data from Google Analytics for Firebase into BigQuery and then combine that with any other data you might be generating server-side, kinda like what @namanyayg mentioned.
@ToddKerpelman This is great. I think that this API is already implemented for mobile devices. In order to send events by mobile devices there must be an API for this purpose. I feel that the API needs to be officially documented and publicly available for server side.
This is the only solution to implement subscription tracking since there is no automatic subscription tracking provided by firebase
Is there any update on this or a link to a custom solution? Ideally I want to be able to update user properties in firebase analytics from server side, so I can filter by them later when using other firebase services e.g. FCM
We also need this.
There is an important use case for games with IAP as any client-side information is going to be unreliable. Having the event logged in server-side make it a bit more reliable.
Many things happen server-side (e.g. events happening when the user is offline). Without such a simple feature, it's impossible to target the right users. This fact forces us think towards other solutions on the market :(
This is crucial for our solution as well. Please consider a fix ;-)
It is now possible to add an Analytics label to messages. Does that mean this FR can now be implemented?
@ToddKerpelman, Is there any update on this?
It is now possible to add an Analytics label to messages. Does that mean this FR can now be implemented?
Looks like it has some limitations. Do you recommend for general logging from Firebase functions?
@ToddKerpelman I consulting Firebase analytics with the clients and its common problem :/ I was thinking about solution and maybe create few standard events (or it will be a new type of standard events) which can have permission to connect with server-side. Two cases that I have in my mind are 1. mobile app with subscription model
Looks like there're server-side reporting already which is used to report appstore* events. They are not exported to BigQuery and do not have any standard properties (user_id, device, ...) comparing to any other events. Here is my SO question about it: https://stackoverflow.com/questions/58300435/app-store-subscription-events-are-not-exported-to-bigquery
Oh, you gotta be joking. There's in-app subscription events happening, which is related directly to client app, but can only be reliably detected on server side. Such as users being charged on monthly basis, trial periods, introductional periods, etc. So there is no way (apart from using a billion other tools) to directly send these events to Firebase? All analytics tools support this...
We also need this.
I am a little surprised that this also was not ported over from old analytics - absolutely need this for server side event logging out of things happening in the database into user lifecycles... For us especially it would also be crucial in order to get some events as conversions into ads...
Can anyone share what kind of workflow (alternatives) they have to handle this missing feature?
Is there any news on this?
Not a solution, but for a pseudo (UDP analytics version) alternative, I literally send silent push notifications (iOS) packaged with event data that is pushed back to firebase from the background using client SDK.
If this is a mobile first/product/foreground only philosophy, it can easily be abused. With the “merger” of GA/Firebase, this should theoretically be supported now, they would just be events from a different platform.
The only thing I can think that might be blocking this feature is internal firbebase ML predictions. Events not generated by an active session may pollute learning models.
Also, just generally, REST apis are usually the lowest priority items, because it’s cannibalising the services they are selling. We’re supposed to be using Firestore/cloud functions, not RDS.
On Mon, Jan 6, 2020 at 4:40 AM voxelbusters notifications@github.com wrote:
Can anyone share what kind of workflow (alternatives) they have to handle this missing feature?
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/firebase/firebase-admin-java/issues/137?email_source=notifications&email_token=AAAY6LDWP543IJD2B6ULVSLQ4MREZA5CNFSM4EPS53XKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIFKSZY#issuecomment-571124071, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAY6LGGLWAEDXZFQOYPDE3Q4MREZANCNFSM4EPS53XA .
Not a solution, but for a pseudo (UDP analytics version) alternative, I literally send silent push notifications (iOS) packaged with event data that is pushed back to firebase from the background using client SDK.
While the idea is nice, background notifications are "unreliable" at best in our (extensive) experience.
Even Apple says so in the docs - "The system treats background notifications as low-priority" (https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/pushing_background_updates_to_your_app)
Updates about this feature? This would be extremely helpful if you want gather all your analytics in one place.
Please, consider adding support for Firebase Analytics in the server
A pretty good work around here would be to have an intermediate Firebase cloud function that will route all the events to your data pipeline system like kafka or another rpc. This way you can get the event (append client side firebase token in your events list) on your backend and then trigger push notifications to that client.
Client sides analytics are being blocked more and more nowadays. All our users using Brave will simply block everything and Brave is one of the most used browsers in our business niche.
Same here, it's been a feature we've been looking for for years. Server side logging is more reliable and the server posseses info that you want to include in the logging that is not available on the client side.
We also need this
2 years later and google still ignores this need.
i have several payment gateways in order to process users purchases in my apps. i use firebase functions as backend to process payment status changes (ipn) once the payment is approved i would like very much to log an event of 'purchase'
the current analytics archtecture forces me to log a purchase in the client side, before it has been approved or create a frankenstein of services in order to push notification back to user and then log the event
Google Analytics is an integration. Firebase doesn't build or control the functionality. When server APIs become available for Analytics, they can be added to the SDKs. The feature request has been communicated (not ignored) and will be prioritized relative to other major feature work by the Analytics team. 2 years isn't a bad timeline for major feature development on platforms operating at scale.
My Environment:
Please provide Firebase analytics Api for server side. We would like to give a decision right now and being limited on client side is unfortunately not acceptable.