> ## Documentation Index
> Fetch the complete documentation index at: https://moengage.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Storyly

## Storyly

[Storyly](https://storyly.io/) is the user engagement platform to embed Stories. Storyly empowers the marketing strategies of mobile brands by enabling them to engage with their audience beyond the limits of the mobile screen and create engaging experiences without any development efforts after integration.

## MoEngage × Storyly

MoEngage × Storyly integration allows you to:

1. Send Storyly audiences to MoEngage using Storyly's [Create Audiences](https://docs.storyly.io/page/create-audiences-from-the-outcome-of-interactive-components)
2. Send MoEngage segments to Storyly using [MoEngage's Custom destinations](https://www.moengage.com/docs/user-guide/data/exports/segments/outbound-segment-sync)

## Integration

<Info>
  **Prerequisites**

  * Ensure you have a Storyly account.
  * You have to have your custom parameter setup between Storyly SDK & your app. [Learn more](https://docs.storyly.io/page/exporting-audiences-to-moengage).
  * Ensure that Custom destinations is enabled for your MoEngage account.
</Info>

## Sync Storyly's audiences to MoEngage

### Step 1: Setup MoEngage on Storyly

Let's start with connecting MoEngage account on Storyly Dashboard.

1. On your Storyly Dashboard, go to **Settings** and find **Integrations** tab.
2. Under **Integrations**, you'll see **MoEngage**. Please click on **Connect**.
   ![1280](https://files.readme.io/f8b5332-6.png)

When you click on **Connect**, you'll be asked to fill 3 fields which are:

| Field Name       | Description                                                                                                                                                                                                        |
| ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Integration Name | You may have more than 1 integration, that's why you can give any name to Integration as you want, to differentiate one from another.                                                                              |
| Workspace ID     | API ID is the Workspace ID. The Workspace ID of your MoEngage account is available at **Settings -> Account -> APIs -> Workspace ID**. The Data API ID and the Workspace ID of your MoEngage account are the same. |
| API Key          | The Data API key of your MoEngage account is available at **Settings -> Account -> APIs -> API keys -> Data** API settings.                                                                                        |

![1280](https://files.readme.io/debb78e-7.png)

3. Copy **DATA API ID** and **DATA API Key**, then paste them in the corresponding fields on the **Storyly Dashboard**.
   ![1280](https://files.readme.io/52e9812-8.png)
4. Once you click on **Connect MoEngage**, integration is completed!
   ![1280](https://files.readme.io/1fb8c2e-9.png)

From here, as referenced above, if you've created audiences from the outcome of interactive components in Storyly, you'll have an option to Export these Audiences to MoEngage.

### Step 2: Send audiences to MoEngage

1. Under **Settings > Data Management > Audiences**, you can see audiences that you've created. If you click on **Export** button, you'll see **Send to MoEngage** option.
   ![1280](https://files.readme.io/bd7028b-5.png)
2. When you click on **Send to MoEngage**, you'll be asked to choose which integration that you'd like to use and to give a **Key Title** for the Custom Attribute that you'll see on MoEngage.
3. After you click on **Start Process**, depending on the audience's size, it'll take couple of minutes for process to be completed.
   ![1280](https://files.readme.io/81f4652-12.png)

### Step 3: Create custom segments from Storyly Audiences

1. Once the process is completed, you can go to **MoEngage Dashboard**, navigate to **Segments** from the left pane and click on **Create Segment** option.
2. In that screen, please click on **User Property** and scroll down to find the custom attribute that you've exported from Storyly under **Tracked Custom Attribute** section.
   ![1280](https://files.readme.io/892c981-13.png)
3. After selecting the custom attribute, if you go with the **"is"** and type in the name of your Audience on Storyly Dashboard, you'll be able to create a segment that includes all of the users in that Audience.

## Sync MoEngage segments to Storyly

### Step 1: Create new audience for MoEngage

1. Go to *Audiences* tab on *Storyly Dashboard* and click on *+ New Audience* at the top right. Select the *Create Audience for MoEngage* option. You can give a name to your Audience and click on *Continue*.
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860692138260.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=df8bf5b80076c920280207ce63bb9eb7" alt="Screenshot_2023-04-14_at_12.48.24_PM.png" width="1984" height="1246" data-path="images/partner_14860692138260.png" />
2. *Storyly* will generate a **Key** and unique Token as **Value** for your Audience. Please copy these values, and you'll paste them on the MoEngage Dashboard while configuring the integration.

### Step 2: Setup custom destination on MoEngage

1. Navigate to *App Marketplace >> Custom Destinations*
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860636958484.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=452c9181e881a6309a26805f445a2080" alt="Screenshot_2023-04-14_at_12.43.35_PM.png" width="1664" height="1042" data-path="images/partner_14860636958484.png" />
2. Click *Add Custom Destination.*
3. Add *Destination name* as *Storyly* and description (optional).
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860669866516.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=8feafdd72b37a87158e03c59a3582480" alt="Screenshot_2023-04-14_at_12.44.25_PM.png" width="644" height="656" data-path="images/partner_14860669866516.png" />
4. Navigate to *Integrate* tab and click *Add Integration*
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860673919252.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=798df6a2e8cd0a177ef535ebc45f2fd4" alt="Screenshot_2023-04-14_at_12.45.29_PM.png" width="1372" height="436" data-path="images/partner_14860673919252.png" />
5. Now go back to the MoEngage Dashboard, and fill in the following details:
   * **Integration name:** you can give any name you'd like.
   * **Method:** Choose *POST* option.
   * **URL endpoint:** Enter the endpoint: `https://core.storyly.io/audience/moengage/export-callback`
   * **Parameters:** Click on *+KV pair* and paste the *Key* & *Value* that you've copied from the Storyly Dashboard in the previous step.
   * **User identifier:** Choose the identifier that you already pass to Storyly via Custom Parameter, which can be ID, e-mail, etc. Then enter *identity* in the *Destination identifier* field.
     <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860747067924.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=1144183b16b83f9d30e1d5e65c76f1f6" alt="Screenshot_2023-04-14_at_12.52.14_PM.png" width="1906" height="1126" data-path="images/partner_14860747067924.png" />
6. Click Next. You will now get an option to test the integration. You can enter a *User value* and click *Test* button. If the test is successful, you'll see the success message.
7. You can also choose to skip the test by directly clicking *Add Integration.*
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860736611860.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=d3aa0e2fa2b94cdf659a9923815fa412" alt="Screenshot_2023-04-14_at_12.55.12_PM.png" width="1916" height="1162" data-path="images/partner_14860736611860.png" />

### Step 3: Send segment to Storyly

1. Navigate to the *Segment,* click on three dots right next to the segment that you'd like to Import, and select the *Sync Segment* option.
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860894636820.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=ae36e8e4eb6a5ec055d27a06f2df822a" alt="Screenshot_2023-04-14_at_1.11.57_PM.png" width="1898" height="810" data-path="images/partner_14860894636820.png" />
2. Select the *Destination* as the Custom Destination that you've set up.
   <img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860895243796.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=e924dd8e788247b9f73b0b98b67b4a51" alt="Screenshot_2023-04-14_at_1.12.06_PM.png" width="1918" height="1200" data-path="images/partner_14860895243796.png" />
3. Select your *Sync Frequency* and other related details.
4. Click on *Save Sync*.

After this point, your MoEngage Segment will be synced to the Storyly Audience. You can view all your synced segments under the *Synced Segments* tab.

<img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860892704148.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=833bc202bb4de3d0e2f057a8c714e2a0" alt="Screenshot_2023-04-14_at_1.10.58_PM.png" width="1894" height="1182" data-path="images/partner_14860892704148.png" />

<img src="https://mintcdn.com/moengage/W4UIG2ZYu1ajYKNS/images/partner_14860886280596.png?fit=max&auto=format&n=W4UIG2ZYu1ajYKNS&q=85&s=37fa4198aed24531d4f1084113ab90a6" alt="Screenshot_2023-04-14_at_1.11.07_PM.png" width="1844" height="506" data-path="images/partner_14860886280596.png" />
