

Side Note: Teams PSTN calls also appear in the sessions. Each session will contain the User from where the session came from, StartTime (UTC), EndTime (UTC), To/From URI, To/From TelNumber (which is masked), To/From ClientVersion, ReferredBy and DialogID (unique to that session).

Once all sessions are retrieved, it will output to a specified CSV file or to GridView. Likewise, if any timeout errors are noticed it will create a new session and carry on from where it left off. If the PowerShell session to Skype Online reaches 45 minutes, it will disconnect, reconnect and carry on from where it left off (if you provide the PSCredential using -Credential it will do this without prompting again). With that list, it will go through each user and retrieve all their sessions that were completed within the set time frame. The default behaviour is to connect to Skype Online and retrieve all Skype-enabled users in Skype Online - this can be hybrid or 100% ‘Pure’ cloud users. This script is based on the Skype Online Connector module (so will need to be installed to run this) and more specifically our old friend Get-CSUserSession cmdlet.
#Skype online member search code#
I’m sure there might be a more elegant way to code this! If my script is doing something terrible or there is a better way to do it, please let me know. Introducing Get-CSSessionsįirstly I’d like to say outside of a couple oneliner’s I’ve never written in PowerShell before.
#Skype online member search how to#
It didn’t tick all the boxes but looking at the code did help me with how to deal with expiring sessions and a recursive search of sessions. The closest I came was with Microsoft employee Jason Shave’s excellent CxdCallData. Whilst there are some scripts out there, nothing did what I wanted. Remove sessions I don’t need - Incomplete sessions, RegisterEvent etc.Specify a particular ToURI/FromURI to search for.Specify a start and end time and gather ALL sessions in that timeframe, not just the first 1000 sessions.Search through all users, (this includes Call Queue ‘users’) and retrieve each of their session details automatically.Rather than reinventing the wheel, I looked to see if anyway had what I was after: Can you tell me which user was sending IMs to X on Y date?.How many calls did we receive for call queue X yesterday?.Can you tell me how many calls each user has made/received over a period of time? Again, we can use the above tools against each user, but in large numbers, this could take some time.If you have 5000 users you can see how this could take some time. Can you tell me who called X number on Y date? Maybe someone has lodged a complaint and you need to investigate who made the call to that person’s number? Maybe someone is making calls they shouldn’t? Using the above tools, if you have 5 users this won’t be too bad to track down.Whilst these tools are great for looking at a particular user or trend, I struggle to use them to answer some of the questions I get asked. One big drawback is it will only ever get the first 1000 sessions, so if there are more than 1000 sessions between the start and end time, you don’t get all sessions. You can specify a user, start time and end time and it will retrieve the sessions. This returns the same dataset as the reports above. Get-CSUserSession - Part of the Skype Online Connector module. Reports are very similar to Call Analytics. Session Details - This is accessed from the Skype Admin Centre. This is similar to the data we can glean from on-premises SSRS reports.Ĭall Quality Dashboard - Again, great for looking at overall trends or metrics of call quality to pinpoint issues. For Skype Online there are various tools to report on user sessions:Ĭall Analytics - This is great for looking at a user’s call history when diagnosing call issues.
