Salesforce Classic: Standard setup
Note:
Get ready for the most powerful PandaDoc experience yet. Upgrade to Editor 2.0 here.Not sure which version of our editor you're using? Find out here.
Note:
This guide covers the functionality of the latest 1.51 version of the PandaDoc <> Salesforce integrationSkip to:
Plan availability:
PandaDoc: Enterprise
Salesforce: "Essentials" "Professional", "Enterprise", "Unlimited", or "Developer edition".
What can you do with the integration?
- Create and send documents from Salesforce Opportunities, Leads, Contacts, Accounts, or Custom objects records;
- Pull Salesforce records information into PandaDoc documents;
- Automatically populate pricing tables with Salesforce products;
- Use Salesforce contacts as document recipients;
- Sync data between Salesforce and PandaDoc (not available on Group and Professional editions)
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 under Salesforce object.
Note:
The below instructions showcase Opportunity configuration but you can use this guide for the other objects (Opportunity, Lead, Account, Contact).Warning:
If you're using Lightning, follow this installation guide.If you want to add the PandaDoc module to a Custom object, learn more here.
- Go to any record under “Opportunity” and click on “Edit Layout.” In the “Opportunity Layout” module at the top, navigate to “Fields” and find “Sections";
- Click and drag “Section” to where you want PandaDoc to display on the Opportunity Layout. Once added, set up section properties. Name this new section “PandaDoc Documents.” Set the layout to “1-Column” and select “OK”;
- Go back to the “Opportunity Layout” module above. Find “Visualforce Pages” on the left and drag “PandaDoc” to the previously created section;
- On the right, click “Properties” and set the “Height (in pixels)” to at least 500. The larger the number, the larger the module is displayed in Salesforce;
- In the “Opportunity Layout” module above, click “Save” and wait for the layout to complete saving;
- Go to any record under “Opportunities” to check the “PandaDoc Documents” module.
Note:
if you created a Custom Object, please refer to this guide to learn how to add PandaDoc to Custom objects in Salesforce.





Pass data from SFDC into PandaDoc
In order to pass data from Salesforce to PandaDoc document, first you should create your template and set it up with Tokens (same as Merge Fields). Learn more about tokens here.
Important information about tokens: Although tokens can automatically populate information in your document, they can only be added/edited in templates, not documents.
Note:
if you want to pass data to PandaDoc which would be editable for Recipients, refer to paragraphs below with the prefix “(via Fields)”.Passing Salesforce fields into PandaDoc (via tokens)
Before setting up your template with tokens, create a tokens list for each object you will use PandaDoc with.
Note:
tokens must be setup for each object individually. Only the tokens listed in that particular object will be available when creating a document from it (no cross-object population.)- For that, click “+” 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 tokens on the right. To add more, check the fields you want to add to the tokens list and click “Save”;
- Open your PandaDoc template in a separate browser window, copy & paste Token names with the square brackets into the template.
Warning:
Encrypted text field cannot be passed through a token!When you create a document from Salesforce using this template, the tokens will be filled out with the information from the CRM.




You can also review the list of tokens along with the data that will be passed in a Saleforce record.
Open a Salesforce record, scroll down to PandaDoc, click the gear icon in the top right corner of the module and choose Tokens - this is what you can pass;
Open your PandaDoc template in a separate browser window, copy & paste Token names with the square brackets into the template.
Note:
Token value passed to PandaDoc might be different from what the field looks like in Salesforce, see the second screenshot below. This is due PandaDoc passing the root field value, not the display value in some cases. Learn here how to format date fields that are passed from Salesforce.

Note:
in case the field in Salesforce is empty, the Token in the document will not be populated and you will have to fill it in manually.Passing Salesforce fields into PandaDoc (via Fields)
Similar to tokens, you can pass data into PandaDoc fields. Unlike the tokens, you will not need the square brackets.
Refer to this setup if you're using uploaded templates.
In the list of tokens found in Tokens list, copy the Token without the square brackets into the “Title” of the PandaDoc textfield.
Once the document is sent, the Recipient will see the data pre-filled and they will be able to update this field on their end.
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
You can configure which field from Salesforce will be mapped to a Role in PandaDoc as well as set up which fields will be send as the following parameters:
- First name
- Last name
- Company field
- Phone field
- Role field
- Go to PandaDoc Setup > Configure Recipients;
- You will see default mapping for default objects. You can change them or add new mapping 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 PandaDoc template;
- If you have this setup 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!




