In this use case, we want to use the Nimbus Power Automate Connector for the following Salesforce interaction scenarios:
- When a call comes in then populate the caller data from the Salesforce contacts.
- When the call remains unhandled (no agent available, customer hung up), then log a new call task in Salesforce with a due date and assign to the corresponding account manager.
Show a preview of the flow...
PRECONDITIONS
At this point we assume you have a Salesforce account with admin privileges.
To connect to Power Automate to your Salesforce instance, perform the steps below.
- Log into your Power Automate account. Within the main menu, go to Data > Connections. Click "New Connection" and select "Salesforce "
- When adding the connector, note that this requires a Premium Power Automate account. 💡 Cost of this connector is outside of Luware product scope.
- Select your URI, and the API Version and create the connection
☝ We highly recommend testing in a "Sandbox" or creating a new account in Salesforce to test the connection. You can delete the account permanently after testing your solution.
You have already created the flow: Use Case - Looking up caller information and creating a task in Salesforce.
🤔 Why is this necessary? In the flow of this use case you learn to create and use Nimbus parameters which are also required in this flow.
Show Icon Legend
💡 = A hint to signal learnings, improvements or useful information in context. | 🔍 = Info points out essential notes or related page in context. |
☝ = Notifies you about fallacies and tricky parts that help avoid problems. | 🤔 = Asks and answers common questions and troubleshooting points. |
❌ = Warns you of actions with irreversible / data-destructive consequence. | ✅ = Intructs you to perform a certain (prerequired) action to complete a related step. |
How-To Steps
Create the Flow
✅ Ensure that your service's workflow has a "Accept Conversation" Workflow Activity which starts the "GetOnUpdatedTasks" Trigger Event.
- Start your flow with the a "GetOnUpdatedTasks" Nimbus activity.
- Select the "Queue Left" Event. If this event is raised, it means the caller has not been connected to an Agent.
Check SFTaskID Parameter
✅ If the contact had been found in Salesforce in the previous Flow, then there should be a value in the SFTaskID parameter.
💡 We created these Parameters in Use Case - Looking up caller information and creating a task in Salesforce.
-
Initialize a variable SFTaskID and write the following expression to it:
- Name= SFTaskID
- Type= String
- Value= triggerOutputs()?['body/customerContextParameters/SFTaskID']
-
Add a Control > "Condition" element to the flow and check on the SFTaskID variable
✅ In the "If no" branch, the SFTaskId is not an empty string, so we want to update the task.
Update the Task in Salesforce
✅ If the SFTaskID is not an empty string, then we can update the Salesforce task as with a due date in two days.
-
Add a "Get future time" element as follows:
- Interval = 2
-
Time unit = Day
-
Then add the "Update record" element from the Salesforce connector and set the values to:
- Salesforce Object Type = Tasks
- RecordID = SFTaskID
- Due Date Only = Future Time
-
Update other values as you like. Here is an example:
- Subject = Call Back - Missed Incoming Call via Nimbus service @{triggerOutputs()?['body/teamName']} at @{formatDateTime(triggerOutputs()?['body/created'],' hh:mm tt')}
-
Description =
You've received a call via nimbus service @{triggerOutputs()?['body/teamName']}. The call has not been handled.
Details:Number: @{triggerOutputs()?['body/microsoftCallerId']}
Ring Time: @{formatDateTime(triggerOutputs()?['body/created'],' hh:mm tt')}to @{formatDateTime(triggerOutputs()?['body/terminated'],' hh:mm tt')} - Call Type = Inbound
- Call Object Identifier = RequestId