How to determine what device was used for login in post-login action

Is there an easy way to determine what type of device was used within the event or api object in a post-login action? A couple of use cases would be to:

  1. Add that device info to an analytics login event
  2. Count the number of user logins on desktop vs mobile for a web app.

The only field that I see that might work would be the event.request.user_agent but I’m not sure how consistent that is and looks like that would require some string parsing to determine mobile vs desktop. I’ve also seen isMobile present in the log details but haven’t seen any way in accessing those via an Action.

Hello @ryan.liszewski welcome to the community!

I’m unfortunately not seeing much either outside of user_agent like you mentioned - This could be a good candidate for a feedback request if you’d like.

Outside of the context of an Action, Log Streams might be something of interest in terms of gathering analytics.