This article discusses configuration steps required to make SharePoint content available in KnowledgeTree.
How it Works
KnowledgeTree integrates with Salesforce's Files Connect feature to access your SharePoint content.
KnowledgeTree can surface any files accessible via Salesforce. So, once you link SharePoint libraries and content to Salesforce, KnowledgeTree can access and surface those files to your reps and customers:
Prerequisites and Limitations
In order to use SharePoint content in KnowledgeTree, you must first enable the Files Connect feature in Salesforce and link your SharePoint libraries to Salesforce. This is a somewhat lengthy one-time process, be prepared and set aside 60-90 minutes.
BEFORE YOU BEGIN:
- Files Connect supports both online and on-premise SharePoint sites. The step-by-step instructions in this article apply to online SharePoint editions only.- Please see Salesforce's comprehensive set of help articles for detailed instructions about connecting on-premise SharePoint editions.
- Setting up Files Connect requires user(s) with system administrator privileges in BOTH Salesforce and SharePoint (only site level admin access is needed if we are just connecting to individual sites. Global admin access is needed if we are connecting to the entire tenant).
IMPORTANT: You'll need to contact Salesforce support if:
- You are using an on-premise SharePoint instance.Files Connect supports SharePoint 2010 and 2013, but Salesforce requires purchase of a Permission Set license to connect on-premise SharePoint instances to Salesforce.
- You run into technical issues configuring Files Connect.Files Connect is a Salesforce feature, technical support is beyond the scope of KnowledgeTree's support team.
Once you've set up Files Connect and linked your Sharepoint instance to Salesforce, see Adding SharePoint Assets to begin using SharePoint content in KnowledgeTree.
Configuring Files Connect for SharePoint 365
Step 1: Enable the Files Connect feature in Salesforce
By default, the Files Connect feature is disabled. Let's turn it on.
- Log into Salesforce with System Administrator privileges and go to Setup.
- Type "Files Connect" in the Setup Search box.
- Select Files Connect.
- On the Files Connect Settings page, click Edit, and select the Enable Files Connect checkbox.
- In the File Sharing dropdown, specify how you want SharePoint files connected to Salesforce:Copy: Creates duplicate copies of SharePoint files in Salesforce. Anyone the copied file is shared with in Salesforce can see it, even if the file isn't shared with them in SharePoint. Updates to original files in SharePoint will not be reflected in Salesforce (nor in KnowledgeTree, which will link to the copy).Reference (*recommended*): Creates reference links to files in SharePoint, but does not create nor store copies of the files in Salesforce. Only people who can see the file in SharePoint can see the file in Salesforce. Updates to files in SharePoint will be reflected in Salesforce, and thus in KnowledgeTree.
- Click Save.
NOTE: Regardless of which method you choose above (Reference or Copy), once SharePoint files are added to KnowledgeTree by a KT Admin, the content is accessible to all KnowledgeTree users and any customers/prospects they share with--this is by design to enable reps & customers to access sales content without needing direct access to your SharePoint site.
Step 2: Assign Permissions for Files Connect
You must create a new Permission Set for Files Connect Cloud, and assign it to Salesforce users to enable them to access SharePoint files within Salesforce. At a minimum, you must assign the new permission set to the system administrator user as they will need it later in this tutorial.
1. In Salesforce Setup, go to Manage Users | Permission Sets and click New.
2. Complete the form as follows. Be sure to leave the User License field set to <--None-->
3. Click Save.
4. On the new permission set's main screen, click System Permissions, then click Edit.
5. Scroll down and select the Files Connect Cloud permission:
6. Click Save.
7. Click Manage Assignments in the toolbar at the top of the page.
8. Click Add Assignments
9. Select users, and click Assign.!! Remember to assign to the user completing this configuration, at a minimum.
Step 3: Set up Authentication between Salesforce and SharePoint
In order to access external data sources such as SharePoint 365 from within Salesforce, you must:
- Create an authentication provider for SharePoint 365 in Salesforce setup.
- Register that provider in the settings for your SharePoint 365 app.
- Log into Salesforce with System Administrator privileges and go to Setup.
- Type "auth" in the Setup Search box.
- Select Auth. Providers.
- Click New.
- For Provider Type, select Microsoft Access Control Service, and then set the following options:
- Name—Enter the name you want to appear in Salesforce (eg "SharePoint Libraries")
- URL Suffix—Enter a suffix you want to appear at the end of the URL path. By default, the suffix reflects the Name entry.
- Consumer Key—Enter a placeholder value. We'll come back and edit with the actual value after registering the provider in Sharepoint 365.
- Consumer Secret—Enter a placeholder value. We'll come back and edit with the actual value after registering the provider in Sharepoint 365.
- Authorize Endpoint URL—Enter a placeholder that begins with https. To be fixed later (you get the idea).
- Token Endpoint URL— Enter a placeholder that begins with https. Edit later as above.
- Default Scopes—Leave empty.
- Everything Else—Leave empty and/or accept the defaults in the rest of the form.
Click Save. Then, at the bottom of the Auth. Provider detail page, copy the Callback URL entry to a text file.
!! IMPORTANT: You’ll use this when registering the authentication provider in SharePoint 365 in the following section. Make sure to copy it!
Now, let's register this new provider in the settings for SharePoint 365.
- Log into your company's SharePoint 365 instance with system administrator credentials.
- Go to the following URL:https://[your company name].sharepoint.com/_layouts/15/appregnew.aspx
- Set the following options and click Create when done:
- Client Id—Click Generate, and copy the generated value to a text file.!! IMPORTANT: You'll need this value later, don't skip copying it.
- Client Secret—Click Generate, and copy the generated value to a text file.!! IMPORTANT: You'll need this value later, don't skip copying it.
- Title—Enter a name for the app (eg "Salesforce").
- App Domain—Enter the domain name of your Salesforce organization:- "[myco].my.salesforce.com" if you use a custom domain- "[instance].salesforce.com" if you don't, replace "instance" with the SFDC instance name (eg "na10") where your account is hosted.
- Redirect URL— Enter the Callback URL you copied when creating the Authentication Provider in Salesforce.
You should see a success message like the following after clicking Create:
Now we need to establish permissions and trust between Salesforce and Sharepoint.
- Go to the following URL:https://[your company name].sharepoint.com/_layouts/15/appinv.aspx
- Set the following options and click OK when done.
- App Id—Enter the Client Id you copied to a text file above, then click Lookup.
- Title—Keep the default value.
- App Domain—Keep the default value.
- Redirect URL—Keep the default value..
- Permission Request XML—Enter a string with this format:
<AppPermissionRequest Scope="[SCOPE]" Right="Read"/>
Replace [SCOPE] with one of these values:
- http://sharepoint/content/sitecollection/web - to let users access a single site (but not its subsites).
- http://sharepoint/content/sitecollection - to let users access a single site collection (including all subsites).
- http://sharepoint/content/tenant - to let users access all site collections.
When you click OK, you will be prompted to trust your Salesforce instance. Click Trust It.
Step 4: Update Auth Provider Placeholder Values in Salesforce
Now that we've got real values for the Office 365 keys (you copied them to a text file in step 3), we need to update the Auth Provider in Salesforce and replace the placeholder values entered previously.
1. In Salesforce Setup, go to Auth. Providers
2. Click Edit next to the provider you previously created.
3. Change the following values:
- Consumer Key—Enter the Client Id you copied to a text file.
- Consumer Secret—Enter the Client Secret you copied to a text file.
- Authorize Endpoint URL—Enter the URL of the OAuthAuthorize.aspx page in Office 365. The URL format is as follows:https://[your company name].sharepoint.com/_layouts/15/OauthAuthorize.aspx
- Token Endpoint URL— Enter a URL in the following format. Note you must replace [your company name] in 3 places:https://accounts.accesscontrol.windows.net/[your company name].onmicrosoft.com/tokens/OAuth/2?resource=00000003-0000-0ff1-ce00-000000000000/[your company name].sharepoint.com@[your company name].onmicrosoft.com
- Leave all other fields as-is and click Save.
Step 5: Create an External Data Source in Salesforce for Sharepoint 365
Sharepoint 365 will sit inside Salesforce as a standard external data source. Let's create that data source now.
- In Salesforce Setup, go to Develop | External Data Sources and click New.
- Set the options as follows:
- Label - A user-friendly name for the data source (eg “MyCo SharePoint Libraries”). This is displayed in the Salesforce Files interface.
- Name - A unique identifier, no spaces. Use the default suggested.
- Type - Choose Files Connect: SharePoint Online
- Site URL - must begin with https. This is the root URL for your SharePoint site (eg “knowledgetreeinc.sharepoint.com”)
- Exclude Other Site Collections - we recommend leaving this blank, otherwise you’ll need to set up separate external data sources for each SharePoint library you want to connect to Salesforce.
- Identity Type - we recommend selecting Per User. That will require each user to authenticate with SharePoint one time when they first try to access the linked libraries from Salesforce Files, and enforces SharePoint permissions inside Salesforce. Select Named Principal to use the same set of credentials for every user who accesses the data source from Salesforce.
- Authentication Protocol - Select OAuth 2.0.
- Authentication Provider - click the magnifier glass and choose the Auth Provider you set up earlier.
- Scope - leave blank.
- Start Authentication Flow on Save - Select to immediately test the settings above. Click Save. You’ll be redirected to SharePoint and prompted to trust your Salesforce instance again, click Trust It.
Click Save. You’ll be redirected to SharePoint and prompted to trust your Salesforce instance again, click Trust It.
Step 6: Update Permissions for the External Data Source
The last step is to edit the Permission Set you created way back in Step 2 to grant access the external data source we just created in Step 5.
1. In Salesforce Setup, go to Manage Users | Permission Sets and click on the Files Connect Cloudpermission set you created in step 2.
2. Click on External Data Source Access
3. Click Edit. Add the External Data Source you created in Step 5 and click Save.
You're Done (At Last)!
To test, go to the Files tab in Salesforce. You'll see a new External Files section in the left nav. Click, authenticate, and you're now able to access all your SharePoint libraries within Salesforce.
The great news is you can now link any SharePoint file to KnowledgeTree with a single click. See Adding Assets from SharePoint for details.