Forum Discussion
Powershell Script to list ALL videos in your 365 Stream environment
- Oct 22, 2022
Anyone looking at this script should also look at the PowerShell script that was released by Microsoft as part of the Stream (Classic) migration tools. The PowerShell script released by Microsoft can be downloaded directly from Stream (Classic) admin page and also has a PowerBI Desktop template that can be used to analyze the output CSVs.
See this part of the migration help articles for more info:
https://learn.microsoft.com/stream/streamnew/migration-details#stream-classic-video-report
Dorje-McKinnon Thanks for this script. My colleague Conrad has been using it a number of times. He asked me to improve this idea to avoid the copy/paste pieces. So I spent half a day and came up with https://neroblanco.co.uk/2022/02/get-list-of-videos-from-microsoft-stream/ It basically does the same thing as what you're doing but uses a scraping technique to get the date center and access token, so then it can loop through the videos without interaction!
Thanks again!
- Dorje-McKinnonOct 12, 2022Iron Contributor
Hi Twan van Beers ,thanks so much for your comment and blog post. Thanks also to ConradMurray for prompting you to work on this problem. I've just updated the code at the top of this script to a slight variation on your code, to give me the detail I needed.
- ScoutmanPtFeb 02, 2022Copper ContributorHi Twan, thanks for mentioning @Dorje and me on your blog entry . Just a quick correction: "MS must have removed the JSON object from their pages" that's not actually true or else the script would never work. The problem is that the page cycle order changed in the old stream portal, there's no validation on the session info which was why the script failed in some of the tenants. Im updating https://bit.ly/PnPScriptSamplesMSStream sample on the pnp repo, but I was wondering if you would like to do it, instead of me 😛 ? PnP Script Samples (https://pnp.github.io/script-samples/) is a community drive open source project and we are always keen to have more contributions.
- Twan van BeersFeb 02, 2022Copper ContributorHi ScoutmanPt
The error in the console was object JSON is undefined, and when I try to execute console commands in the debugger that object JSON definitely doesn't exist at all.
I'm ok to update it, just didn't want to replace someone else's work 🙂- ScoutmanPtFeb 02, 2022Copper ContributorTwan van Beers, "sharing is caring" is the key , right now the world owns the code ! 😛 . Rang me if you need any help on don't it ... Have a couple of other scripts coming in and if you wanna test drive them before they come public , that could be awesome. Thanks again for reaching out.