{"id":13800116,"url":"https://github.com/Dev-Mom/SharePointWorkflowConverter","last_synced_at":"2025-05-13T09:31:08.051Z","repository":{"id":157587110,"uuid":"295843228","full_name":"Dev-Mom/SharePointWorkflowConverter","owner":"Dev-Mom","description":"A proof-of-concept C# console application for retrieving legacy 2010 \u0026 2013 custom SharePoint workflow definition files, and creating new Power Automate flows programmatically.","archived":false,"fork":false,"pushed_at":"2020-09-16T23:34:47.000Z","size":80,"stargazers_count":15,"open_issues_count":1,"forks_count":7,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-11T22:36:58.790Z","etag":null,"topics":["logicapps","powerautomate","sharepoint","sharepoint-online","workflows"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Dev-Mom.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2020-09-15T20:35:49.000Z","updated_at":"2024-10-30T00:06:49.000Z","dependencies_parsed_at":"2024-01-02T23:09:07.257Z","dependency_job_id":"bd0be66f-21cc-4584-92d2-f2b93ef2c88a","html_url":"https://github.com/Dev-Mom/SharePointWorkflowConverter","commit_stats":null,"previous_names":["dev-mom/sharepointworkflowconverter"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Mom%2FSharePointWorkflowConverter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Mom%2FSharePointWorkflowConverter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Mom%2FSharePointWorkflowConverter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Mom%2FSharePointWorkflowConverter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dev-Mom","download_url":"https://codeload.github.com/Dev-Mom/SharePointWorkflowConverter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253913028,"owners_count":21983245,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["logicapps","powerautomate","sharepoint","sharepoint-online","workflows"],"created_at":"2024-08-04T00:01:09.445Z","updated_at":"2025-05-13T09:31:07.561Z","avatar_url":"https://github.com/Dev-Mom.png","language":"C#","funding_links":[],"categories":["Tools, Extensions and Frameworks"],"sub_categories":["Power Platform (Microsoft)"],"readme":"# SharePointWorkflowConverter\nA proof-of-concept C# console application for retrieving legacy 2010 \u0026 2013 custom SharePoint workflow definition files, and creating new Power Automate flows programmatically.\n\n### General Notes:\n1. This project is a proof-of-concept to demonstrate that it's *possible* to programmatically retrieve/parse SharePoint legacy workflow definition files and create new Power Automate flows.  As for specific use cases and implementation, this is a launch pad for you to build those out.   \n1. Only compatible with SharePoint Online.\n2. Tested with a tenant [global admin](https://docs.microsoft.com/en-us/microsoft-365/admin/add-users/about-admin-roles?view=o365-worldwide#commonly-used-microsoft-365-admin-center-roles) account.\n3. Uses the 4.7.2 [.NET Framework](https://docs.microsoft.com/en-us/dotnet/standard/choosing-core-framework-server).  \n4. The code for retrieving legacy workflows and the code for creating a new Power Automate flow are contained in 2 separate respective functions: `GetLegacyWorkflow()` and `CreateNewWorkflow()`.  If you don't need one or the other for your purposes, simply comment them out.\n### Notes about retrieving legacy 2010/2013 workflows:\n1. [Legacy authentication](https://techcommunity.microsoft.com/t5/microsoft-sharepoint-blog/sharepoint-online-authentication-in-powershell-for-csom-when/ba-p/510114) must be enabled in the tenant for this code to work.   \n2. All custom list/library workflows created within SharePoint Designer will have `*.xoml` and `*.xoml.wfconfig.xml` files.  Each file contains pertinent information describing the workflow, such as list/library associations, actions, etc.  You can manually view these files in [SharePoint Designer 2013](https://www.microsoft.com/en-us/download/details.aspx?id=35491) by clicking *All Files* from the left-hand navigation and selecting \u003e *Workflows*.  The files can be programmatically retrieved using this project and parsed to map to equivalent Power Automate connections, actions, etc.\n![SharePoint Designer Screenshot](/SS.png?raw=true)\n3. Declarative `*.xoml` and `*.xoml.wfconfig.xml` files do not appear to exist for workflows created from [OOB SharePoint 2010 or 2013 workflow templates](https://support.microsoft.com/en-us/office/overview-of-workflows-included-with-sharepoint-d74fcceb-3a64-40fb-9904-cc33ca49da56).  *(If you can find them - I'll buy you a beverage of your choice!)*\n### Notes about creating Power Automate flows:\n1. This project leverages the [Power Automate Management Web API](https://docs.microsoft.com/en-us/power-automate/web-api) to create a new Power Automate flow.  \n2. Per Microsoft's [documentation](https://docs.microsoft.com/en-us/power-automate/web-api), flows shown in the *My Flows* tab are not supported by these APIs.  Instead you will find flows created via the API in your *[Solutions](https://flow.microsoft.com/en-us/blog/solutions-in-microsoft-flow/) \u003e Default Solution* tab.  \n*(I have opened a [GitHub issue](https://github.com/MicrosoftDocs/power-automate-docs/issues/323) inquiring about how to programmatically create Power Automate flows within solutions other than Default.)* \n3. The meat and potatoes of the flow payload is in the `clientdata` property.  To help determine appropriate content for this section, I recommend manually creating the desired Power Automate flow using the UI.  Then, you can [leverage the API](https://docs.microsoft.com/en-us/power-automate/web-api#list-flows) to get the `clientdata` content for your manual flow and copy/paste it into the payload for your new flow.  \n*(Also a great strategy for programmatically bulk-creating Power Automate flows in an environment!)*\n4.  Once you successfully create a new Power Automate flow via the API, you will need to turn it on.  Then, do a Ctrl+F5 refresh to confirm your connections appear as expected.   \n![Power Automate Screenshot](/SS1.png?raw=true)\n\n### Happy Automating! :-)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDev-Mom%2FSharePointWorkflowConverter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FDev-Mom%2FSharePointWorkflowConverter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDev-Mom%2FSharePointWorkflowConverter/lists"}