---
title: "Connect Salesforce Marketing Cloud"
description: "Create an installed package with API access in Marketing Cloud, connect it, and send new sign-ups as contacts."
url: https://scratcher.io/help/integrations/salesforce-marketing-cloud
language: en
---

1. [Help center](https://scratcher.io/help)
2. [Integrations](https://scratcher.io/help/integrations)
3. Connect Salesforce Marketing Cloud

# Connect Salesforce Marketing Cloud

Create an installed package with API access in Marketing Cloud, connect it, and send new sign-ups as contacts.

With the Salesforce Marketing Cloud integration, everyone who signs up is created or updated as a contact in Marketing Cloud, with the email address as the contact key. Your Salesforce administrator will usually need to help with the setup.

## What you need

- A Salesforce Marketing Cloud account, and a user with access to **Setup** > **Installed Packages** (usually a Marketing Cloud administrator).
- A Scratcher plan that includes all native integrations. If the button is locked, see [Your trial, plans and what happens when the trial ends](https://scratcher.io/help/billing/trial-and-plans).

## Step 1: Create API credentials in Marketing Cloud

1. In Marketing Cloud, open **Setup** (from the menu under your name).
2. Go to **Apps** > **Installed Packages** and click **New**. Give the package a name, for example "Scratcher", and save.
3. Click **Add Component**, choose **API Integration** and then **Server-to-Server**.
4. Set the permissions listed below and save.
5. Open the component. Copy the **Client Id**, **Client Secret**, **Authentication Base URI** and **REST Base URI**.
6. Make sure the package has access to the business unit you want the contacts in (under **Access** on the package).
7. Find the external key of the data extension your team uses for Scratcher leads. In **Contact Builder** or **Email Studio**, open the data extension and copy its **External Key**.

## Permissions the package needs

Scratcher asks Marketing Cloud for exactly these scopes, so the component must allow them:

- **Contacts** > **List and Subscribers**: **Read** and **Write**. To find contacts by email and create or update them.
- **Data** > **Data Extensions**: **Write**.

Nothing else is needed.

## Step 2: Connect it to Scratcher

1. In Scratcher, go to **Settings** > **Integrations** and click **Salesforce Marketing Cloud**.
2. Fill in the fields:
    - **Auth Base URL**: the Authentication Base URI, for example `https://xxxx.auth.marketingcloudapis.com`.
    - **Rest Base URL**: the REST Base URI, for example `https://xxxx.rest.marketingcloudapis.com`.
    - **Client ID** and **Client Secret**.
    - **Data extension id**: the external key from step 1.
3. Click **Install integration**. Scratcher logs in to Marketing Cloud to check the details.

Both URLs must be Marketing Cloud API addresses (ending in marketingcloudapis.com). Other addresses are refused.

## Step 3: Turn it on in a campaign

1. In the editor, go to **Connect** > **Integrations** > **Salesforce Marketing Cloud** and click **Activate**.
2. If you have connected more than one account, choose it under **Select account**.
3. Under **Field mappings**, click **Add field mapping**, choose the Scratcher field and type the name of the attribute in Marketing Cloud in **External field name**.
4. Under **Filter by permissions (optional)**, choose your consent checkbox if needed.
5. Click **Save**, and then **Test**.

> Good to know: there is no list to choose, so Scratcher starts sending as soon as you click **Activate**. Activate it before the campaign goes live, or set up the mappings right away.

## What is sent

- The email address is used as the contact key and saved in the **Email Addresses** attribute set, with HTML emails turned on.
- First name and last name from your form are saved in **Email Demographics**.
- Your mapped fields are saved in the attribute set called **Custom Data**, with the names you typed. Ask your administrator to create that attribute set in Contact Builder with matching attribute names.

New sign-ups are sent within a minute or two, and the campaign's existing leads are sent when you activate it.

## Troubleshooting

- "All or some of the fields are invalid. The integration failed to validate the fields." when installing: check the two URLs, the client ID and secret, and that the package has the permissions above.
- Deliveries fail with an unknown attribute: an **External field name** doesn't match an attribute in **Custom Data**. Fix the name or add the attribute.
- "The Salesforce Marketing Cloud urls must be marketingcloudapis.com addresses.": install the integration again with the correct URLs.

Need a deeper connection with Salesforce, such as Sales Cloud? On Enterprise plans we can build it with you. [Book a meeting](https://scratcher.io/book-a-meeting).

Integrations

- [How integrations work](https://scratcher.io/help/integrations/how-integrations-work)
- [All integrations](https://scratcher.io/help/integrations/other-integrations)
- [Check the delivery status and resend leads](https://scratcher.io/help/integrations/delivery-status)
- [Connect HubSpot](https://scratcher.io/help/integrations/hubspot)
- [Connect Salesforce Marketing Cloud](https://scratcher.io/help/integrations/salesforce-marketing-cloud)
- [Connect Microsoft Dynamics 365 with Zapier](https://scratcher.io/help/integrations/microsoft-dynamics-365)
- [Connect Emarsys](https://scratcher.io/help/integrations/emarsys)
- [Connect Klaviyo](https://scratcher.io/help/integrations/klaviyo)
- [Connect Mailchimp](https://scratcher.io/help/integrations/mailchimp)
- [Connect ActiveCampaign](https://scratcher.io/help/integrations/activecampaign)
- [Connect Apsis One](https://scratcher.io/help/integrations/apsis-one)
- [Connect Drip](https://scratcher.io/help/integrations/drip)
- [Connect HeyLoyalty](https://scratcher.io/help/integrations/heyloyalty)
- [Connect Peytz](https://scratcher.io/help/integrations/peytz)
- [Connect Marketingplatform](https://scratcher.io/help/integrations/marketingplatform)
- [Connect Campaign Monitor with Zapier](https://scratcher.io/help/integrations/campaign-monitor)
- [Connect ActiveTrail with Zapier](https://scratcher.io/help/integrations/activetrail)
- [Connect Bloomreach](https://scratcher.io/help/integrations/bloomreach)
- [Connect Iterable](https://scratcher.io/help/integrations/iterable)
- [Connect Mapp](https://scratcher.io/help/integrations/mapp)
- [Connect Agillic](https://scratcher.io/help/integrations/agillic)
- [Connect Ortto](https://scratcher.io/help/integrations/ortto)
- [Connect Emarketeer](https://scratcher.io/help/integrations/emarketeer)
- [Connect Shopify](https://scratcher.io/help/integrations/shopify)
- [Connect Hello Retail](https://scratcher.io/help/integrations/hello-retail)
- [Connect 8,000+ apps with Zapier](https://scratcher.io/help/integrations/zapier)
- [Connect monday.com with Zapier](https://scratcher.io/help/integrations/monday-com)
- [Connect Asana with Zapier](https://scratcher.io/help/integrations/asana)
- [Connect Podio with Zapier](https://scratcher.io/help/integrations/podio)
- [Connect Intercom with Zapier](https://scratcher.io/help/integrations/intercom)

## Related articles

- [How integrations work](https://scratcher.io/help/integrations/how-integrations-work): Connect your email tool or CRM once, turn it on in each campaign, choose a list, map your fields and send only people who gave consent.
- [Check the delivery status and resend leads](https://scratcher.io/help/integrations/delivery-status): See which leads were sent to your tools, understand the error messages, fix the problem and send them again.
- [Connect HubSpot](https://scratcher.io/help/integrations/hubspot): Log in to HubSpot from Scratcher and create or update contacts with the properties you choose, step by step.

## Still need help?

Real people are here to help. If you already use Scratcher, the quickest way is the chat inside the platform.

- **[Chat with us](https://platform.scratcher.io/login)**

    Log in and click the chat button in the bottom-right corner. Rex answers right away, and our team is a click away.
- **[Book a meeting](https://scratcher.io/book-a-meeting)**

    A free 30-minute video call with our team: a tour, campaign ideas or help with your setup.
- **[Email us](mailto:contact@scratcher.io)**

    Write to contact@scratcher.io and we will get back to you.
