GAM reporting on logins

170 views
Skip to first unread message

Mohamed Lrhazi

unread,
Jan 30, 2023, 2:35:41 PM1/30/23
to GAM for Google Workspace
Is there a way to pull all login events? successful or not.

<ActivityApplicationName> ::= access|accesstransparency| admin| calendar|calendars| chat| chrome| contextawareaccess| currents|gplus|google+| datastudio| domain| drive|doc|docs| gcp| groups|group| groupsenterprise|enterprisegroups| jamboard| keep| login|logins| meet|hangoutsmeet| mobile| rules| saml| token|tokens|oauthtoken| useraccounts

I tried pulling admin login and useraccounts, but none of them seems to have login events.

Thanks,
Mohamed.

Jay Lee

unread,
Jan 30, 2023, 2:36:58 PM1/30/23
to google-ap...@googlegroups.com
gam report login

Jay

--
You received this message because you are subscribed to the Google Groups "GAM for Google Workspace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/4b10d8f6-e0d9-44fb-95d7-e96f31e1d351n%40googlegroups.com.

Mohamed Lrhazi

unread,
Jan 30, 2023, 5:17:43 PM1/30/23
to GAM for Google Workspace
hmmm. Thanks! 

I have a script that runs every hour, and tried to pull the logs from the previous hour... turns out this never finds anty login events!!!!!
I guess I have to rethink my logic!

TIMESTAMP_PREV_HOUR=$(TZ=GMT date -d " 1 hour ago" "+%Y-%m-%dT%H:00:00Z")

gam report login start $TIMESTAMP_PREV_HOUR

I guess these login events are not realtime and "previous hour" always has none!


Thanks,
Mohamed.


Jay Lee

unread,
Jan 30, 2023, 5:24:28 PM1/30/23
to google-ap...@googlegroups.com
That's because it takes up to an hour or more for login events to show in the audit logs on Google's side (and yes, that's a sub-optimal experience:

https://support.google.com/a/answer/7061566?hl=en#:~:text=User%20log%20events,Tens%20of%20minutes

Note also that some events may come in out of order so you may need to look back up to 6 hours to make sure you are seeing all events for a time period.

Jay Lee


Ross Scroggs

unread,
Jan 30, 2023, 5:30:33 PM1/30/23
to google-ap...@googlegroups.com
These login events run behind by a few hours.

Ross



--
Reply all
Reply to author
Forward
0 new messages