Lesson: Enabling Salesforce Sessions for Noca AI Bots
Learn how to configure user-level authentication for your Noca AI bot, ensuring all data queries and automated actions strictly enforce the Salesforce permissions and record visibility of the logged-in user.
Prerequisites
Before starting this guide, ensure you have:
-
Access to your Noca AI workspace.
-
An active Salesforce integration connected to your workspace.
-
A pre-configured Noca Bot with Salesforce data sources or automations added.
Why Use Salesforce Sessions?
When a Salesforce Session is enabled, the bot does not use a global system account. Instead:
-
All Data Sources and Automations run under the credentials of the user currently logged in.
-
Sales reps only see the accounts and records assigned to them.
-
Community users only access their allowed records.
-
Enterprise data governance and role-based permissions are maintained automatically.
Step 1: Open Bot Security Settings
-
From your Noca AI dashboard, open your bot (e.g.,
Sales Helper). -
In the right-hand panel, click on the Settings tab.
-
Select Security from the left side of the settings modal.
Step 2: Select the Salesforce Session Provider
-
Under Security Settings, click the Select Provider dropdown.
-
Choose Salesforce Session.
-
Under Choose your connection, select your target Salesforce connection (e.g.,
Salesforce - Noca Dev Org).
Step 3: Save and Publish Your Bot
-
Click the close button on the settings modal.
-
In the top toolbar, click Save.
-
Click Publish (or open the publish menu) and confirm by clicking Publish.
-
Once published, click View Bot to test the live user experience.
Step 4: Authenticate as a Salesforce User
-
When the bot loads, it will prompt you to authenticate before proceeding.
-
Click Auth Production (or Sandbox, depending on your environment setup).
-
In the Salesforce popup window, select or log in with your specific Salesforce user credentials.
-
Once authenticated, click the Send button in the bot window to complete setup.
Step 5: Test Record Visibility
-
Send a query to the bot, such as:
“List all accounts”
-
Verify the output. The bot will return a table containing only the accounts and records that your logged-in Salesforce user account has explicit permission to view!