# Customer.io

Add mobile event data to your customer profiles.

[Customer.io](https://customer.io/) is a behavioral email platform that
harnesses user activity and profile data to send targeted campaigns at scale.
With the Airship [Real-Time Data Streaming](https://www.airship.com/docs/reference/glossary/#rtds) and Customer.io integration, incorporate mobile
engagement data into your Customer.io profiles and run email campaigns based
on Airship events.

## Customer.io Integration Requirements

This integration requires these accounts:
   1. Customer.io
   1. Airship — Must include both:
      * Messaging
      * [Real-Time Data Streaming](https://www.airship.com/docs/reference/feature-packages/#data)

<!-- Commented out for DOC-1704.

* **Airship project**
  * [Named User](https://www.airship.com/docs/reference/glossary/#named_user) must be enabled for your project.

---

In order for Airship to send events to Customer.io, you need to register users in Customer.io and associate an email address. See [Integrating with Customer.io](https://customer.io/docs/basic-integration.html) for more information on registering users.

The important thing to remember is that your Airship [Named User](https://www.airship.com/docs/reference/glossary/#named_user) must match the identifier you send over to Customer.io in your `identify` call. In the next sections we'll show you how to set the Airship Named User to match your Customer ID.

### Client Code: iOS

In your iOS project, set the Airship named user to be the same ID you use in the Customer.io `identify` call.

```swift
UAirship.namedUser().identifier = "NamedUserID"
```


```obj-c
[UAirship namedUser].identifier = @"NamedUserID";
```


See [Mobile: Contacts](https://www.airship.com/docs/guides/audience/your-audience/)
for more detail.
### Client Code: Android/Fire OS

In your Android/Fire OS project, set the Airship named user to be the same ID you use in the Customer.io `identify` call.

```java
// Associate the channel to a Contact.
Airship.getContact().identify("NamedUserID");
```


See [Mobile: Contacts](https://www.airship.com/docs/guides/audience/your-audience/)
for more detail.

-->

## Configuring the Customer.io Integration 

You will need your **Customer.io Site ID** and **API key**, found in your [Customer.io dashboard Integration settings](https://fly.customer.io/).

In Airship:

1. Next to your project name, select the dropdown menu (
), then **Settings**.
1. Under **Project settings**, select **Real-Time Data Streaming**.
1. Under **Real-Time Data Streaming**, select **Customer.io**.
1. Follow the onscreen instructions to configure the integration.

Once you've configured the integration, we'll start sending events from this project
to your Customer.io instance, and they will appear in your user activity
stream.

The following example from the Customer.io dashboard shows an expanded custom
event and open event.

![Sample Customer.io event data in Airship](https://www.airship.com/docs/images/connect-customer.io-sample-data_hu_71514492b07fc6e6.webp)

*Sample Customer.io event data in Airship*
