web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Help with getWOPIFrame...
Power Automate
Answered

Help with getWOPIFrameUrl to bring embed path to file

(0) ShareShare
ReportReport
Posted on by 8

Hello everyone!

 

I need some help to bring some data to my flow.

I'm trying to embed a file in a modern Site Page webpart. By this I need to setup a link using the embed path to the file (WOPIUrl). The desired output needs to be like this: https://[companydomain]/sites/[sitename]/[subsitename]/_layouts/15/Doc.aspx?sourcedoc=%7BC7B5C73A-60D7-47EF-8092-A1B7015A63D5%7D&file=[filename]&action=embedview&mobileredirect=true

 

I setup a Send HTTP Request to Sharepoint using this config:

  • Site Adress: https://[companydomain]/sites/[sitename]/[subsitename]
  • Method: POST
  • Uri: _api/web/lists('edd46fd0-b8c8-448f-9b10-862d482ff58d')/items('12345')/getWOPIFrameUrl()
  • Headers and body empty

(Sorry, I cannot upload images in any site due to my company TI policies)

 

The output I get is like this: https://[companydomain]/sites/[sitename]/[subsitename]/_layouts/15/Doc.aspx?sourcedoc={486371b6-ae8f-4cbf-81c4-7b3793a16d82}&action=view

 

The ID is incorrect (I tested it inside de wopiUrl in the webpart) and the action is different I want. I saw in this site there are some forms to setup the action parameter by don't realize how to do that.

 

Any idea?

(Sorry bad english)

Categories:
  • Verified answer
    rdinacio Profile Picture
    8 on at

    I realize I could change the action it using replace function. And the ID is equivalent.

    Can close this post!

  • alrezac Profile Picture
    Microsoft Employee on at

    Hi,

     

    It looks like you were able to figure out your issue here. I just wanted to jump in and add a little more information if you would like to learn more. Feel free to take a look.

     

    https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-replace-substitute

     

    Regards,

     

    Alex

     

    -------

     

    Community Support Team _ Alex Rezac
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 245 Super User 2026 Season 2

#2
11manish Profile Picture

11manish 233 Super User 2026 Season 2

#3
Valantis Profile Picture

Valantis 136 Super User 2026 Season 2

Last 30 days Overall leaderboard