Introduction
Hello and welcome to the Anrok/Salesforce integration guide. This guide outlines the process for linking your Salesforce account with Anrok to automatically synchronize transactions and update sales tax to your Salesforce invoices.
Before you continue, ensure that your Product IDs are set up in Anrok. Click here to learn how to do so.
Invite Anrok to Salesforce
First, you'll need to invite Anrok to your Salesforce account to allow Anrok to set up webhooks. When inviting Anrok, send the invitation to billing-integration-support@anrok.com with admin permissions. You also have the option to create an SFDC sandbox account called "Anrok" and type "Developer".
Create Sales Tax Product
Next, create the 'Sales Tax' product:
- Click the dots in the upper-left and search for the 'Products' App.
- Select 'All Products'.
- Click 'New'
- Product Name: Sales Tax
- Product Code: sales-tax
- ✔️ Active.
Create a permission set
Set up → Quick find box → Permission Sets → New
- Label:
Anrok API User
- API Name:
AnrokApiUser
Go to Manage Assignments → Add assignment
- Choose user that you did OAuth with
- Assign
Create Salesforce Named Credentials
Go to Setup → Quick find box → Named Credentials
Create an External Credential first:
- External Credentials → New
- Label:
Anrok API key secret
- Name:
AnrokApiKeySecret
- Authentication protocol:
Custom
Create permission set mapping:
- Permission set:
Anrok API User
- Sequence number:
1
- Identity type:
Named Principal
- Authentication parameter 1:
- Name:
ApiKeySecret
- Value: Generate an API key from Anrok and paste it here
- Anrok → Data sources → Salesforce integration → Ellipsis menu → Manage Anrok API key → Generate Anrok API key
- Name:
Create custom header:
- Name:
Authorization
- Value:
{!'Bearer ' & $Credential.AnrokApiKeySecret.ApiKeySecret}
- Sequence:
1
Go back to Named Credentials tab → New
- Label:
Anrok API key named credential
- Name:
AnrokApiKeyNamedCredential
- URL: https://api.anrok.com/integrations/salesforce/webhook
- External credential:
Anrok API key secret
- Allow Formulas in HTTP Header: Yes
- Uncheck other options
Final setting: