Forum Discussion

Alan Marshall's avatar
Alan Marshall
Steel Contributor
May 09, 2018

Do more with Flow Send an HTTP Request to SharePoint and Site Designs

I've been using Site Designs and Scripts to provision SharePoint sites with pre-set document libraries, lists and themes but there are still lots of provisioning things that are missing to create a complete site template.

This is where "Send an HTTP Request to SharePoint" Flow action comes in. 

As part of the Site Script, I can call a Flow to complete further actions including calling out to some PnP code in Azure.  In this Flow, I can now use this new action to call any SharePoint API request; my first experiment was with creating a Folder in the base document library which worked great.

Next steps are to see if adding content types and other typical configurations work.  And then I need to ask myself if I should do this in Flow or custom code.

5 Replies

  • Balmeter's avatar
    Balmeter
    Copper Contributor

    Hi Alan Marshall ,

     

    Were you able to figure out how to add content types to a list or library with this method?  I am trying to figure that out now.

     

    VR,

    Brian 

    • Nabeel Salie's avatar
      Nabeel Salie
      Copper Contributor

       

      For getting the output, I've used the following with a variable

      body('Get_Item_Content_Type')['d']['ContentTypeId']

       

      "Get_Item_Content_Type"

      This is the name of the action "Send HTTP Request..."

    • Περικλής Δράμπης's avatar
      Περικλής Δράμπης
      Brass Contributor
      I added a request to retrieve items from a list. Then as a next step I added data operation "Parse JSON" where I provided a sample json response to create the schema and then I was able to add a "Apply to each" to do some business logic. Not sure if there was a better way.