Salesforce integration

Turn a response into a Salesforce Case, Lead or Task without copying and pasting, or let an automation do it for every response that matches a condition. The record is created straight from the response, already filled in with the answers and the page the visitor was on, and it links back to the response. Available on the Business and Enterprise plans.

Records are created in your own Salesforce org through its API, as a user you choose. Salesforce Government Cloud and orgs without a My Domain cannot be connected.

Connect Salesforce

A space admin connects Salesforce once, from Settings → Integrations, and the people who can change a response's status can then send records. It has two parts. First, a Salesforce admin creates an app in Salesforce that Voxtrics signs in with. Then you enter the app's details on the Salesforce card.

Create the app in Salesforce

Voxtrics signs in to your org as an External Client App with the OAuth client credentials flow, so no password is shared and nobody approves a login. The steps use the labels of Salesforce's English interface, as in the screenshots. If your Salesforce is set to another language, the same items have translated labels.

  1. In Salesforce, open Setup. In Quick Find, search for External Client App Manager and open it. Press New External Client App.
Setup → External Client App Manager → New External Client App.
  1. Under Basic Information, enter a name for the app in External Client App Name, for example Voxtrics Feedback. Salesforce fills in the API Name from it; leave it as it is. Enter an email address in Contact Email. Leave Distribution State on Local.
Name the app and give a contact email.
  1. Under API (Enable OAuth Settings), tick Enable OAuth. Enter a Callback URL: Salesforce requires one, but the client credentials flow never uses it, so a placeholder such as https://localhost/callback works. Move Manage user data via APIs (api) into Selected OAuth Scopes. It is the only scope Voxtrics needs.
OAuth on, a placeholder callback address, and the api scope.
  1. Further down, under Flow Enablement, tick Enable Client Credentials Flow. If Salesforce asks you to confirm, press OK. Then press Create. Salesforce explains the flow in its client credentials flow guide.
The client credentials flow is the one to switch on.
  1. Open the new app's Policies tab and press Edit. Under OAuth Policies, in OAuth Flows and External Client App Enhancements, make sure Enable Client Credentials Flow is ticked. In Run As (Username), enter the username of the Salesforce user the app acts as. Press Save.
The OAuth Policies section of the Policies tab, in edit mode.
  1. Open the app's Settings tab and expand OAuth Settings. Press Consumer Key and Secret. Salesforce may ask for a verification code before it shows the values.
The Consumer Key and Secret button opens the page with both values.
  1. Copy the Consumer Key and the Consumer Secret with their Copy buttons. Keep them at hand: you enter them in Voxtrics in the next section.
Both values are masked in this picture.
  1. In Setup, open My Domain. Your org's address is the Current My Domain URL. The name Voxtrics needs is the part before .my.salesforce.com. Read it from that URL, not from the My Domain Name line below it: a sandbox's name ends in .sandbox and a Developer Edition org's in .develop.
The Current My Domain URL is your org's address.

Enter the details in Voxtrics

The Salesforce card: your My Domain name, the app's Consumer Key and its Consumer Secret.
  1. On the Salesforce card, enter your My Domain name: everything before .my.salesforce.com in your org's address. For https://your-company.my.salesforce.com that is your-company. A sandbox looks like your-company--uat.sandbox and a Developer Edition org like your-company-dev-ed.develop.
  2. Enter the Consumer Key and the Consumer Secret you copied.
  3. Press Connect Salesforce. Voxtrics asks Salesforce for an access token and reads your org's name before saving anything, so a typo shows up right away instead of at the first record.

Enter the name only, not the full address: Voxtrics builds the address itself and only ever connects to *.my.salesforce.com. The Consumer Secret is stored encrypted and never shown again. To change the org, the app or the secret later, use Edit. A secret you leave empty is kept, as long as the org and the Consumer Key stay the same.

Send a response to Salesforce

Open any response and find the Salesforce card on the right. Send to Salesforce opens a dialog with:

  • Record: Case, Lead or Task. A Lead is made from the email address in the survey's contact form, so it is switched off, with the reason, when the survey has no contact form.
  • Subject: for a Case or a Task. It starts as the visitor's own words (the main feedback text), or the survey name and score when there is no text.
  • Description: the survey, the score, the page and every answer. Edit it freely: a link back to the response is added after your text.
Everything is filled in from the response. Edit what you need and press Send.

Press Send. The new record appears on the response's Salesforce card, with a link that opens it in Salesforce, and the Task of a Case points at that Case. A response can be sent by hand up to five times.

If a record of the same kind has already failed on this response (one an automation tried, say), Send sends that record again instead of adding a second one. If an automation is still making one, the dialog asks you to wait a moment.

Make records automatically

Add the Salesforce action to an automation, from Automations or from the Automations section of a survey, and choose Case, Lead and Task as you need them.

The Salesforce action: pick the kinds of record to create.

A record is made for every response that matches the survey and the rating condition, right after the response is saved. There is no time window, minimum or throttle for this action. A Task points at the Case (or the Lead) made just before it, and a Lead is made only when the response has an email address. A space makes at most 500 records a day this way; past that, the response shows a failed record that says so, and the count starts over the next day.

Who can do what

  • Connect, edit or disconnect Salesforce: space admins.
  • Add the Salesforce action to an automation, change which responses it covers, or switch it on: space admins. Anyone who can edit the automation can still rename it, change its other actions, take the Salesforce action off or switch it off.
  • Send a response, or send a failed record again: admins and managers; on a team-restricted survey, Writer and up (the same people who can change a response's status).
  • See the records of a response: everyone who can open the response.

When something goes wrong

  • Salesforce did not accept this Consumer Key and Consumer Secret: check both, and that Enable Client Credentials Flow is ticked on the app's Policies tab.
  • Salesforce accepted the key but refused our first request: the Run As user probably cannot use the API. Give that user API access in Salesforce and try again.
  • Salesforce no longer accepts the saved Consumer Key and Consumer Secret: the secret was rotated, the app switched off or the Run As user frozen. The Salesforce card shows Needs attention and nothing new is sent; enter working credentials with Update credentials, and what was waiting is made.
  • A record failed: it stays on the response with the reason, in Salesforce's own words when it refused it (a validation rule, a required custom field, a duplicate rule). Fix the cause in Salesforce and press Try again: that same record is sent again. A record that has waited ten minutes before it was made can be sent again too, and Voxtrics also makes records an interruption left behind, every few minutes.

Disconnecting

Disconnect deletes the stored secret; nothing new is made until Salesforce is connected again, and a response can no longer be sent. Records already made stay in Salesforce and stay listed on their responses.