SOLVED

MSgraph signinactivity

Iron Contributor

Hello all

Im trying to get the "lastSignInDateTime" for a particular user using powershell. The below query works fine if i go to Graph Explorer - Microsoft Graph  I have already setup the delegation, just need to understand how to do the same thing in powershell 

 

3 Replies
I gave you a working example in the article/script I linked to in your other post...
All you need to do is authenticate, then issue the request. If using filters and such, make sure to 'escape' the $ character.
best response confirmed by Skipster311-1 (Iron Contributor)
Solution
I suppose using the Microsoft.Graph module might be the easiest option, if it supports what you need. You can switch to the beta profile using the Select-MgProfile cmdlet and then you do not have to worry about trying to do it manually.
Installing the graph powershell module was much easier.
1 best response

Accepted Solutions
best response confirmed by Skipster311-1 (Iron Contributor)
Solution
I suppose using the Microsoft.Graph module might be the easiest option, if it supports what you need. You can switch to the beta profile using the Select-MgProfile cmdlet and then you do not have to worry about trying to do it manually.

View solution in original post