1

I have one project list in site collection and want to create a subsite when a new item is inserted in Project list. Is it possible using workflow?

Note: I am using Office365 account.

If this is not possible then please suggest me another way to do the same.

4 Answers 4

0

The action to create a new site isn't included in the actions available by default in SharePoint (Designer) workflows. It's possible to develop a custom workflow action to add this capability to the workflows in your site collection.

Technically this can be achieved by creating a sandbox solution which contains the custom action for SharePoint Designer, and activate this custom solution in your site collection

4
  • Hi massimo Prota, Thanx for the answer but I am using Online Office 365 Account so can't create Sandbox solution. Commented Jul 14, 2014 at 8:16
  • Dear Ashok, what you assert isn't true. Sandbox solutions are still supported in SharePoint Online (365). Sandbox solutions containing code are deprecated, but still a possibility. Commented Jul 14, 2014 at 8:21
  • This answer is false. With the REST API and an App step you can create new subsites with workflow. dmcinfo.com/latest-thinking/blog/id/8661/…
    – Dave
    Commented Sep 19, 2014 at 19:42
  • my first answer is false? Well I'd say it is partially: indeed there's no specific OOB action to create sub-sites directly, but can be achieved by using another activity adapted for this purpose. I don't see I state anywhere that is the only way of achieving that Commented Sep 22, 2014 at 7:39
2

In SharePoint 2013 Workflows was introduced a new action named Call HTTP Web Service. Using the specified action you could consume SharePoint REST API, in particular /_api/web/webinfos/add endpoint to create web site from a workflow.

Please follow Consuming the SharePoint 2013 REST Service from SharePoint Designer post that describes how to configure Call HTTP Web Service in order to create web site.

In order to perform Create/Update/Delete operations using Call HTTP Web Service action, App permissions for workflow have to be configured. Please follow the steps in article Create a workflow with elevated permissions by using the SharePoint 2013 Workflow platform to configure App permissions for workflow.

0

I agree to suggested approach with calling web service, but it is quite complex to implement.

There is a workflow action called Create Site in Workflow Action Pack. It allows creating SharePoint sites cross-site from a template.

It is paid third party solution with many other workflow actions. I'm a part of the development team.

0

I tried the above to create a site, but it didn't create the site nor errored. Here are the logs of the dictionaries I wrote out. Please advise.

2/13/2019 1:36 AM Comment No presence informationHoward Bash Url: https://somesite.sharepoint.com/sites/OfficeDevelopment/DataKloudDev/_api/web/webinfos 2/13/2019 1:36 AM Comment No presence informationHoward Bash Metadata: {"type":"SP.WebInfoCreationInformation"} 2/13/2019 1:36 AM Comment No presence informationHoward Bash WebParameters: {"__metadata":{"type":"SP.WebInfoCreationInformation"},"Url":"MadeInCode","Description":"MadeInCode","Language":2,"WebTemplate":"sts","UseIniquePermissions":false} 2/13/2019 1:36 AM Comment No presence informationHoward Bash RequestHeaders: {"Accept":"application/json;odata=verbose","Content-Type":"application/json;odata=verbose"} 2/13/2019 1:36 AM Comment No presence informationHoward Bash RequestContent {"parameters":{"__metadata":{"type":"SP.WebInfoCreationInformation"},"Url":"MadeInCode","Description":"MadeInCode","Language":2,"WebTemplate":"sts","UseIniquePermissions":false}}

1
  • Your WebTemplate and UseUniquePermissions parameters don't look right. UseUniquePermissions should be spelt as I have, replace the capital I with a U. The WebTemplate should read sts#0 (assuming you are trying to create a team site).
    – JonS
    Commented Jul 29, 2019 at 12:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.