Gc users list CLI flag --expand lastLoginDate returning incorrect date

I have opened a support ticket for this issue and they suggested I post here as well. Using version 50.0.0 of the CLI, if I include the --expand lastLoginDate in a gc users list command, I get an odd date for users. I see some dates in 2020, but primarily I get this:

"dateLastLogin": "0000-12-30T00:00:00Z"

Is there an issue returning the last login date with the gc users list command?

Data returned by the API is not something that can be investigated via the forum; we have no access to any org's data to investigate. Care is the correct (and only) avenue to investigate data in your org.

Thanks Tim. Just curious though, if you execute the gc user list --expand lastLoginDate command against your ID on an org, do you get the correct last login date back?

When working with Care, please reference PLUS-467.

Care came back with the recommendation to use "lasttokenissued", instead of "dateLastLogin". The dateLastLogin field is only updated opportunistically, so it’s possible in the event of this field not being updated to come across the date β€˜0000-12-30T00:00:00Z’.

Using lastokenissued seems to provide the result I am looking for.

2 Likes