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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Getting new page url f...
Power Automate
Suggested Answer

Getting new page url from "Send an HTTP request to SharePoint" News page creation

(1) ShareShare
ReportReport
Posted on by 4
We are working on a flow where a form submission after an approval gets automatically posted to the News section of one of our SharePoint sites. I've already successfully worked out how to create and publish the page, but my issue lies in getting the correct URL to email to the submitter.
 
My 4 steps for initializing and publishing the News Article Post are as below:
 
 
body.d.Id pulls the page ID from the initial HTTP request, however that's sequential for all posts within pages. I know the article saves based on the title in the SavePageAsDraft JSON Payload but if it's a replicated title you end up with (1), (2), etc appended to the .aspx page.
 
I notice on the raw outputs of the first request it has an absolute url but that has a placeholder page name that gets overwritten by the draft save. Is there a way to pull the absolute url after using SavePageAsDraft or Publish?
 
Attachment of screenshot as required by power platform.
Categories:
I have the same question (0)
  • Suggested answer
    Expiscornovus Profile Picture
    33,194 Most Valuable Professional on at
    It looks like the SavePageAsDraft and Publish methods don't return the Url. You could use a new Get request after the publish action. With a $select query parameter you can specifically retrieve the AbsoluteUrl.
     
    Try something like the below example
     
    URI
    _api/sitepages/pages(@{outputs('Send_an_HTTP_request_to_SharePoint')?['body']['d']['Id']})?$select=AbsoluteUrl
     
    Headers
    {
      "Accept": "application/json;odata=nometadata",
      "Content-Type": "application/json;odata=nometadata"
    }
     
  • t.sheehy Profile Picture
    4 on at
    UPDATE: Disregard, I had the new module pointed at the wrong sharepoint site

    -----
    Unfortunately I get this error:
     
    {"odata.error":{"code":"-1, Microsoft.SharePoint.Client.ClientServiceException","message":{"lang":"en-US","value":"Item does not exist. It may have been deleted by another user."}}}

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 503 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 321 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard