SharePoint Module Basics – ListsLast Updated: 12/05/2018 Introduced in Version:
The SharePoint module in Decisions allows you to access and update SharePoint list data using steps in a flow. Before using these steps, you must install the SharePoint module. Instructions on how to do that are listed here: SharePoint Module Basics – Setup
Supported SharePoint List Features
- Add Item
- Delete Item
Get All Items
- Update Item
In this example we are going to interact with a custom list created in SharePoint named Customer Contacts.
Create SharePoint List Integration
Before we can interact with our SharePoint list in a flow, we need to setup an integration with the list.
- Navigate to System > Integrations > SharePoint
- This is the SharePoint integrations folder, where all of our list integrations and SharePoint defined data structures will be stored.
- Click Add SharePoint List
- Fill in the following form
- Name: This is the name of the integration that will be creating in the SharePoint integrations folder. This field is required and does not have to match the list name in SharePoint.
- Description: This is an optional field to describe your integration.
- List Name: This is the actual name of the SharePoint list in SharePoint. My list is named Customer Contacts. This field is required and does need to match the list name in SharePoint.
- Click the ellipses button to open your SharePoint Settings.
- Fill in your credentials for your SharePoint server.
- Authentication: Default is Windows Authentication. We also support Claims Authentication, for which you would need to provide your SAML site.
- Sharepoint Site: The URL to your SharePoint site
- Sharepoint Domain: The windows domain where your SharePoint site is hosted. This is not the URL domain name of your SharePoint site.
- Sharepoint UserName: A SharePoint user that has permissions to manage this list in SharePoint. Click here for more on SharePoint permissions.
- Sharepoint Password: The SharePoint user’s password
- After saving the list configuration information two items will appear in the lists folder. One is the configuration data, the other is the Decisions defined data structure generated for your list.
Note: Your type may have some unusual field names. These are the field identifiers that your SharePoint list provided and should not be edited. The column names you are used to seeing in SharePoint are available in the Display Label property of each field.
Example: Displaying a List of Items
- Create a flow
- In the Steps browser, locate your Sharepoint list steps under Data > Sharepoint
- Select the Get All Items step and add it to the flow. Connect the Start step to it.
- Add a Show Form step to the flow, and connect the Success path of the Get All Items step to it.
- In the Form add a Button and a Data Grid.
- In the properties for the Data Grid, for the Input Data Type, choose All/Search… Then, type your list name into the search box and select it in the results.
- Click the pencil icon to rename the column titles of the data grid.
- Manually copy the Display Label from your data structure and paste into the column Title on your data grid.
- Save and Close the Form.
- Edit the Form’s Input Mapping to connect the output of Get All Items step to the grid.
- Connect the button path from the Form to the End Step. For now, connect the Error path from the Get All Items step to the End Step. It is best practice to setup error handling for this scenario. See our best practices here.
- When you run this flow, you will see the list of the items that are in your SharePoint site.