Salesforce
Connect Salesforce so your agent can recognise returning callers, capture new leads and keep opportunities current, without anyone updating the CRM after the call.
At a glance
Before you connect
- An edition with API access. Enterprise, Performance, Unlimited and Developer editions include it. Professional Edition needs the API add-on.
- A user with the API Enabled permission. The agent acts as whoever signs in, so use a dedicated integration user with access to only the objects your agent needs. Anything that user can edit, the agent can edit.
- Admin approval, if you’re not an admin. Salesforce blocks users from authorizing a connected app that isn’t installed in the org unless they have the Approve Uninstalled Connected Apps permission. If sign-in is blocked, ask a Salesforce admin to install the app first.
Connect Salesforce
Open Salesforce on the Integrations page
Open the Integrations page in the dashboard and click Connect next to Salesforce.
Tools
The function name is what the agent calls. Reference it in your prompt, for example “Call salesforce_search_leads with the caller’s phone number before asking for their name.”
Fields
Search leads
Returns each matching lead’s Id, Name, Email and Phone. Use Get lead with the Id for the full record.
Get lead · Get account · Get opportunity
The agent is told never to use a name as an ID. For leads, it should search first. Accounts and opportunities have no search tool, so the ID has to come from earlier in the call, such as a field on the lead.
Create lead · Update lead
Update lead also needs the lead’s record_id. Every other field is optional; the agent fills the ones it learns on the call.
By default, Salesforce requires Last name and Company on a new lead, and your org may require more fields. Tell the agent to collect them before it calls Create lead.
Update opportunity
Needs the opportunity’s record_id, plus any of:
Pin the values that never change
Open the tool on your agent and set these fields to Fixed (or Variable, to set them per campaign). The agent stops asking about them and can’t change them.
Use values from your org’s picklists. Voice Agent isn’t a default Lead Source value, so add it to the picklist in Salesforce Setup first, or pin one you already use.
How it works on a call
Identify the caller
The agent calls Search leads with the caller’s number or email. A match returns the lead’s ID.
Example condition prompts:
Limits
- Production orgs only. Sign-in always goes through
login.salesforce.com; sandboxes aren’t supported. - Leads are the only searchable object. Accounts and opportunities are read by ID.
- One Salesforce org per organization. To switch to a different one, click Disconnect, then Connect again.
Troubleshooting
A Salesforce tool shows Reconnect on the Tools page
Access can no longer be renewed. Usually an admin revoked the app, or your org’s refresh-token policy expired it. Click Reconnect and sign in again. Your tools and pins are kept.
Create or update fails with 'Provider rejected the request: HTTP 400: …'
Salesforce refused the record. The text after the colon is Salesforce’s reason, such as the missing field. The usual causes are a missing required field, such as Last name or Company on a new lead, a validation rule, or a pinned value that a restricted picklist doesn’t allow. Pinned values are sent exactly as typed, so copy them from the field’s picklist in Salesforce Setup.
