# Dynamic Yield By Mastercard Audiences Destination

> \[!IMPORTANT]
>
> This feature is in active development and may change before general availability.

## Destination Info

* Accepts [Track](/docs/segment/connections/spec/track) calls.
* Refer to it as **Dynamic Yield Audiences**, **Dynamic Yield by Mastercard Audiences** in the [Integrations object.](/docs/segment/guides/filtering-data/#filtering-with-the-integrations-object)
* This integration is **partner owned.** Please reach out to the partner's support for any issues.
* This destination is **Beta.**
* This destination is **only** compatible with [Twilio Engage.](/docs/segment/engage/)

[Dynamic Yield by Mastercard](https://www.dynamicyield.com/) helps businesses deliver digital customer experiences that are personalized, optimized, and synchronized.
With Dynamic Yield's Experience OS, you can algorithmically match content, products, and offers to each individual customer to increase revenue, build customer loyalty, and gain a sustainable competitive advantage.

This destination is maintained by Dynamic Yield by Mastercard. For any issues with the destination, [contact the Dynamic Yield support team](mailto:info@dynamicyield.com).

## Getting started

**Dynamic Yield by Mastercard Audiences** is an Audience Destination which must be first connected to an Engage Space before it can be connected to individual Engage Audiences. The steps below outline how to connect the Destination to an Engage Space and then to an Audience.

### Enable IP allowlisting

Dynamic Yield requires that data sent by Segment originate from a fixed IP range. As a prerequisite to using the **Dynamic Yield by Mastercard Audiences** Destination, Segment Business Tier customers must enable the **IP Allowlisting** feature on their workspace. This feature is only available for Segment Business Tier customers.

To enable IP allowlisting:

1. Navigate to **Settings > Workspace Settings > Destination IP Settings** in your Segment workspace.
2. Click **Enable IP allowlisting** to enable the feature.

### Create an instance of the Dynamic Yield Destination

1. From your Segment workspace, navigate to **Connections > Catalog**.
2. Use the search field to find the **Dynamic Yield by Mastercard Audiences** Destination, then select it.
3. Click **Add destination**.
4. Select the Engage Space you'd like to connect your destination to and click **Next**.
5. Enter a name for your destination and click **Create destination**.

### Configuring Basic Settings

1. Provide the Section ID and Connection Key on the Settings tab for your Dynamic Yield by Mastercard destination.
2. Enable the Destination using the toggle, then click the **Save changes** button.

### Create and configure a Mapping

You must first create, configure, and enable a Mapping before connecting your Audiences to the Dynamic Yield by Mastercard destination.

1. Navigate to the Mappings tab in the Dynamic Yield by Mastercard Destination.
2. Click **New Mapping** and select the **Sync Audience Action**.
3. Ensure that the only condition to trigger the mapping is **Event Type is Track** (remove the **Event Type is Identify** condition, if present).
4. Click **Save**.
5. Enable the Mapping from the Mappings tab using the **Status** toggle.

Once these steps have been completed you can connect Audiences to the Destination.

### Connecting Audiences to the Dynamic Yield by Mastercard Destination

1. Navigate to your **Engage Space > Audiences**.
2. Select the Audience you'd like to sync to your Dynamic Yield by Mastercard Audiences destination.
3. Click **+ Add destination**, select the **Dynamic Yield by Mastercard Audiences** Destination you connected earlier, and click **Add Destination**.
4. On the Audience Settings panel, provide a value for the following fields:
   * **Audience Name**: The name Segment uses when creating the Audience in Dynamic Yield.
   * **Identifier Type**: Select `userid`, `anonymousid`, or `email`. \* See [Customized Identifier Setup](#customized-identifier-setup) for how to configure identifiers other than userid, email or anonymousid.
5. Enable the **Send Track** toggle. You don't need to change the **Enter Event** or **Exit Event** fields, as these are not used by this Destination.
6. Click **Default Setup** panel under **Event settings**.
7. Click **Save** and then click **Add Destination**.

The Destination is now connected to your Audience and starts syncing data to Dynamic Yield.

### Customized Identifier Setup

The Dynamic Yield Audience Destination can accept identifiers other than userId, anonymousId or email. However, this requires some additional configuration steps when connecting the Audience to your Dynamic Yield Audiences Destination.

1. When connecting your Audience to the **Dynamic Yield Audiences** Destination, select the **Customized Setup** panel under **Event Settings**.
2. Click**Add identifier** then select the identifier type you'd like to use.
3. Provide a name for the identifier in the **Identifier in destination** field.
4. Scroll back up to the top of the Audience Settings panel and ensure that the **Identifier Type** field contains the name of the identifier you configured in the Customized Setup panel.
5. Click **Save** and then click **Add Destination** button.

The Destination is now connected to your Audience and starts syncing data to Dynamic Yield with the specified custom identifier.

## Destination Settings

| Field      | Description                            | Required | Type     |
| ---------- | -------------------------------------- | -------- | -------- |
| Access Key | Description to be added                | Yes      | password |
| Section ID | Dynamic Yield by Mastercard Section ID | Yes      | string   |

## Available Actions

Build your own Mappings. Combine supported [triggers](/docs/segment/connections/destinations/actions/#components-of-a-destination-action) with the following Dynamic Yield by Mastercard Audiences-supported actions:

> \[!NOTE]
>
> Individual destination instances have support a maximum of 50 mappings.

* [Sync Audience](#sync-audience-8)

### Sync Audience

Sync users to Dynamic Yield

Sync Audience is a **Cloud** action. The default Trigger is `type = "identify" or type = "track"`

| Field                | Description                                                                | Required | Type   |
| -------------------- | -------------------------------------------------------------------------- | -------- | ------ |
| External Audience ID | Unique Audience Identifier returned by the createAudience() function call. | Yes      | STRING |
| Audience Key         | Segment Audience key / name                                                | Yes      | STRING |
| Traits or Properties | Traits or Properties object                                                | Yes      | OBJECT |

## Engage

You can send computed traits and audiences generated using [Engage](/docs/segment/engage) to this destination as a **user property**. To learn more about Engage, schedule a [demo](https://segment.com/contact/demo).

For user-property destinations, an [identify](/docs/segment/connections/spec/identify/) call is sent to the destination for each user being added and removed. The property name is the snake\_cased version of the audience name, with a true/false value to indicate membership. For example, when a user first completes an order in the last 30 days, Engage sends an Identify call with the property `order_completed_last_30days: true`. When the user no longer satisfies this condition (for example, it's been more than 30 days since their last order), Engage sets that value to `false`.

When you first create an audience, Engage sends an Identify call for every user in that audience. Later audience syncs only send updates for users whose membership has changed since the last sync.

> \[!NOTE]
>
> Real-time audience syncs to Dynamic Yield By Mastercard Audiences  may take six or more hours for the initial sync to complete. Upon completion, a sync frequency of two to three hours is expected.

## Settings

Segment lets you change these destination settings from the Segment app without having to touch any code.

| Field      | Description                            | Required | Type     |
| ---------- | -------------------------------------- | -------- | -------- |
| Access Key | Description to be added                | Yes      | password |
| Section ID | Dynamic Yield by Mastercard Section ID | Yes      | string   |
