Skip to main content

SharePoint Integration for Facilio

Introduction​

Managing documents efficiently is crucial for facilities, maintenance, and corporate real estate (CRE) teams handling various operational tasks, such as storing work order completion reports, inspection reports, audits, and quotes. SharePoint integration with Facilio Connected CMMS (Computerized Maintenance Management System) enhances operational efficiency by automating document storage, centralizing records, and ensuring real-time access to critical files. This eliminates manual file management, enhances compliance readiness, and enables teams to retrieve, update, and collaborate on documents like work orders, vendor contracts, lease agreements, and asset recordsβ€”all within Facilio’s Connected CMMS environment.

Configuring SharePoint Integration​

1. Accessing SharePoint Settings​

To configure SharePoint integration in Facilio:

  1. Navigate to Settings in the Facilio application.
  2. Select SharePoint Settings from the available options.
  3. Configure the SharePoint connection by selecting a SharePoint site and document library.

2. General Settings Configuration​

The General Settings section allows users to define the primary SharePoint integration parameters:

  • Site: Select the SharePoint site to integrate with Facilio.
  • Document Library: Choose the document library within SharePoint where files will be stored and managed.
  • Root Folder (Optional): Select a specific root folder if you want to restrict access to a subset of the document library.
  • Click Save to store the settings.

Configuring Modules with SharePoint​

Facilio enables users to link SharePoint folders to specific modules within its Connected CMMS for efficient document organization. Each module can have its own SharePoint folder structure.

1. Adding a New Module​

To add and configure a new module:

  1. Click on the Add Module button.

  2. In the Add Module popup, fill in the following details:

    • Name: Enter a descriptive name for the module.
    • Facilio Module: Select the relevant Facilio module (e.g., Asset, Work Order, Building) from the dropdown.
    • Allow Create Record Folder: Enable this option to automatically create a new folder in SharePoint for every new record in the module.
    • Allow Link Existing Record Folder: Enable this option to associate existing SharePoint folders with records in Facilio.
    • Parent Folder Path: Specify a parent folder path to structure documents hierarchically.
    • Folder Name Field: Choose the field in Facilio that will be used as the SharePoint folder name.
    • SharePoint Folder ID (Facilio Field): Select the Facilio field that stores the SharePoint folder ID.
    • Facilio ID (SharePoint Custom Column): Choose the corresponding SharePoint column that maps to the Facilio record ID.
    • Permissions: Configure user access permissions in JSON format, specifying roles and their allowed actions.
    • Required Custom Columns (SharePoint): Select additional SharePoint columns that should be captured for each document.
    • Allow Multiple Files Upload: Enable this option to allow batch file uploads.
  3. Click Save to complete the module setup.

2. Configuring Permissions​

Permissions define which users can access, upload, and modify documents in the linked SharePoint library. Facilio allows defining user roles with specific permissions using JSON.

Example: Role-Based Permission Structure

{
"Super Administrator": {
"create_record_folder": true,
"link_record_folder": true,
"open_in_sharepoint": true,
"add_folder": true,
"upload": true,
"delete": true,
"preview": true,
"download": true
},
"Manager": {
"create_record_folder": true,
"link_record_folder": true,
"open_in_sharepoint": true,
"add_folder": true,
"upload": true,
"delete": false,
"preview": true,
"download": true
},
"Technician": {
"create_record_folder": false,
"link_record_folder": false,
"open_in_sharepoint": true,
"add_folder": false,
"upload": true,
"delete": false,
"preview": true,
"download": true
}
}

Using the SharePoint Widget in Facilio​

Once a module is configured with SharePoint, users can access SharePoint documents directly within Facilio through the SharePoint Widget available on the record page layout. This widget provides seamless interaction with SharePoint, ensuring document retrieval and management without leaving Facilio.

1. Accessing Documents via the SharePoint Widget​

  1. Open a module record (e.g., Asset, Work Order, Building) in Facilio.
  2. Locate the SharePoint tab on the summary page.
  3. The widget displays the linked SharePoint folders and files, ensuring users can browse, manage, and retrieve documents efficiently.

2. Actions Available in the SharePoint Widget​

Within the SharePoint Widget, users can perform various actions, including:

  • View Folders and Files: Browse through the linked SharePoint document structure without leaving Facilio.
  • Open in SharePoint: Click this option to directly open the document library in SharePoint for additional actions.
  • Upload Files: Add new documents to the linked SharePoint folder seamlessly from within Facilio.
  • Add Folder: Create new folders to better organize documents within SharePoint.
  • Sort and Filter Files: Arrange files based on attributes such as size, date modified, or name for easy navigation.
  • Preview and Download: Quickly preview or download documents directly from the widget without switching between platforms.

