How to Copy Account Engagement Assets to Sandbox

How to Copy Account Engagement Assets to Sandbox

min. reading

As part of the Winter ‘24 release, Account Engagement users gained the ability to copy assets to and from Account Engagement Sandboxes. This allows marketers to test automations and assets before pushing them to their Production Account Engagement org. It also allows them to pre-populate Sandboxes with assets so they don’t have to start from scratch. 

The Account Engagement to Sandbox-to-Production Flow currently supports seven asset types: 

  1. Email Templates
  2. Custom Redirects
  3. Custom Fields
  4. Files
  5. Engagement Studio Programs
  6. Layout Templates
  7. Form Handlers

Account Engagement Sandbox-to-Production Flow Installation Instructions

To start using the Sandbox-to-Production flow, you will need to create a Connected App and two named credentials. 

Step 1: Create the Connected App in the Sandbox Org

This provides the interface to authenticate into an org.

  1. In your source org (Production), grab the Sandbox Asset Auth Flow callback URL.
    • Go to Setup > Auth. Providers
    • Open the Sandbox Asset Flow Auth
    • Copy the Callback URL, you will need this shortly
  2. In your Sandbox org, navigate to Salesforce Setup > App Manager and then select New Connected App.
  3. Configure the Connected App as follows:
    • Connected App Name: MCAE Sandbox to Production
    • Contact Email: Email Address of the admin who will be managing the Sandbox-to-Production promotion process. 
    • Enable OAuth Settings: Checked
    • Callback URL: The Source Org Callback URL you copied in step #1
    • Selected OAuth Scopes:
      1. Access the Salesforce API Platform (sap api)
      2. Access unique user identifiers (openid)
      3. Manage Pardot services (pardot_api)
      4. Manage user data via APIs (api)
      5. Manage user data via Web browsers (web)
      6. Perform requests at any time (refresh token, offline_ access)
    • Require Secret for Web Server Flow: checked
    • Require Secret for Refresh Token Flow: checked
  4. Select Save
    • Note: It may take 10-15 minutes for the connected app to be ready for authentication.
  5. Select Manage Consumer Details
  6. Copy your Consumer Key and Consumer Secret for later use.

Step 2: Update Auth Provider in Production Org

This handles the authentication process.

  1. In your Source Org (Production), enter the Consumer Key and Consumer Secret from your Connected App
    1. Go to Setup > Auth. Providers
    2. Open the Sandbox Asset Flow Auth
    3. Select Edit
    4. Enter the Consumer Key and Consumer Secret
  2. Select Save

Step 3: Create an Account Engagement API Named Credential

This establishes access via an integration user to the Account Engagement API.

  1. In your Source Org (Production), navigate to Setup > Named Credentials
  2. Select New Legacy
    1. Note: Do not select “New”, it should be “New Legacy”!
  3. Configure the Named Credential as Follows:
    1. Label/Name: MCAE API Access
    2. URL: https://pi.demo.pardot.com
    3. Identity Type:  Named Principle
    4. Authentication Protocol: OAuth 2.0
    5. Authentication Provider:  Sandbox Asset Flow Auth
    6. Scope: Pardot_api refresh_token
      1. Make sure this says “pardot_api refresh_token”, not just “api refresh_token”
  1. Start Authentication Flow on Save: Checked
  2. Generate Authorization Headers: Checked
  1. Select Save
  2. Log back into the Sandbox org with your credentials. Doing so finalizes the authentication for the named credential.

Step 4: Salesforce Metadata API Named Credential

This establishes access via an integration user to the Metadata API to retrieve BU details.

  1. In your Source Org (Production), navigate to Setup > Named Credentials
  2. Select New Legacy
    • Note: Do not select “New”, it should be “New Legacy”!
  3. Configure the Named Credential as Follows:
    • Label/Name: Metadata API Access
    • URL: https://mydomainsandboxname.sandbox.my.salesforce.com, but replace “mydomain” and “sandboxname” with the value from your sandbox url.
      1. ex: https://sercante–testing.sandbox.my.salesforce.com
    • Identity Type:  Named Principle
    • Authentication Protocol: OAuth 2.0
    • Authentication Provider:  Sandbox Asset Flow Auth
    • Scope: api refresh_token
    • Start Authentication Flow on Save: Checked
    • Generate Authorization Headers: Checked
  4. Select Save
  5. Log back into the Sandbox org with your credentials. Doing so finalizes the authentication for the named credential.

Running the Flow

