Question

In SharePoint Online, the Automatic Workflow Clean-up is set to 30 days and cannot be turned off or modified. I need to retain this workflow history information for auditing purposes.

Is there a way to export out this information possibly every 7-10 days? I know that there is a hidden Workflow History, but it has no association to the item.

Was it helpful?

Solution

The Workflow History list is a standard list like any other. ....../Lists/Workflow%20History is the default, though workflows can use whatever history list they want of course.

I checked my online SharePoint and it looks like the structure is the same as our on premises SP2013. There's a List ID, which is a GUID, and there is a "Primary Item ID" field that lists the ID of the item. It's an integer with an internal name of "Item".

You should be able to write REST code or Powershell code, or even SharePoint Designer code to be able to grab the information and write it to another list. It would be a chore since you'd have to figure out what guids belong to what, but it looks doable.

The other fields in the history list

 Modified                           Date and Time   
 Created                            Date and Time   
 Event Type                         Event Type   
 Workflow History Parent Instance   Single line of text   
 Workflow Association ID            Single line of text   
 Workflow Template ID               Single line of text   
 List ID                            Single line of text   
 Primary Item ID                    Integer  
 User ID                            Person or Group   
 Date Occurred                      Date and Time   
 Group Type                         Integer  
 Outcome                            Single line of text  
 Duration                           Number  
 Description                        Single line of text  
 Data                               Multiple lines of text  
 Created By                         Person or Group   
 Modified By                        Person or Group  

OTHER TIPS

The Workflow History List is hidden list but you can access from the URL. I have a Workflow History list in a site I can access

<<site url>>/Lists/Workflow History/AllItems.aspx

You will see the list with items

enter image description here

The list will have default "Export to Excel" option.

If you want to automate this process create a Task Scheduler using Powershell or CSOM and store the file into your preferred location.

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top