# Migrate DocuSign templates from Sandbox to Production — DAL (DocuSign Apps Launcher) export # Purpose - Use DocuSign's DAL template export/import to preserve Salesforce merge fields embedded in the DocuSign-for-Salesforce templates (`dfsle__EnvelopeConfiguration__c`). - This document covers exporting templates via DAL from Demo/Sandbox, importing into Production, capturing new template IDs, and updating Salesforce `dfsle__EnvelopeConfiguration__c` records. - Includes instructions to create the `Short_Name__c` custom field required by our Apex classes and Flow. # Prerequisites - DocuSign admin access (Demo/Sandbox + Production) with permission to export/import templates via DAL. - Salesforce admin access to create fields and run Data Loader / `sfdx` commands. - `dfsle` (DocuSign for Salesforce) managed package installed in Production. - Optional: `sfdx` CLI or Data Loader for bulk CSV updates. # High-level steps 1. Export the DocuSign templates from Sandbox/Demo using DAL export. 2. Import the DAL package(s) into DocuSign Production. 3. Capture the new DocuSign template IDs for each imported template. 4. Create the `Short_Name__c` custom field on `dfsle__EnvelopeConfiguration__c` (if missing). 5. Prepare CSV mapping old→new template IDs. 6. Update (or insert duplicates of) `dfsle__EnvelopeConfiguration__c` records in Salesforce. 7. Validate by sending test envelopes through the Flow/Apex. # Detailed steps ## 1) Download templates from the source Salesforce org - Preconditions: you must have Salesforce and DocuSign admin permissions and DAL (DocuSign Apps Launcher v4.5+) installed in the org. ### Steps in the source org: 1. Open the Salesforce App Launcher (grid icon) and select View All. 2. Select DocuSign Apps Launcher. 3. In the left column select eSignature to open the eSignature Configuration page. 4. The Templates tab should be showing 5. On the eSignature Configuration page, locate the list of Envelope Templates. 6. Select the checkbox next to each template you want to download. 7. From the Create Template dropdown choose Download Template. 8. The page will refresh and show "Templates downloaded". Save the downloaded file(s) (ZIP) to your device. - Note: Salesforce prevents downloading templates larger than 4 MB. - Important: templates that include custom fields created by a specific user may not import cleanly into the destination org unless that creating user exists in the destination. Either add the creating user to the destination org before upload, or plan to rebuild the missing custom fields after import. ## 2) Upload templates to the target Salesforce org ### Steps in the target org: 1. Open the Salesforce App Launcher (grid icon) and select View All. 2. Select DocuSign Apps Launcher. 3. In the left column select eSignature to open the eSignature Configuration page. 4. The Templates tab should be showing 5. From the Create Template dropdown choose Upload Template. - Upload each Template file exported from the source org. - After upload, open each template and verify that merge fields (placeholders) are preserved and that the template content looks correct. ## 3) Create `Short_Name__c` on `dfsle__EnvelopeConfiguration__c` (if not present) Why: Our Apex and Flow expect a `Short_Name__c` field as a compact identifier. Create it before inserting/updating records so `Short_Name__c` values can be included in CSVs and UI pages. ### Steps for adding the Short_Name field: 1. Go to the Docusign Apps Launch eSignature Configuration page (should already be there from last step) 2. Click on Name of the top template (you can select any template). This will bring you into the template 3. Go to top Gear Icon Settings menu and Select "Edit Object" 4. This brings you to the Setup Object Manager for the Docusign Envelope Template 5. Click **Fields & Relationships** in left hand menu, then → **New**. 6. Select **Text** → **Next**. 7. Label: `Short Name` → API Name will be `Short_Name__c` → Length: `50` → Next. 8. Set Field-Level Security (visible to all profiles) → Next → Save.