Embedding Stream videos outside Office environment

%3CLINGO-SUB%20id%3D%22lingo-sub-3209988%22%20slang%3D%22en-US%22%3EEmbedding%20Stream%20videos%20outside%20Office%20environment%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3209988%22%20slang%3D%22en-US%22%3E%3CP%3EIn%20Stream%20(Classic)%2C%20users%20have%20the%20ability%20to%20generate%20embed%20(iframe)%20code.%20This%20enables%20users%20to%20embed%20the%20videos%20in%20environments%20outside%20the%20Office%20suite%20-%20such%20as%20in%20blogs%20and%20web%20sites.%20As%20an%20HE%20institution%2C%20we%20encourage%20our%20instructors%20to%20use%20this%20feature%20to%20embed%20the%20videos%20in%20their%20online%20courses.%20This%20is%20so%20students%20do%20not%20need%20to%20leave%20the%20LMS%20environment%20to%20view%20the%20videos.%20Has%20anyone%20seen%20whether%20or%20not%20an%20embed%20feature%20will%20be%20added%20to%20SharePoint%20and%20OneDrive%20for%20Business%20to%20replace%20the%20feature%20as%20it%20exists%20currently%20in%20Stream%20(Classic)%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

In Stream (Classic), users have the ability to generate embed (iframe) code. This enables users to embed the videos in environments outside the Office suite - such as in blogs and web sites. As an HE institution, we encourage our instructors to use this feature to embed the videos in their online courses. This is so students do not need to leave the LMS environment to view the videos. Has anyone seen whether or not an embed feature will be added to SharePoint and OneDrive for Business to replace the feature as it exists currently in Stream (Classic)?

2 Replies
We are working on rebuilding this feature for videos on SharePoint and OneDrive. It's not on the roadmap with a date yet but it's in progress.

That being said you can embed a video today using the embed.aspx URL. It will only work if you construct the URL or grab it with an API, and it doesn't automatically login or offer a sign in button if the user doesn't already have floating auth/cookies from M365 in the browser.

But here is a way to construct the embed.aspx URL using a custom doc library view formatting:
https://github.com/pnp/List-Formatting/tree/master/view-samples/get-video-file-embed-code

Or this API:
https://docs.microsoft.com/en-us/graph/api/driveitem-preview?view=graph-rest-1.0

@Marc MrozMany thanks. Everyone here will be relieved to know this is in the works!