SOLVED

Automatically publishing News Articles based on Microsoft Flow Approvals

Copper Contributor

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. approval.png

     

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.

   

promotedstates.png

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!

7 Replies
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?
best response confirmed by Evert Eckhardt (Copper Contributor)
Solution
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.
I’m very much looking forward to OOTB publishing being implemented in the modern experience of SharePoint.

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!

Bummer. I thought that you could do that by now :(. Guess I heard it was being worked on too and thought it had been released.

If you have Content Approval turned on in the Sites Pages library and the page author submits for approval. Flow can set the approval status to Approve which will publish it.

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/

1 best response

Accepted Solutions
best response confirmed by Evert Eckhardt (Copper Contributor)
Solution
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.

View solution in original post