Filter recipients
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 "+" > 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”.
Note:
Salesforce Contact Roles and PandaDoc Template Roles cannot have 2 contacts assigned to one role.
If you have any suggestions regarding PandaDoc functionalities -> please submit an idea on the idea portal or email us at support@pandadoc.com.
Passing product data into Pricing Table
PandaDoc can be configured to pick Products from an Opportunity, Leads, Contacts or Account and add them to a pricing table in a document.
You can map product fields of an object to PandaDoc pricing table fields to pass data even more accurately.
- Go to PandaDoc Setup > Configure Pricing Items;
- Add an object you want to pass product data from and select which fields exactly you want to map to the PandaDoc pricing table, click “Save” once done;
- Below, under Pricing Items Sorting, you can set up the order in which you want the products listed in the PandaDoc pricing table;
- Now, just make sure your Opportunity, Lead, Contact or Account has products added. Then open your PandaDoc template, add a pricing table. In the right-hand settings, switch the toggle "Automatically add products to this table" to ON position.




Pass custom product fields into pricing table
- To view products' custom fields you can pass, click “+” and go to Pandadoc Setup. Scroll down to “Salesforce to PandaDoc data flow” and click “Configure tokens”;
- Next, choose "Opportunity Product";
- You will see a default fields list on the right. To add more, check the fields you want to add on the left and click “Save”;
- Don't forget to add your custom product information into your opportunity record.



Now you need to configure PandaDoc pricing table to accept custom product fields.
- Open your existing PandaDoc Template, find and click on your pricing table block.
- Click on “Add column” at the top right of the pricing table block to add a blank&plain column.
- Click on the column header and add the “Field Label” of the “Custom Product Field” you want in the pricing table.
- In the right sidebar, you will see “Column” settings. Check the box “Map column to custom field.”
- In the “Custom Field” box, enter in the “Product2.API Name.” For example, “Product2.Special_Notes.c” (you can find it in the products' custom fields and relationship section in Salesforce.)


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, scroll down to the PandaDoc module, click "New Document". If you're using Lightning, see this guide;
- Choose your template and assign recipients to roles, if applicable;
- Click "Start editing" and check your document: tokens, 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 2-way sync functionality, it's enabled by default when you install the PandaDoc package.)
If you have multiple workspaces and creating documents from Opportunities or Accounts in Salesforce, you can set it up so that documents from ALL workspaces are displayed in the PandaDoc module, see here more.



Link a document to an Opportunity in Salesforce
Note:
you need to have the latest integration version - 1.46.2 - installed.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, go to ...More > Link to Salesforce. You can link a document in any status
- Click “Link” and you will be prompted to login into your Salesforce account;
- Select a deal from the list then click “Link”
- On the right, under Opportunity info, you can view the Opportunity’s created date, status and grand 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
Warning:
if you are using the "Save PDF version of PandaDoc to Files" trigger, the document linked to an opportunity with this feature won't be attached to Files.



In order to unlink a document from an Opportunity or link it to another one, click the ellipses on the Integrations panel and choose an action from the dropdown.
Update a document with field values from Salesforce
Note:
the document must be in the Draft status for this feature.
The information in your Opportunity is updated after the document has already been created from or linked to the Opportunity? You can update your document with the correct values from the linked Opportunity:
- In PandaDoc, go to the Integrations panel by clicking ...More > Link to Salesforce inside the PandaDoc document
- Under Document data, select “Pull field values”
- The tokens will be updated with the correct information from Salesforce.
Warning:
you cannot update your pricing table with product data from Salesforce, nor can you update PandaDoc fields or role tokens.
