title: How to track online and offline app usage duration on Firebase?
body: <p>I already have a service that sends how much time by minutes a user was online or offline every 15 mins and only after the state has changed from the previous one (online to offline or vice versa). So, basically, I can see the minutes count as a value when selecting a parameter, for example, ONLINE_TIME (in screenshot called TIME), and see events in the last 30 mins with values of how much time the user was online by minutes.<a href="https://i.stack.imgur.com/EL5b1.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EL5b1.png" alt="enter image description here" /></a></p>
  <p>My main goal is to see in Firebase, how much percent time of the day users was online and offline. Any ideas on how could I achieve this? Thanks.</p>