# Unity LevelPlay

This guide will instruct you step-by-step on how to set Chartboost live as an Ad Network on Unity LevelPlay mediation.

## Platform Integration
Integrate LevelPlay mediation SDK and Chartboost LevelPlay SDK adapter by following LevelPlay official guide:

[iOS integration](https://developers.is.com/ironsource-mobile/ios/chartboost-mediation-guide/#step-4)

[Android integration](https://developers.is.com/ironsource-mobile/android/chartboost-mediation-guide/#step-5)

[Unity integration](https://developers.is.com/ironsource-mobile/unity/chartboost-mediation-guide/#step-5)

## Supported integrations and ad formats

The Unity LevelPlay SDK exposes the native Chartboost SDK so you can access all native Chartboost interstitial, rewarded, and banner methods outside of the Unity LevelPlay SDK.

| Feature         | Supported |
|:---------------:|:---------:|
| **Integration**           |
| Bidding         |    ✓      |
| Waterfall       |    ✓      |
| **Formats**           |
| Banner          |    ✓      |
| Interstitial   |    ✓      |
| Rewarded        |    ✓      |


## Step 1: Set up configurations in Chartboost UI
[Sign up](https://platform.chartboost.com/signup) for a Chartboost account and [log in](https://platform.chartboost.com/login) once your account is verified. Then, navigate to the [Apps management](https://platform.chartboost.com/apps/overview) tab.

![](/assets/images/articles/chartboost_dashboard_apps.png)

Click the **Add new app** button to create your app. For details, see [Adding Apps](https://docs.chartboost.com/en/monetization/publishing/adding-your-first-app-and-campaign/#adding-apps).

![](/assets/images/articles/apps_management.png)

Fill out the rest of the form and click the **Add App** button to finalize your app.
![](/assets/images/articles/new_app_form.png)

After your app is created, you will be directed to its dashboard. Take note of the **App ID** and **App Signature** of your app.
![](/assets/images/articles/Chartboost_appIDappSignature.png)

Ensure your app successfully passes the [Publisher App Review](https://docs.chartboost.com/en/monetization/publishing/publisher-app-review/).


## Step 2: Activate Chartboost SDK network within Unity LevelPlay dashboard
If Chartboost is not yet active on your LevelPlay account, navigate to [Unity LevelPlay dashboard > Setup > Networks](https://platform.ironsrc.com/partners/next/networks), find **Chartboost**, and click **Setup**. 

![](/assets/images/articles/UnityLevelPlay_LevelPlayDashboard_activateChartboostNetwork.png)

Input your Chartboost User ID and User Signature. [Learn how to find them here](https://docs.chartboost.com/en/faq/analytics/#where-do-i-find-my-user-id-and-user-signature). Click "Save".
![](/assets/images/articles/UnityLevelPlay_LevelPlayDashboard_activateChartboostNetworkUserId.png)

## Step 3: Set up Chartboost Bidding and/or Waterfall locations on Chartboost dashboard and Unity LevelPlay dashboard
Unity LevelPlay supports both Chartboost Bidding and Chartboost Waterfall. Follow the guides below to set up Chartboost instances for your preferred mode:
* [Setup Chartboost Bidding Instances](#how-to-set-up-chartboost-bidding-instances-in-unity-levelplay)
* [Setup Chartboost Waterfall Instances](#how-to-set-up-chartboost-waterfall-non-bidding-instances-in-unity-levelplay)



## How to set up Chartboost Bidding Instances in Unity LevelPlay

**1. Create Bidding Ad Location**: On your Chartboost dashboard, [create Chartboost's ad location](https://docs.chartboost.com/en/monetization/publishing/ad-locations/) for your app.

* Set the **Ad Location Type** to **Bidding**.
* **Note the ad location name**, as you will need it for the LevelPlay setup.

![](/assets/images/articles/UnityLevelPlay_ChartboostDashboard_bidding_adLocation.png)

**2. Setup Bidding Ad Location on mediation**:  On your Unity LevelPlay dashboard,

2.1 Navigate to **LevelPlay dashboard > Setup > Instances**, select your app, and click on **Chartboost** under the **Bidding** section.
    ![](/assets/images/articles/UnityLevelPlay_LevelPlayDashboard_biddingNetwork.png)

You will see a dialog allowing you to input Chartboost's parameters:
    ![](/assets/images/articles/UnityLevelPlay_setupBiddingInstance.png)

2.2  Enter your Chartboost **App ID** and **App Signature**.
    * *These are found in the Chartboost dashboard under **[Apps Management](https://platform.chartboost.com/apps/overview)**, or [step 1](#step-1-set-up-configurations-in-chartboost-ui).*
    ![](/assets/images/articles/Chartboost_appIDappSignature.png)

2.3  Click "+ Add Instance" and select an ad format. 

In the **Location** field, enter the corresponding Ad Location Name from your Chartboost dashboard. *Important: This name must be an exact match.* 

You can give the instance any custom name in the **Instance Name** field.
    ![](/assets/images/articles/UnityLevelPlay_ChartboostDashboard_biddingAdLocation.png)

2.4  In the "Mediation groups" field, activate the instance on the applicable mediation group(s).


2.5.  Repeat these steps for each ad format, then click **Save**.

You're all set! Chartboost is now enabled as a bidding network.

## How to set up Chartboost Waterfall (non bidding) Instances in Unity LevelPlay

### 1. Set up the Chartboost Instance

- Log into your [Unity LevelPlay platform](https://platform.ironsrc.com/partners/login){:target="_blank"}  and navigate to Setup > SDK Networks. Click on the desired app from the list of applications. To the right, find Chartboost under Non Bidding, then click on Setup to create a Chartboost Instance.  
	![](/assets/images/articles/UnityLevelPlay_SDKNetworkSetup_waterfallNetworkSetup.png)

- Enter your Chartboost **App ID** and **App Signature** into the **App ID** and **App Signature** boxes. In your [Chartboost platform](https://platform.chartboost.com/){:target="_blank"}, navigate to **Apps Management** and select the app. The App ID and App Signature will be listed on the right column under **App information**.
	![](/assets/images/articles/Chartboost_appIDappSignature.png)  

	![](/assets/images/articles/UnityLevelPlay_AppSetting_waterfall_appidappsig.png)

- Select the ad type. Chartboost supports rewarded video, interstitial, and banner ads with Unity LevelPlay.
	![](/assets/images/articles/UnityLevelPlay_AppSettings_waterfall_adtype.png)

- Enter a value for **Location**. In the Chartboost platform, this is also referred to as an **Ad Location**. Login to your [Chartboost platform](https://platform.chartboost.com/){:target="_blank"}. Navigate to **Monetization** and select the app. Enter the Chartboost **Ad Location Name** to the Unity LevelPlay **Location** field. If there are no ad locations listed, then you will need to [create new ad locations](/en/monetization/publishing/ad-locations/) before continuing.  
- **Ad Location Name** can NOT be longer than 80 characters. Note: Chartboost [app country API](/en/advertising/reference/analytics-methods/) can provide data breakdown by `adLocation` values that cross a small threshold of activity (generally around 10 different ad creatives displayed, for example), otherwise they will not be broken out and instead aggregated under the `other` grouping.
	![](/assets/images/articles/Chartboost_adLocationName.png) 

- Set a country group. Learn more about [creating custom country groups](https://developers.is.com/ironsource-mobile/air/mediation-management-3/#step-4){:target="_blank"} in Unity LevelPlay.
	![](/assets/images/articles/UnityLevelPlay_AppSetting_waterfall_country.png) 

- Set a rate to manually assign a price for this instance’s waterfall prioritization. This field is optional. Learn more about Unity LevelPlay’s [rate setup](https://developers.is.com/ironsource-mobile/air/mediation-management-3/#step-3){:target="_blank"}.
	![](/assets/images/articles/UnityLevelPlay_AppSetting_waterfall_rate.png) 

- Continue on to the [Add More Chartboost Instances](#add-more-chartboost-instances-optional) section to add more Chartboost instances. Otherwise, click **Save** and continue to the next section.

#### Add more Chartboost Instances (Optional)

- To add more Chartboost instances, click on **+Add Network Instance**.
	![](/assets/images/articles/UnityLevelPlay_AppSetting_waterfall_addNetworkInstance.png) 

- When you have more than one instance, Unity LevelPlay will require you to set an **Instance Name**. We recommend using the **Location** name for the **Instance Name**.
	![](/assets/images/articles/UnityLevelPlay_AppSetting_waterfall_instanceName.png) 

- Enter another **Location** (in the Chartboost platform this is also referred to as an **Ad Location**) for the new instance.
- Set a country group.
- Enter a rate amount (optional).
- Repeat the steps above to add up to 10 different instances from Chartboost. Click on **Save** when finished.

### 2. Include Chartboost Instances in Mediation Groups

If you have more than one Mediation Group in Unity LevelPlay, please remember to include all the Chartboost instances in each of the Mediation Groups where you would like to serve Chartboost ads.
	![](/assets/images/articles/UnityLevelPlay_MediationManagement_groups.png) 

- To make sure Chartboost instances are included, login to the [Unity LevelPlay platform](https://platform.ironsrc.com/partners/login){:target="_blank"}, navigate to **Setup** > **SDK Networks**, click on the desired App from the list of Applications, find Chartboost under **Non Bidding**, then click on the **Edit** icon.
	![](/assets/images/articles/UnityLevelPlay_SDKNetworkSetup_edit.png) 

- Click on the **Mediation Groups** dropdown, and check on all the **Groups** that you would like to include Chartboost instances. This has to be done for each instance. By default, all groups are included.
	![](/assets/images/articles/UnityLevelPlay_SDKNetworkSetup_appSettingCountry.png) 

- Click on **Save** when finished.

### 3. Manually rank and top-rank Chartboost instances

When you have multiple instances in a Unity LevelPlay Mediation Group, you can then manually rank each instance. Utilize this tool to top-rank Chartboost.

To manually rank instances in a Unity LevelPlay waterfall, login to the [Unity LevelPlay platform](https://platform.ironsrc.com/partners/login){:target="_blank"}, and navigate to **Management** > **Mediation**.
1. Click on the desired App from the **Application** list.
2. Click on the desired **Mediation Group** in the group(s) list.
3. Click on the desired ad type (rewarded video, interstitial, banner).

_Note that by default, Unity LevelPlay puts you in the tab for rewarded video._

![](/assets/images/articles/UnityLevelPlay_MediationManagement_tiers.png) 


The steps below are using rewarded video as an example but the process is the same for interstitial and banner.

- Set a tier to **Manual**, then drag and drop Chartboost into that tier.
- Once you’ve positioned an instance of this ad source in this section, your app will serve ads from that ad source prior to any lower tiers, but not before any higher tiers. 
- Within manual priority, instances will deliver according to the order you place them, regardless of eCPM or rate.

Make sure you have manually ranked all the Chartboost instances properly. Any instances in lower tiers will be served after higher tiers in a waterfall. Within the **Sort by CPM** or **Optimized** option, Unity LevelPlay will pick the highest-ranking eCPM or rate instance at the moment to serve ads.

- If you have multiple Mediation Group(s), you will need to repeat Step 3 for each Mediation Group where Chartboost instances are included.
- To top-rank Chartboost, drag and drop Chartboost instances to the top of the highest tier.

The ad unit in the Mediation Group(s) will now be able to request ads with multiple instances from Chartboost (top-ranked first).
