This Repository is a "partially" self-contained demo repository that demonstrates the following:
- Ability for a Custom Lightning Web Component (LWC) to be embedded into Microsoft Outlook leveraging Lightning For Outlook (LFO)
- Ability for a Custom Lightning Web Component (LWC) embedded into Microsoft Outlook to associate Emails with Salesforce Records
- Ability for a Custom Lightning Web Component (LWC) embedded into Microsoft Outlook to pull information from an Email in Read Mode
- Ability for a Custom Lightning Web Component (LWC) embedded into Microsoft Outlook to pull data from an external data source via an API
Note: This demo currently has an immigration/legal flavor to it. I intend to generalize this in the future.
Lightning for Outlook is the ability for you to embed Salesforce capabilities into Microsoft Outlook (Including Office 365!). Read more HERE.
- Lightning Web Component that can be embedded into an Outlook Flexipage.
- Custom Objects for Internal and External Searching.
- Lightning App that allows you to demonstrate/test capability without Office 365 (aka, if it works here, it should work in Outlook), as well as provides access to the custom objects.
- Apex based Rest API
- Salesforce Community. This is only used to enable a guest user profile to enable API access.
- Remote Site Settings (Assuming you are installing via GPBU-Deployer)
- Data (Assuming you are installing via GPBU-Deployer)
Due to the fact that this includes a community, there are some setup steps prior to installing the package.
Setup -> Sites -> Ensure you have a domain name.
Setup -> Communities Settings -> Enable ExperienceBundle Metadata API (Must be checked!)
*Note: this is currently only available as Source Installable via the GPBU Deployer.
Because we are doing a Rest API Call, we need to enable access to the endpoint via the creation of a Remote Site Setting. This is done automatically if you leverage the GPBU-Deployer, but should something not work, you must create one manually.
- Get your salesforce site domain name from Setup -> Sites (Example: sandbox-energy-saas-93462-dev-ed-175b99744ef.cs97.force.com)
- Add a new Remote Site (Setup -> Remote Site Settings -> New) that allows access to your site.
- From Setup, go to "Outlook Integration and Sync", enable "Let users access Salesforce records from Outlook".
- Click on the down arrow and enable "Customize Content with AppBuilder".
- Click Create new "Pane"
- Add the "Outlook" custom component to the page. Recommendation is to add a new "Tab" and set it to only be visible in "Read Mode".
- Save -> Activate -> Set this page as the default Email Application Pane -> Activate
- Ensure your User Account is using your Office 365 Email Address.
Download Directly from the Microsoft App Store
First and foremost, If you don't feel like doing all the Office 365 Setup (Or potentially you can't because of Licensing), I have inclueded an embedded "LFO Demo" App that has the outlook look and feel and demonstrate's the same functionality of the Lightning Web Component in the safety of the Lightning Platform.
The Lightning Web component grabs data directly from open emails, so it is more impactful if it brings back records. The trick is to update a few Service_Item__c records to have an email address (Attorney_Email__c) you can readily send emails from. You can do this by opening up the LFO_Demo App and clicking on the Service Item tab.
The demo consists of 3 major scenarios. Each is outlined below.
Number | Talk Track | Actions |
---|---|---|
1 | Blah | Blah |
2 | Blah | Blah |
3 | Blah | Blah |
Number | Talk Track | Actions |
---|---|---|
1 | Blah | Blah |
2 | Blah | Blah |
3 | Blah | Blah |
First Name: Jarred
Last Name: Peplay
Date of Birth: 02/08/1955
Number | Talk Track | Actions |
---|---|---|
1 | Blah | Blah |
2 | Blah | Blah |
3 | Blah | Blah |
Number | Talk Track | Actions |
---|---|---|
1 | Blah | Blah |
2 | Blah | Blah |
3 | Blah | Blah |
Subject: Jarred Peplay
Message Body:
Hi,
I am the legal aid for Cochran, Cochran, and Cochran associates. Can you please provide updates on our client Jarred Peplay. Here is the information I have:
- Name: Jarred Peplay
- A Number: 857925175
- Date of Birth: 02/08/1955
- Birth Country: Madagascar
Thanks,
{Your Name}
Legal Aid
Cochran, Cochran, and Cochran associates
(222) 222-2222