Note:This guide covers the functionality of the latest 1.59.1 version of the PandaDoc <> Salesforce integration.
PandaDoc: Enterprise plan
Salesforce: “Professional”, “Enterprise”, “Unlimited”, “Developer edition”, "Performance" or "Essentials"
The integration will work for Opportunities, Leads, Contacts, Accounts, and custom objects.
- Connect PandaDoc and Salesforce
- Install PandaDoc package on AppExchange
- Configure PandaDoc for a Salesforce object
- Pass data from Salesforce into PandaDoc
- Passing information from Salesforce into PandaDoc (via fields)
- Pass Product data from Salesforce into PandaDoc pricing tables
- Create and Send documents
- Link a document to an Opportunity in Salesforce
- Update a document with field values from Salesforce
- Variables: You can pass information from Salesforce to PandaDoc documents automatically with the help of variables.
- Products: Transfer product information from Salesforce deals to PandaDoc pricing tables.
- Create documents: You can create PandaDoc documents from Salesforce Opportunities, Accounts, Contacts, Leads, and custom objects.
- Status tracking: You can track document status in Salesforce.
- Sync data between Salesforce and PandaDoc (not available on Group and Professional editions)
Learn about PandaDoc’s integration with Salesforce in this course.
Connect PandaDoc and Salesforce
Note:view our setup guide found in the bottom right corner of the Salesforce tab in PandaDoc for a quick and easy integration setup.
- In PandaDoc, go to “Settings” > “Integrations” > Click on “Salesforce” > choose where you would like to enable the integration: Sandbox or Production environment
- You may need to log into Salesforce at this point. Click “Allow” to authorize PandaDoc access to Salesforce
- Your PandaDoc account is now connected to Salesforce. Proceed to installing the PandaDoc package on AppExchange as described in the next section
Install PandaDoc package on AppExchange
Note:You must have Salesforce Admin rights to install the PandaDoc module and configure it.
- Log into your Salesforce account: https://login.salesforce.com/
- You can find our application on SFDC AppExchange;
- Click on “Get It Now”;
- Click on “Install for All Users”, then click “Upgrade/Install”;
- Select, “Yes, grant access to these third-party web sites” and Click “Continue.”
- The installation process will start and might take a while. Click “Done” once it’s finished.
Configure the PandaDoc module for a Salesforce object
Note:The below instructions showcase Opportunity configuration but you can use this guide for any other object.
Warning:Salesforce account must have a My Domain to use the PandaDoc Lightning component.
- Open an Opportunity record
- In the top right corner, click the gear icon > Edit Page
- You will be transferred to the Edit mode where you can add the PandaDoc module to the page layout
- On the left panel, scroll down and find the PandaDoc Documents Lightning component
- Drag and drop it on the page layout, wherever you like
- You can add as many PandaDoc components as you like
- When you add it, adjust the component height and the display mode: Related documents will show all documents created from an Opportunity, Template selection will show templates to create documents from
- Save and Activate the component by clicking "Save" and "Activation" in the top right
Pass data from SFDC into PandaDoc
Passing Salesforce fields into PandaDoc
Before setting up your template with variables, create a variable list for each object you will use PandaDoc with.
Note:Variables must be set up for each object individually. Only the variables listed in that particular object will be available when creating a document from it (no cross-object population.)
- For that, click your App Launcher button, and go to Pandadoc Setup. Scroll down to “Salesforce to PandaDoc data flow” and click “Configure tokens”;
- Next, choose an object you want to modify tokens list for. If you have PandaDoc installed in another object, click “Add object”;
- You will see a default list of variables/tokens on the right. To add more, check the fields you want to add to the variables/tokens list and click “Save”;
- Open your PandaDoc template in a separate browser window, copy & paste variable names with the square brackets into the template.
- When you create a document from Salesforce using this template, the variables will be filled out with the information from the CRM.
Warning:Encrypted text field cannot be passed through a variable!
Note:In case the field in Salesforce is empty, the Variable in the document will not be populated and you will have to fill it in manually.
Passing Recipients from Salesforce to PandaDoc
Note:Passing recipients info best works with PandaDoc Roles. Learn how to setup Roles on a Template here.
By default Salesforce pushes the following recipient information depending on an object where your PandaDoc module is located:
- from Opportunity: Contact Role info
- from Account: Contact info + possible to push Account info
- from Lead: Lead info
- from Contact: Contact info
- from Quotes: Contact info
In case you pre-assign a recipient on the template level, they will be automatically assigned to the role when the document is created via Salesforce.
You can configure which field from Salesforce will be mapped to a Role in PandaDoc as well as set up which fields will be sent as the following parameters:
- First name
- Last name
- Company field
- Phone field
- Role field
- Go to App Launcher
- Click on 'PandaDoc Setup' in the App Launcher window.
- Select 'Configure Recipients'
Note:You will see default mapping for default objects. You can change them or add new mappings for custom objects.
If you want PandaDoc to automatically map recipient to specific Role, you need 2 things:
- Role field configured in the Recipients mapping;
- Have identical Role names in Salesforce and in the PandaDoc template;
If you have this set up right, PandaDoc will insert respective Recipient into the respective role when you will be creating documents.
Note:PandaDoc pulls all related contacts from Salesforce into the document. If you want to remove any, delete them on the role popup window or in recipients section on the document.
If you generate documents from a quote or a case, you might be using a lookup field to a specific contact record. You can specify what lookup fields to use as recipients by going to PandaDoc Setup > scrolling down to Object Customization settings. Find the object you need to set this up for and click Setup on the right-hand side.
Then choose the field to use as a recipient and click Save. You can choose up to five fields.
Next, set up the recipient mapping. And that's it!
You can filter contacts that get transferred into PandaDoc documents as recipients based on yes/no fields in a record (aka Boolean fields).
- Go to App Launcher > PandaDoc Setup > Configure Recipients;
- Scroll down to "Recipients Filtering";
- Click "Enable Filtering";
- Choose a field based on which value recipients will be filtered;
- Choose the value of the field based on which recipients will be filtered: true - yes, false - no.
If you have set up Recipient mapping for Accounts, you can then configure it to pass this Account info (email, phone # and etc) as a Recipient to PandaDoc.
For that, go to PandaDoc Setup -> Scroll down to JSON Builder Settings, next to the Account Object name click “Setup” -> Tick the box next to “Send Account as recipient” and click “Save”.
Salesforce Contact Roles and PandaDoc Template Roles cannot have 2 contacts assigned to one role.
Passing information from Salesforce into PandaDoc (via fields)
You can pass data into PandaDoc fields similarly to how variables operate. Unlike with variables, however, you don’t need to include square brackets.
In the list of tokens, copy the token without square brackets into Merge field.
Once the document has been sent, the recipient will see the pre-filled data and be able to update this field, provided the field has been assigned to them.
Passing product data into Pricing Table
PandaDoc can send Products from an Opportunity, Leads, Contacts or Account to a pricing table in a document. In this guide, we'll review how to pass Opportunity Products into PandaDoc, but the setup is the same for other objects.
First, map Opportunity product fields to pricing table fields.
- Go to PandaDoc Setup > PandaDoc Configure Pricing Items.
- Opportunity products will be displayed by default but you can select another object to set up the mapping for.
- Next, map Opportunity product fields to pricing table fields and click Save.
- Below, under Pricing Items Sorting, you can set up the order in which you want the products listed in the PandaDoc pricing table.
Now, set up the pricing table to accept products from Salesforce.
- Open your PandaDoc template, add a pricing table.
- Click on Properties at the top of the pricing table and in the right-hand settings, toggle on Data merge.
Note:Products might be passed to PandaDoc in an order different than the one listed in the Opportunity.
That's it for the setup! When you start a new document from an Opportunity (assuming products have been added to it), make sure you select your template. Products will be added to the pricing table. If certain fields are not displayed, click the plus sign on the right side of the pricing table and select the fields under Add hidden.
Pass custom product fields into pricing table
Sometimes, you need to pass more than the standard set of product fields.
- First, add Opportunity product fields into the tokens/variables list by going to PandaDoc Setup > Configure tokens. Select Opportunity product, and check the fields you need to pass on the right and they will show up in the tokens list on the left.
- Click Save. That's it for the setup!
- Make sure the pricing table in the template has Automatic import toggled on.
- When you create a document from the template, click the plus sign on the right side of the pricing table.
- Select the custom product fields under Add hidden.
If adding custom fields from hidden columns every time you create a document seems like too many clicks, there's a way around that.
- Create a document and unhide custom product fields.
- Then, click the vertical ellipses in the top right corner and select Convert to Template. Your new template will open in a new browser tab.
- In the template, you can delete the products from the pricing table, but make sure you keep the custom field columns.
- Next time you start a document from Salesforce, use this template. The columns will be populated with custom product field values.
Create and Send documents
Now that you've created and set up your template, you can proceed to creating and sending documents from Salesforce.
- Go to a record, find the PandaDoc module, click "New Document";
- Choose your template and assign recipients to roles, if applicable;
- Click "Start editing" and check your document: variables, content, recipients list, reminders and Send your document;
- You can now go back to the record in Salesforce and track your document status;
- When a document is completed, its .pdf will show up under Files in the record. (Although it is a part of the sync triggers functionality, it's enabled by default when you install the PandaDoc package.)
Add Files in your Object view
If you do not see Files in your object, you may need to add it to your object view.
To do this you will need to go back to the Object’s Page Layouts in the settings:
- From the Home screen, look in the top right corner for the Setup gear;
- Once in the Settings page, go into the Object Manager list and select Opportunity;
- In the Opportunity, go to Page Layout, and select Opportunity Layout;
- From the Opportunity Layout page, use the top toolbar to and find Related Lists in the toolbar and add Files under related lists, then save;
- Double-check your Opportunities to ensure Files can now be seen from the page.
Link a document to an Opportunity in Salesforce
If you have a document created in PandaDoc which you would like to link to an Opportunity in Salesforce, we’ve got you covered!
- In your PandaDoc tab, open the document, click the Salesforce icon on the right.
- Click “Link” and you will be prompted to login into your Salesforce account.
- Select an opportunity from the list then click “Link.”
- On the right, under Opportunity info, you can view the Opportunity’s created date, status and total amount. Please note, the opportunity info displayed in PandaDoc may need to be refreshed in order to ensure you are viewing the latest update.
- Now, go to the Salesforce opportunity record, and the document will be displayed in the PandaDoc module as if it was created through Salesforce.
In order to unlink a document from an Opportunity or link it to another one, click on the desired action on the Integrations panel. If you have created the document from another object (Account, Contact, etc.), you cannot unlink it from that object and link it to an Opportunity or view related information.
Update a document with field values from Salesforce
Note:The document must be in the Draft status for this feature.
If the information in a Salesforce record is updated after the document has already been created from this record, you can update the document with the correct values:
- In the document, go to the Integrations panel by clicking the Salesforce icon on the left inside the PandaDoc document
- Under Document data, select “Import from CRM”
- The variables will be updated with the latest information from Salesforce
- You can use the "Import from CRM" feature in any object in Salesforce: Opportunity, Account, Lead, Contact, custom objects.
If the field in Salesforce is empty, the corresponding variable won't be refreshed.
Warning:you cannot update your pricing table with product data from Salesforce, nor can you update PandaDoc fields or role variables.
How can I check my integration version?
Open your Salesforce, click on the plus sign at the top, type “installed packages” into Quick find, then click on the Installed packages section that appears in the search. Find PandaDoc among the installed applications and look up the version in the Version number column.
How can I provide the PandaDoc support team with access to my account in Salesforce?
The Support team might request access to your account in Salesforce to assist with an issue or question. Please do not grant access without the request of our Support team.
In Salesforce Lightning:
- Log into your Salesforce, click on your image (or avatar) in the top right, then click on Settings
- On the left in the small search box, type in "grant," then click below on Grant Account Login Access
In Salesforce Classic:
- Log into your Salesforce, then click on My Settings in the top right. (Alternately, click on your name, then on My Settings.)
- On the left in the small search box, type in "grant," then click below on Grant Account Login Access
Set the “Access duration” for "PandaDoc Support" for 3 days.
Next, email our Support team your SalesForce Organization ID found on the Company information page. Click Setup > Company profile > Company information and find the ID next to Salesforce Organization ID.
Click on a problem to unfold the solution.
PandaDoc module is blank or shows the following error message: “Attempt to de-reference a null object. An unexpected error has occurred.
This happens when the object for which you have set up variables, a pricing table, or recipients mapping is deleted or renamed.
You can fix it by following these steps:
- Make sure you have the latest version of the integration installed
- Go to PandaDoc Setup, click Configure Tokens, then open the object that shows the error message or a blank screen.
- Add any new field from the left column as a token/variable, then click Save.
- If the issue persists, go to Object customization settings on the PandaDoc Setup page, then click Setup next to the object where the error is shown.
- If a blank page opens, remove the object from the list, then re-add it.
PandaDoc module displays the error: “Unexpected token ‘FROM’ in opportunity”
If you see this message, you may not have permissions for certain Salesforce objects related to the opportunity. Possible examples are that files aren’t enabled for your profile, or perhaps your company recently added a new object that hasn’t yet been enabled for your profile.
To fix this, ask your Salesforce administrator to check permissions for your profile and make sure you have access to the related objects.
Contacts are not passed as recipients when you create a document from an opportunity
You may have just started testing the integration with test Contacts. It’s possible that no email addresses are associated with these Contacts in Salesforce. To fix this issue, add valid email addresses to the Contacts in Salesforce, then try again.
PandaDoc module isn't loading in Salesforce for some users in my account/ Some users in my account see Insufficient permissions error in the PandaDoc module
After that, you need to allow this user full access to 7 objects mentioned below. You can do so by going to the profile in question and pressing Edit, then scrolling down to the Custom Object Permissions.
- Doc Status
- Object Tokens
- PandaDoc Document
- PandaDoc Log
- Pricing Item Map
- Recipient Map
- Trigger Setting
Next, check access to the fields related to the 7 objects mentioned in the previous step. You can do that by going to the profile in question and scrolling down to the option Field-Level Security (Custom Field-Level Security), then pressing View for each of the 7 objects, Edit and allow read-only access to all the fields.