Forum Discussion

williamdw's avatar
williamdw
Copper Contributor
Feb 24, 2022

Embedding Stream videos outside Office environment

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)?

  • marcobus's avatar
    marcobus
    Copper Contributor
    I assume those environments use oembed functionality from stream classic to retreive the iframe code. For other services sometimes the preview URL can be derived from the original. In this case we need the meta data UniqueId, assuming this is the driveItem id, or from an object representing the share related to the driveItem. Just adding this since I havn't seen this mentioned in detail. Hopefully this is addressed in the ticket Baardaap has initiated?
    • Baardaap's avatar
      Baardaap
      Copper Contributor

      marcobus don't know if I understood you correctly but I don't think this is mentioned in my ticket as my issue with the placement of the cookies for authentication on sharepoint that can't happen trough the Iframe. Once a user has authenticated on sharepoint the issue is gone but since we dont use sharepoint the user is unlikely to have these cookies in place.

       

      In any case my ticket has been put on ice as the issue now lays with 'the product team'. 

      I have given up on the issue or a solution for it as support was worse than terrible... Seems the hostingprovider will do an update soon that will allow embedding so that should solve it for me.

      • karen_dredske's avatar
        karen_dredske
        Steel Contributor
        Baardaap I think you will find that the product team will be more helpful than general support was. They have been very responsive to people who have joined the office hours they hold. You can sign up for those and talk to the team directly at https://aka.ms/StreamConnect.
  • Baardaap's avatar
    Baardaap
    Copper Contributor
    I have a ticket for this with microsoft, the responsetime is rediculous so I'm still waiting on a reply.
    I have send them a video of the issue showing the issue is with the cookies not being placed.
    I will post back here once I finaly do have a reply.
    • Ron's avatar
      Ron
      Copper Contributor
      Baardaap I too have an open ticket with MS and I am also having a horrible response. My ticket has been open since 1/6/23. I too have sent videos and even had a screen sharing session. They have not been able to figure out what is wrong or atleast have not told me anything. At one point they even tried to close the ticket. I would not let them do that. I also have sent them the link to this forum so they are aware it's more than one person having issue.
      • Baardaap's avatar
        Baardaap
        Copper Contributor

        Ron I just had a call with them after a week waiting since I send the video and their response is that they will not allow this kind of embedding trough sharepoint due to security reasons and that I should accept this as a solution. I have asked them to send me this in a witten response so I can maybe escalate the issue to our microsoft contact.

        I did not yet receive the witten response (which i will copy here).

         

        Any questions I had they did not want to or could not answer... Like why will we get a 'new' stream with less functionality.

  • Rae_Jay's avatar
    Rae_Jay
    Iron Contributor

    We are experiencing this issue with embedding videos in Canvas - our learning management system. This means that we cannot use Stream on SharePoint for learning and teaching videos... such a shame as the acccessibility features are really quite good.

    • williamdw's avatar
      williamdw
      Copper Contributor

      We're also working with videos in a Canvas environment. Looks like you may need to set permissions in SharePoint so that users can view the video. The iframe (embed) code directs users to the location of the video but does not contain permissions for viewing it. These have to be set in SharePoint. So basically this is a two-pronged process: (1) grant viewing permissions in SharePoint to a specific individual or group and then (2) generate the embed code and add that to a Canvas page. Now those with permission will be able to view the video. All others will be told that they do not have access.

       

      Here's a good tutorial that someone posted to another Stream on SharePoint discussion:


      https://youtu.be/5B13u_-N0zI

      • Rae_Jay's avatar
        Rae_Jay
        Iron Contributor
        Thanks williamdw I have seen that video and the critical step is sharing to the Group "everyone except external users". We have that group disabled here for security reasons so I think that means we cannot embed the videos successfully.
  • Ron's avatar
    Ron
    Copper Contributor
    Have there been any updates on this? We are trying to embed videos into our external LMS via Stream (Sharepoint) and iframes with no luck. The users gets a flashing login screen but never gets the video. The LMS has SSO via O365. So, you would think the authentication would have already taken place. The strange thing is, if the users goes to the sharepoint document library where the files are store he can see the files. Now he can go back and the video works. What are we missing? We are not using any shared links. The user is in the Sharepoints site visitor group which has read access to the whole site, including all the files.
    • Baardaap's avatar
      Baardaap
      Copper Contributor
      We seem to have the same issue here.
      In the classic stream embedding to our '3rd party intranet' works fine but trough Stream on Sharepoint we get the same flashing screen.

      Now I'm no expert on webservers and stuff but I did some research and noticed the cookies for stream classic are being placed when there's embedded video on the page, when I embed trough stream on sharepoint the cookies aren't being placed.
      Apparently there is a samesite cookie setting in sharepoint online that is not set to allow cookies to be placed when it's a third party webpage.

      As it's in sharepoint online I don't think we're able to change these cookie settings.
      I have opened a supportcase with Microsoft last week but did not yet get a response.

      For now having people visiting the sharepoint before opening it through an iFrame will give a workaround as the cookies will then be placed.
    • KCormier's avatar
      KCormier
      Copper Contributor
      williamdw , just wondering if you found a resolution for the flashing login screen issue? Our college is experiencing the same thing with Embed code url's for our Sharepoint/Stream videos in our Brightspace LMS. If the user chooses to copy the link and has it open in the LMS in a new window, it works fine. Just the embed code that's giving the flashing login screen error. Any ideas?
      • Ron's avatar
        Ron
        Copper Contributor

        KCormier no I have not. I do have an open Support ticket with Microsoft. They are asking for more information and I have not gotten back to them. I am on vacation this week. The info they asked for makes me think they have no idea (try another computer or network). I will let you know if we figure anything out or get any info from Microsoft.

      • Ron's avatar
        Ron
        Copper Contributor

        KevinCrossman  Yes that is where were are getting the iFrame code to use in the LMS. 

  • 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
    • katyg9551's avatar
      katyg9551
      Copper Contributor
      quick question: why did Microsoft create this "new" version of Stream that is exponentially less intuitive, less useful, and doesn't have any of the features of stream classic? Almost daily tasks I used to complete in Classic Stream are now either impossible because the features I used all the time are gone, or it takes me three times longer to complete. New Stream is awful. Absolutely terrible. And now it won't allow me to even go back to Classic to complete my work. It forces me into Stream on SharePoint. Ugh.
      • karen_dredske's avatar
        karen_dredske
        Steel Contributor

        katyg9551 although I may not be Marc Mroz, I did a presentation on this topic back in December. I would be interested in what daily tasks you are doing that have become difficult. It DOES take a new mindset on how to manage files to get comfortable with this, but once you are able to make the paradigm shift in thinking, you find that it really is the same or better - and it keeps getting better all the time. I know I was just preparing a demo to use tomorrow on using the new Stream and I had a lot of fun with the new recording features that are available that we did not have previously in the classic version. 

         

        I did a talk on how to create a Stream portal on SharePoint, but session hasn't been posted yet or I would point you in that direction. In the meantime. . . maybe there is something I can help you with that would make things smoother for you? Once you understand how things work in SharePoint, I think it will not seem so difficult and you will start to find improvements over classic Stream. 

Resources