# Amplitude Engage Event Source

## Source Info

* The Amplitude Engage Event Source is an **Event Cloud** source. This means that it sends data as events, which are behaviors or occurrences tied to a user and a point in time. Data from these sources can be loaded into your Segment warehouses, and **also** sent to Segment streaming destinations. [Learn more about cloud sources.](/docs/segment/connections/sources#cloud-app-sources)

> \[!WARNING]
>
> This Source is only supported in workspaces configured to process data in the US region. Workspaces configured with data processing regions outside of the US cannot connect to this source. For more information, see [Regional Segment](/docs/segment/guides/regional-segment/).

This source combines Amplitude's analytics with Segment's rich connections ecosystem. This allows you to export Behavioral Cohorts from Amplitude to Segment so that you can better target users across their many downstream connections. You can sync Behavioral Cohorts to your Segment-connected raw data warehouses and downstream destinations that accept Segment `identify` events.

> \[!TIP]
>
> This page is about the Amplitude Engage Segment source, which sends data *to* Segment. For the Amplitude destination, which receives data *from* Segment, see the [Amplitude Segment destination](/docs/segment/connections/destinations/catalog/amplitude/) docs.

## Getting started

1. From your Sources page in Segment, click **Add source**.
2. Choose **Amplitude Engage**, then click **Connect**.
3. Give the Source a nickname. The nickname is a label used in the Segment interface.
4. From the new Source's Overview page, copy the Segment `writeKey`.
5. To export users from Amplitude to Segment, first, in Amplitude, create the cohort of users you wish to export. You can read more about the different
   types of cohorts you can create in [Amplitude's documentation](https://help.amplitude.com/hc/en-us/articles/231881448-Behavioral-Cohorts).
6. In your Amplitude account, navigate to your Behavioral Cohort and paste the Segment `writeKey` under "Sync to" -> "Add Integration" if the
   Segment integration is not already set up for your project.

**Note**: If you have just added the integration and do not see Segment in the list, refresh your page.

![Enable syncing to Segment.](https://docs-resources.prod.twilio.com/3d4e3d58b24322a2ed82231bf864fc670675ef4005dd34a5c3e167747043118c.png)

![Segment integration highlighted in list with active status in Amplitude.](https://docs-resources.prod.twilio.com/a8516acde4119eb7a254e4371b64c8c65634d5ee3b3dc353e15683dc4235c265.png)

![Dialog box for entering your Segment write key with Cancel and Save buttons.](https://docs-resources.prod.twilio.com/f99ab9eae241862cbb2ddd0fa84ebe0c97a8685875b335baf608230eb4b843ba.png)

7. If you would like to set up automated export on an hourly or daily basis, you can use Amplitude's Cohort Sync feature. Click **Advanced Preferences**, and select "Segment" as the integration.
8. From your Segment account, click into your Amplitude Engage Source, and you'll be able to add other downstream destinations where you want to see
   your Behavioral Cohort data.

Behavioral Cohorts will now sync to Segment based on the sync
schedule you defined in Amplitude.

## How Amplitude syncs cohorts

Amplitude sends cohort data to Segment by triggering an Identify call for each user in the cohort being synced, for example:

```js
analytics.identify({
  userId: <amplitude_user_id>,
  traits: {
    '[Amplitude] <some_cohort_name> (<cohort_id>)': true
  },
  context: {
    integration: {
      name: 'Amplitude Cohort Sync',
      version: '1.0.0'
    }
  }
})
```

Upon subsequent cohort syncs (manual or scheduled), Amplitude syncs only new users and users whose cohort status has changed (for example, a user has left a cohort). When a user has left a cohort, Amplitude sends `false` as the cohort trait value, for example:

```js
analytics.identify({
  userId: <amplitude_user_id>,
  traits: {
    '[Amplitude] <some_cohort_name> (<cohort_id>)': false
  },
  context: {
    integration: {
      name: 'Amplitude Cohort Sync',
      version: '1.0.0'
    }
  }
})
```
