How to check users that have logged in?

53 views
Skip to first unread message

Beloit Manager

unread,
Jun 17, 2011, 3:53:47 PM6/17/11
to google-app...@googlegroups.com
 Google API experts,
  We want to run a report of all users that have logged in or not logged in, what is the easiest way to do this?  We have found the agreedToTerms attrtribute in the users.entry download, but we don't see any values for any of them.  So we are not sure that we can use that or must use something else.  We are trying to do this using the Python API's.  Can someone give us advice?
  Tim

Alexandre Jacquet

unread,
Jun 17, 2011, 3:57:59 PM6/17/11
to google-app...@googlegroups.com
Hello Beloit,

I think best way is using Report API, there you can get the firstLogin and the lastLogin, instead of validating the hasAgreedToTerms attribute, 


date, account_id, account_name, status, quota_in_mb, 
    usage_in_bytes, primary_account_id, primary_account_name, creation_date, 
    last_login_date, last_web_mail_date, surname, given_name,
    service_tier, channel, suspension_reason, last_pop_date, creation_time,
    last_login_time, last_web_mail_time, last_pop_time

20060808, 000000aaaaa11111, "ab...@example.com", "ACTIVE", 10240, 
    9235, , , 20060802, 19691231, 20060802, , "Abuse", 0, , , 20060802,
    2006-08-02 17:22:15, 1969-12-31 16:00:00, 2006-08-02 17:22:15, 2006-08-02


                                                                                           

Alexandre Jacquet

Google Apps Deployment Specialst 
São Paulo | SP | Brasil
Tel.: 55 11 8064 6882






--
You received this message because you are subscribed to the Google Groups "Google Apps Domain Information and Management APIs" group.
To view this discussion on the web visit https://groups.google.com/d/msg/google-apps-mgmt-apis/-/WgHpIq9F9YIJ.
To post to this group, send email to google-app...@googlegroups.com.
To unsubscribe from this group, send email to google-apps-mgmt...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-apps-mgmt-apis?hl=en.

NCCFred

unread,
Jun 17, 2011, 4:07:21 PM6/17/11
to google-app...@googlegroups.com
Hello,
 
Using the Reporting API, I check to see if the last_login_date = '19691231', if it does then the user never accessed the account via the web interface.
 
Hope this helps.
 
Fred

Beloit Manager

unread,
Jun 20, 2011, 12:41:55 PM6/20/11
to google-app...@googlegroups.com
Okay, How do I get the created_date attribute from the report? I am trying to create an automated python script to check if any of the accounts are not logged in. I guess I am kind of looking for a similar approach as the

if user_entry.report.created_date == '19691231:
    #never logged in

I looked around for some python documentation but did not have any success.

-DN

Reply all
Reply to author
Forward
0 new messages