Before you run the flow, ensure the destination org has at least one Folder, Campaign, and Tracker Domain. If your destination does not have these assets, you will run into issues with the flow.

  1. In your Source Org (Production), navigate to Setup > Flow
  2. Open the Account Engagement Sandbox-Production Bulk Asset Copy Flow
  3. Select Run
  4. For “Named Credential for Salesforce API Access” select the Metadata API Access (step 4 above)
  5. For “Named Credential for Account Engagement API Access” select the MCAE API Access (step 3 above)
  1. Select Next
  2. Select your direction of Copy
    • From a Sandbox to Production
    • From Production to a Sandbox
  3. Select your Production and Sandbox Business Units
  1. Select Next
  2. Select assets to copy over, select Next
  1. Confirm the Assets, select Next
  2. Select your Folder, Campaign, and Tracker Domain for your new assets
  3. Select Copy Assets
  4. The final screen will provide details regarding the copied assets as well as let you know if there were any errors.

Considerations for Using the Sandbox to Production Flow

Since this is a new capability for Account Engagement, there are some details and settings that do not come over when copied. I thoroughly tested each asset type and below are the considerations that I found.

Tracker Domain

You must verify the Tracker Domain in your Sandbox. Otherwise, Email Templates, Custom Redirects, and Files will fail when the unverified Tracker Domain is selected. You can use the default tracker domain (go.pardot.com) but this will cause issues when copying over any Custom Redirects with a Vanity URL.

Email Templates

  • When copied, the email sender will be replaced by a General User with the email [email protected]. This applies even if you have a sender hierarchy specified using “Assigned User” and ‘Account Owner.”
  • Email Templates containing Dynamic Content will not copy over. This is because dynamic content is unique to the Business Unit. Even if you have the same Dynamic Content in each Business Unit, they will have a different asset ID and merge tag.
  • If the Email Template contains a merge tag for a field that is not in the destination org, the flow will fail. Ensure all needed fields are copied to the destination org before copying over any assets that use custom field merge tags.

Custom Redirects

A Custom Redirect’s Completion Action(s) will not copy over, however, the Google Analytics Parameter values do.

Files

During my testing, I tested PNG, JS, JPG, GIF, SVG, CSS, and PDF file types, and all successfully copied over!

Custom Fields

When you copy custom fields, only the following information comes over:

  • Field Name
  • Field API Name
  • Field Type

Engagement Programs

  • When you copy an Engagement Studio Program (ESP) only the ESP structure is copied. The Recipient List, Suppression lists, Send days/times, and “Allow prospects to enter more than once” settings do not come over and will need to be reconfigured.
  • The assets specified in a Trigger or Action node, such as email templates, landing pages, and forms, will need to be reselected in the new ESP. However, the number of wait days specified in the node will copy over. 



  • If an Action node looks at a Prospect field (i.e. Prospect default field “Job Title” is not blank) and that field is in both Production and Sandbox, then the node will be copied to the new ESP with the field and value/settings specified. If the field does not exist in both Production and Sandbox, then the Action node will still be in the ESP but the field and value/settings will need to be reconfigured. 

Layout Templates

If you use Dynamic Content within your Layout Templates, keep in mind that the Dynamic Content will not come over when the Layout Template is copied. You can copy the Dynamic Content over as a separate asset, but you will still need to edit the Layout Template in your destination Business Unit to make sure it has the correct Dynamic Content ID.

Form Handler

  • Ensure all the fields on the Form Handler exist in the environment you are copying to before copying the Form Handler.
  • If your Form Handler only uses Default Prospect Fields, then all of the fields will come over when the Form Handler is copied. However, if your Form Handler uses any Custom Prospect Fields, the custom field needs to be in the destination org before you copy the Form Handler.
  • When copied, the Success Location and Error Location details will copy over to the new asset. Completion Actions do not copy over.

Now it’s even easier to work with Account Engagement Sandboxes!

This new Flow is a huge step toward making Account Engagement Sandboxes user-friendly for testing and staging. What other capabilities would you like to see in this Flow? Let us know in the comments!

Subscribe to The Spot

Hidden
Hidden
Hidden
Hidden
This field is for validation purposes and should be left unchanged.

Upcoming Salesforce Events

Salesforce Training Courses

Categories

Top 5 Recent Posts

  • Erin Duncan is the Account Engagement Product Director at Sercante. Erin is 8x Salesforce certified and has 12+ years of experience as a Salesforce and Account Engagement Admin. She is the leader of the Atlanta B2B Marketers User Group, the leader of the Pardashian Slack group, and a Salesforce Marketing Champion.

Leave Your Comment

Related Articles

Bot Single Post