If you want to send out a survey automatically using a Workflow (such as every time a case is closed) then you can set this up by utilising the following steps.

Firstly, you will need to create an email template within Salesforce. This will include your survey link and any merge fields you want to add. To do this go Setup > Email > Email Templates.

Click ‘New Template’ at the top of the page and choose the type of email you would like to use. For this example we will choose a Text email.

On the next page, you can start creating your template. At the top of the page is a drop-down menu showing you the available field types and fields. You can use this generate any merge fields you want to include in your email.

Ensure you mark the template available for use and give it a relevant name. You can set your email subject and your email body, inserting any merge tags as required. You can also add the survey URL into the conversation.

You can test and verify your merge fields on the following page and once you are happy with your email you can move on to create the workflow.

Create Your Workflow

Now your email template is ready you can set up your workflow to create the email. Workflows are a great way to automate business processes in which you can create rules, based on criteria that you set, that will then get Salesforce to do a number of things such as send an email, create a task, or update a field.

Let’s say for example you want to trigger a survey to be sent when a case is closed.

First of all you need to go to Process Automation > Workflow Rules. Select ‘New Rule’ and select the object you want the rule to apply to (for this example we have selected case). Give your rule a name and description and then decide on your evaluation criteria. Here you can decide if Salesforce will evaluate the rule when a record is:

  1. Created

  2. Created, and every time it’s edited

  3. Created, and every time it’s edited to subsequently meet criteria.

For the purpose of our scenario we will go with option 3 so that the workflow will be triggered when the case is edited to be closed.

You then need to set your rule criteria. We have chosen:

  • Field: Case: Closed

  • Operator: equals

  • Value: True

You can add further filter logic here if required. Your Workflow should look something like this:

Create Your Workflow Actions

Now that your rule is set up, you need to specify the workflow actions that the rule will trigger. From the drop down ‘Add Workflow Action’ select the ‘New Email Alert’. Give your email alert a description, unique name and choose the email template you created earlier.

You can then choose the recipients for your email. In this scenario we will want to email to the email address provided in the case so will choose ‘Email Field’ under Recipient Type and select ‘Contact Email’ from the list of available recipients. You can select additional email addresses to be notified if required and choose a from address.

Save your action and you are almost there. The last step in the process is to activate your rule. On the Workflow Rules landing page to the left of the rule you set up you should see the options to edit, delete and activate. Click ‘Activate’ and your workflow will now be live and your email triggered next time a case is closed.

Did this answer your question?