Forum Discussion

Evert Eckhardt's avatar
Evert Eckhardt
Copper Contributor
Jan 29, 2018
Solved

Automatically publishing News Articles based on Microsoft Flow Approvals

Hi all, 

 

For our intranet we're trying to actively allow editors in our organization to post content such as news and blog articles. We're using the Modern Communication Site as a template.

 

The basic idea we had is as follows:

  1. Editors to write a page and save that page as a draft.
  2. When the draft is saved, catch the creation of a new item in Flow and trigger an Approval.
  3. The Editor-in-Chief checks the article, makes changes if needed and approves it. 
  4. Up on approval, we update the PromotedState of the draft to 2 (which is the Published state) to get it to show up as a news article. 
  5. Editor is notified that the article is published. 

     

The only hiccup we're experiencing right now is that the updating of the PromotedState via this method does not have the same effect as actually pressing the 'Publish' button on the Draft page, the page is still in Draft.

   

Does anyone know of a way to trigger the actual publishing based on this scenario, or is this not yet possible and will we need to do this manually? Thanks in advance!

  • Deleted's avatar
    Deleted
    Jan 29, 2018
    I know they are also working on approval process function for site pages/ news like in the old SharePoint that is coming, but I think you should still be able to use flow to do this. Curious if that works.

7 Replies

  • vo_quynh_chi's avatar
    vo_quynh_chi
    Copper Contributor

    Hi Evert Eckhardt, not sure if you have found the solution, but for the benefits of people searching for the same question and come to this post, you can publish the finished page using the Flow Action "Send a HTTP request to Sharepoint" with uri _api/sitepages/pages({id})/Publish
    For more detail, check out Step 7 of this post http://www.sites.se/2018/08/sharepoint-modern-pages-microsoft-flow/

  • The document gets checked out basically when it's in Draft, Checked in = published, maybe try throwing a step in there for checking in after the promoted state goes to 2?
    • Deleted's avatar
      Deleted
      I know they are also working on approval process function for site pages/ news like in the old SharePoint that is coming, but I think you should still be able to use flow to do this. Curious if that works.
      • Evert Eckhardt's avatar
        Evert Eckhardt
        Copper Contributor

        Hi Christopher, 

         

        It seems that there is currently no way to check in a file or page with Flow. It seems like the functionality is currently planned, but not available yet. Thanks for the response!

Resources