Skip to content Skip to main navigation Skip to footer

Merge Signatures into a Signed Document

This article will show you how to merge signatures into the body of a signed document, either by using merge signature fields or merging the image of a drawn signature. Please note that this feature is only available if using Opero Documents with Opero Signature for full automation.

Prior to setting up this feature, you should already be generally familiar with the fields on the eSign Doc object, especially the Merge Signature fields and how to use them. If not, check out our About the eSign Doc Object article.

Article Contents:

How to Merge Signature Fields

This configuration adds signer information into the body of the signed document.

  • In order to merge signature merge fields or signature image URL into your signed document the “Merge Signature Fields” checkbox must be updated to equal “true” after the eSign Doc record is created and before it is signed. To do this, create a record-triggered flow on the eSign Doc object, to run after an eSign Doc record is created. Add an Update Record element to update the “Merge Signature Fields” checkbox plus any other optional settings for the eSign Doc that triggered the flow. Recommended other optional settings are “require hand signature” and “attach signed document as PDF”. See the Optional Settings section of About the ESign Doc article for a list of all optional settings.
  • Copy and paste the desired merge fields from the Table of Merge Fields into the Google Doc template.
  • Adjust the font settings as desired, e.g. to make it appear more like handwriting or underline to show signature placement.
  • Change the font color of the merge fields to white so that the merge fields will be invisible to the recipient.
  • After the document is signed and the PDF is created, the text color will change to the color specified in the Signature Merge Field Color field of the eSign Doc record.
  • Once signed, the PDF on the eSign record shows the names of the people who signed the document where these merge fields were defined.

How to Merge the Image of a Drawn Signature

This configuration adds an image of the Signer 1, Signer 2, and Countersigner drawn signature into the body of the signed document.

  • In the Google Doc template, within the table where you are merging signature fields, create an inner table (one cell).
  • Copy the signature merge field from the Table of Merge Fields or see below:
    • Signer 1 signature image: {!esign__Document__c.esign__Signature_Image_URL__c[IMAGE]}
    • Signer 2 signature image: {!esign__Document__c.esign__Signer_2_Signature_Image_URL__c[IMAGE]}
    • Countersigner signature image: {!esign__Document__c.esign__Hand_Signature_Image_URL__c[IMAGE]}
  • Paste the signature merge field into the inner table.
  • Adjust the Table properties of the inner table. Right click the merge field inside the inner table. Go to Format>Table>Table properties.
    • Set the column width to a value such that the inner table appears small enough to fit within the outer table (see example below). Go to “Column” > Select “Column width” checkbox > Set a value (e.g. “3”). By defining the column width, the merged image will be resized to fit within that column width. This will control the size of the drawn signature image when it is merged.
    • Ensure this checkbox is NOT selected: Go to “Row”>”Allow row to overflow across pages”.
  • Test signing the document to check merge fields and confirm that the drawn signature image fits within the table.
  • Set the font color of all merge fields to white. This ensures that the merge code is invisible when sending the document for eSignature.
  • Set the table border color to white so that the inner table is not visible. Right click the merge field inside the inner table. Go to Format>Table>Table properties>Color>Change color to white.  
  • After the document is signed and PDF is created, the image will be displayed on the document and the font color of all merged signature fields will be changed to black by default.
    • You can customize the font color with a record triggered flow on the eSign Doc object that fires when an ESign Doc object is created. Set the “Signature Merge Fields Color” field to the hex color code of the desired color. Default is ‘000000’ (black).
  • If choosing to merge the Countersigner Image, you will additionally need to configure the following:
    • There is a URL field on the User object called Hand Signature Image URL. Add this field to  the page layout of the User object.
    • The Salesforce user who is the countersigner will paste the URL to their drawn signature image into this field on their user profile.
    • The image file must be a publicly available URL to the direct image. At this time, the field only supports merging a publicly available URL from a Salesforce Documents file (Classic only). For details, see Opero Documents Template Configuration article. Under the “Merge Images”, section see “Documents (Classic Only)” for steps.

Example nested tables to control the size of merge images

Table is shown with black borders so that you can see the configuration. Normally the borders of the nested table and the merge fields would be set to white. 

Example of drawn signature images merged into a signed PDF document

Table of Merge Fields

Listed below are merge fields that you can add to your Google Doc template to show signature information. All information about each field and its features is reviewed in About the eSign Doc Object.

FieldDescription
Signer 1 Name{!esign__Document__c.esign__Signed_By_Name__c}
Signer 1 Title{!esign__Document__c.esign__Signed_By_Title__c}
Signer 1 Company{!esign__Document__c.esign__Signed_By_Company__c}
Signer 1 Email{!esign__Document__c.esign__Signed_By_Email__c}
Signer 1 Date Signed{!esign__Document__c.esign__Recipient_Signed__c}
Signer 1 Signature Image URL{!esign__Document__c.esign__Signature_Image_URL__c[IMAGE]}
Signer 2 Name{!esign__Document__c.esign__Signer_2_Name__c}
Signer 2 Title{!esign__Document__c.esign__Signer_2_Title__c}
Signer 2 Company{!esign__Document__c.esign__Signer_2_Company__c}
Signer 2 Email{!esign__Document__c.esign__Signer_2_Email__c}
Signer 2 Date Signed{!esign__Document__c.esign__Signer_2_Signed__c}
Signer 2 Signature Image URL{!esign__Document__c.esign__Signer_2_Signature_Image_URL__c[IMAGE]}
Countersigner Name{!esign__Document__c.esign__Counter_Signed_By__r.Name}
Countersigner Title{!esign__Document__c.esign__Counter_Signed_By__r.Title}
Countersigner Company{!esign__Document__c.esign__Counter_Signed_By__r.CompanyName}
Countersigner Email{!esign__Document__c.esign__Counter_Signed_By__r.Email}
Countersigner Date Signed{!esign__Document__c.esign__Counter_Signed_Date__c}
Countersigner Signature Image URL{!esign__Document__c.esign__Hand_Signature_Image_URL__c[IMAGE]}
Email To Name{!esign__Document__c.esign__Email_To_Name__c}
Email To{!esign__Document__c.esign__Email_To__c}
Created By Date{!esign__Document__c.CreatedBy.Name}
Created By Title{!esign__Document__c.CreatedBy.Title}
Created Date{!esign__Document__c.CreatedDate}
Owner Name{!esign__Document__c.Owner.Name}
Owner Email{!esign__Document__c.Owner.Email}
Doc Link{!esign__Document__c.esign__Doc_Link__c}
eSign Link{!esign__Document__c.esign__eSign_Link__c}

How to create a signature merge field

If you would like to merge a signature field that is not listed above, it must exist on the esign doc object and it must be formatted with “esign__Document__c” before the field API name, separated by a “.”.

For example, {!esign__Document__c.esign__Signer_2_Name__c}.