Automating SharePoint Integration​

This section provides an overview of how to automate SharePoint integration using custom functions, which can be used in Workflows / Stateflows. These functions allow seamless interaction with SharePoint for file and folder management, enabling automated document handling, structured storage, and efficient collaboration.

1. Fetching a SharePoint Folder by Path​

Function: getSharePointFolderByPath(String parentFolderId, String path)

Description:

Retrieves a SharePoint folder based on the provided folder path within a parent directory.

Parameters:

ParameterTypeDescription
parentFolderIdString(Optional) The unique identifier of the parent folder.
pathStringThe folder path inside the parent directory.

Returns:

A Map containing folder metadata, including folder ID, name, and path.

Example Usage in a Workflow Script:

parentFolderId = "XXXX";
folderPath = "/Cleaning/2025";
sharePointFolder = new NameSpace("sharepoint").getSharePointFolderByPath(parentFolderId, folderPath);
console.log(sharePointFolder);

πŸ“Œ Use Case in Workflows:

  • Automatically verify if a sharepoint folder exists before uploading files.
  • Automatically assign record folder based on the given path.

2. Uploading a File to SharePoint​

Function: uploadFileToSharePointFolder(String moduleName, Number recordId, Number fileId, String fileName, Map customColumns)

Description:

Uploads a file to a SharePoint folder and associates it with a specific module and record.

Parameters:

ParameterTypeDescription
moduleNameStringThe name of the module where the file belongs.
recordIdNumberThe record ID associated with the file.
fileIdNumberThe unique identifier of the file in the system.
fileNameStringThe name of the file, including the extension.
customColumnsMap(Optional) Additional metadata fields to store with the file.

Returns:

A Map with details of the uploaded file, including the SharePoint file ID and URL.

Example Usage in a Workflow Script:

moduleName = "asset";
recordId = 1234;
fileId = 5678;
fileName = "Asset Manual.pdf";
customColumns = {};
customColumns.DocumentType = "Standard Operating Procedures";
fileData = new NameSpace("sharepoint").uploadFileToSharePointFolder(moduleName, recordId, fileId, fileName, customColumns);
console.log(fileData);

πŸ“Œ Use Case in Workflows:

  • Automatically upload invoices to SharePoint when a new invoice is generated.
  • Attach supporting documents to SharePoint when creating a new record in Facilio.

3. Creating a SharePoint Folder for a Record​

Function: createSharePointFolderForRecord(String moduleName, Number recordId)

Description:

Creates a dedicated folder in SharePoint for a specific record within a module.

Parameters:

ParameterTypeDescription
moduleNameStringThe name of the module where the folder should be created.
recordIdNumberThe record ID for which the folder is being created.
folderNameStringThe name of the folder being created.

Returns:

A Map containing the newly created folder’s details, including folder ID and URL.

Example Usage in a Workflow Script:

moduleName = "asset";
recordId = 1234;
folderName = "AHU-1";
folder = new NameSpace("sharepoint").createSharePointFolderForRecord(moduleName, recordId, folderName);
console.log(folder);

πŸ“Œ Use Case in Workflows:

  • Automatically create a new building folder when a building is registered in Facilio.

Benefits of Automating SharePoint Integration in Workflows​

βœ… Automate File Organization – Ensure structured storage of files in SharePoint.
βœ… Improve Document Management – Upload, rename, and retrieve files dynamically.
βœ… Enhance Collaboration – Keep SharePoint folders in sync with Facilio records.
βœ… Seamlessly Integrate with Workflows / StateFlows – Automate document handling as part of business processes.

Troubleshooting & Support​

If you encounter issues while using SharePoint integration in Facilio:

  • Ensure that SharePoint authentication and permissions are correctly configured.
  • Verify that the SharePoint site and document library are accessible.
  • Check for any restrictions on file types or sizes in SharePoint.
  • Contact Facilio Support for further assistance.

Summary​

Facilio's SharePoint integration simplifies document management by enabling a direct linkage of SharePoint libraries with Facilio modules. Users can configure module-specific document repositories, upload and access files seamlessly, and ensure centralized document management across their operations.

For additional guidance or troubleshooting, contact us at support@facilio.com.