Zapier: Sending Reward Data To Salesforce
In this article, we will go through the steps required to send Reward redemption data from the AdvocateHub to a custom object in Salesforce. When an Advocate redeems a reward In the AdvocateHub we can use Zapier to send this reward data to Salesforce as well as adding the Advocate as a new contact if they do not already exist in your Salesforce. This maybe be useful for your Sales team to quickly and easily see when a reward was redeemed and what it was, along with some other information if required, this information can be used as a nice personal touch if your Sales team is contacting an Advocate in the future.
This article will cover:
Prerequisites: You will need to have a Premium Zapier account in order to begin this process.
Creating A New Custom Object in Salesforce (Overview)
The first thing we need to do is create our Custom Object in Salesforce, we won't delve into too much detail on this as a Salesforce Administrator will know the steps involved here. In this example I named my object 'AdvocateHub Reward' but you can name it whatever makes most sense for your needs. I also included a few custom fields which you can see below, I added a field to Lookup the Contact object and also a number field to house the amount of points the reward cost the Advocate. Again, feel free to add anything else you would like here.
1. Go to Zapier, and click on Make a Zap!
2. Choose Webhook for the 'App' and select Catch Hook for the 'trigger'. At this point it should look like below:
3. Copy the webhook link present in the View Webhook section and then continue to Test this step and copy the webhook link
4. Now open up a new window/tab and navigate to your AdvocateHub's Webhook configuration page: Settings > System > Webhooks
5. Click on the Add a Webhook button:
6. Here you fill out the name of the webhook, the URL and the format. You also select the event you want this webhook to run on:
- Name - Is not important and you can call it whatever makes most sense for you
- Webhook Provider URL - This is the URL we retrieved from Zapier in point 3 above
- Format - Must be 'Form Post'
- Event - In this case it will be 'Reward Fulfilled'
7. Now we are ready to test that the webhook is being caught so head back to Zapier and go to the 'Test this step' stage. Click 'OK, I did this' and quickly go back to your hub and redeem a reward AdvocateHub. If the webhook is working at this point you will see a screen like below:
Building The Zap
Now that we our Custom Object in Salesforce built and our Webhook successfully triggering we are ready to build the rest of our zap.
1. For the first 'Action' stage of the Zap search for and select the Salesforce app
2. In the list of possible actions, choose 'Find a Contact'
3. The next step will involve hooking up your Salesforce account to Zapier (if you have not already done this in the past). Follow the instructions in Zapier and enter your credentials
4. Next, we want to enter the following in the available fields:
Fields to Search By: Contact ID
Search Value: Select the Contact[external Systems][salesforce Contact Id] from the dropdown button on the right of the field (see below)
(Optional) Also, check the 'Create Salesforce Contact if it doesn't exist yet?' box if you want to add the Advocate who is redeeming the reward to Salesforce as a contact if they do not exist already. Fill out the applicable details you want to populate this new Contact with under the 'Set up Salesforce Contact' section
5. Click 'Continue' and test this step and we should have success again
6. For the second 'Action' stage of the Zap search for and select the Salesforce app, exactly like we did for Step 1 of this section above
7. This time from the list of possible actions choose 'Find a Custom Object'
8. Once again, select your Salesforce account and continue
9. Next, we want to enter the following in the available fields:
Custom Object Type: AdvocateHub Reward (whatever you names your Object)
Field to Search By: AdvocateHub Reward Name
Search Value: Select 'Name' from the drop down to the right of the field
Check the checkbox for 'create Salesforce Custom Object if it doesn't exist yet'
10. On the second half of this page, choose which data you want brought over to your Custom Object. Here is my example:
11. Click 'Continue' and test the is step and that should be it! Once you have the success message, click finish!
12. Turn your Zap on and test it out and you should see something like this on your Contact record in Salesforce