# Integrate Network SDKs

## Partner Adapter Integration

Mediation adapters are required to use other ad networks with Mediation.

### Adapter Versioning Scheme

The partner adapter versions uses floating pegs and are formatted as follows:

```
<chartboost_mediation_sdk_major_version>.<partner_sdk_version>.<adapter_revision>
```
- **Chartboost Mediation SDK Major Version**: The major version of the Chartboost Mediation SDK that the adapter is compatible with.
- **Partner SDK Version**: The full partner SDK version that the adapter is compatible with. Note that this could be the traditional `major.minor.patch` version scheme, but there are some partners that have a `major.minor.patch.revision` version scheme.
- **Adapter Revision**: A sequential counter that identifies the revision of the adapter for a given partner SDK version. It increments when a new adapter release is made that is compatible with the same partner SDK version.

Examples:

| Partner    | Adapter Version | Chartboost Mediation SDK Major Version | Compatible Partner SDK Version | Adapter Revision |
| :--------- | :-------------- | :------------------------------------- | :----------------------------- | :--------------- |
| AdMob      | 4.21.5.0.2      | 4                                      | 21.5.0                         | 2                |
| IronSource | 5.7.2.5.1.0     | 5                                      | 7.2.5.1                        | 0                |

### Adapter Integration

Utilize our [Chartboost Mediation Adapters](https://adapters.chartboost.com/){:target="_blank"} below to compare which partners are ideal for you to integrate with. You can filter by ad format from the top right menu and compare selected partners. Click into the chosen partner for the latest supported partner adapter versions and integration guide or visit their [adapter repository](/en/mediation/integrate/ios/integrate-network-sdks/#adapter-repositories){:target="_blank"}.

**Be sure you are navigated to the iOS specific adapters from the top right menu.**

<iframe src="https://adapters.chartboost.com/" height="700" width="100%" style="border:1px solid black;" title="Chartboost Mediation Adapter"></iframe>

For CocoaPods users, Mediation adapters can be downloaded, along with their dependent ad network SDKs, by adding the following to your Podfile:

```ruby
# Chartboost Mediation Adapter for AdMob
pod 'ChartboostMediationAdapterAdMob'
  
# Chartboost Mediation Adapter for Amazon Publisher Services
pod 'ChartboostMediationAdapterAmazonPublisherServices'

# Chartboost Mediation Adapter for AppLovin
pod 'ChartboostMediationAdapterAppLovin'

# Chartboost Mediation Adapter for BidMachine
pod 'ChartboostMediationAdapterBidMachine'

# Chartboost Mediation Adapter for Chartboost
pod 'ChartboostMediationAdapterChartboost'

# Chartboost Mediation Adapter for Digital Turbine Exchange (Fyber)
pod 'ChartboostMediationAdapterDigitalTurbineExchange'
  
# Chartboost Mediation Adapter for Google Bidding
pod 'ChartboostMediationAdapterGoogleBidding'
  
# Chartboost Mediation Adapter for HyprMX
pod 'ChartboostMediationAdapterHyprMX'
  
# Chartboost Mediation Adapter for InMobi
pod 'ChartboostMediationAdapterInMobi'
  
# Chartboost Mediation Adapter for Liftoff Monetize (Vungle)
pod 'ChartboostMediationAdapterVungle'
  
# Chartboost Mediation Adapter for ironSource
pod 'ChartboostMediationAdapterIronSource'
  
# Chartboost Mediation Adapter for Meta Audience Network
pod 'ChartboostMediationAdapterMetaAudienceNetwork'
  
# Chartboost Mediation Adapter for Mintegral
pod 'ChartboostMediationAdapterMintegral'
  
# Chartboost Mediation Adapter for MobileFuse
pod 'ChartboostMediationAdapterMobileFuse'

# Chartboost Mediation Adapter for Pangle
pod 'ChartboostMediationAdapterPangle'

# Chartboost Mediation Adapter for UnityAds
pod 'ChartboostMediationAdapterUnityAds'

# Chartboost Mediation Adapter for Verve
pod 'ChartboostMediationAdapterVerve'

```

### Adapter Repositories





<table>
	<thead>
		<tr>
			<th>Partner Network</th>
			<th>iOS Repository</th>
		</tr>
	</thead>
	<tbody>
		
		
		<tr>
			<td>AdMob</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-admob">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-admob</a></td>
		</tr>
		
		
		<tr>
			<td>Amazon Publisher Services</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-amazon-publisher-services">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-amazon-publisher-services</a></td>
		</tr>
		
		
		<tr>
			<td>AppLovin</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-applovin">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-applovin</a></td>
		</tr>
		
		
		<tr>
			<td>BidMachine</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-bidmachine">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-bidmachine</a></td>
		</tr>
		
		
		<tr>
			<td>Chartboost Monetization</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-chartboost">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-chartboost</a></td>
		</tr>
		
		
		<tr>
			<td>Digital Turbine Exchange (Fyber)</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-digital-turbine-exchange">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-digital-turbine-exchange</a></td>
		</tr>
		
		
		<tr>
			<td>Google Bidding</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-google-bidding">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-google-bidding</a></td>
		</tr>
		
		
		<tr>
			<td>HyprMX</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-hyprmx">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-hyprmx</a></td>
		</tr>
		
		
		<tr>
			<td>InMobi</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-inmobi">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-inmobi</a></td>
		</tr>
		
		
		<tr>
			<td>Liftoff Monetize (Vungle)</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-vungle">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-vungle</a></td>
		</tr>
		
		
		<tr>
			<td>ironSource</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-ironsource">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-ironsource</a></td>
		</tr>
		
		
		<tr>
			<td>Meta Audience Network</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-meta-audience-network">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-meta-audience-network</a></td>
		</tr>
		
		
		<tr>
			<td>Mintegral</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-mintegral">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-mintegral</a></td>
		</tr>
		
		
		<tr>
			<td>MobileFuse</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-mobilefuse">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-mobilefuse</a></td>
		</tr>
		
		
		<tr>
			<td>Pangle</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-pangle">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-pangle</a></td>
		</tr>
		
		
		<tr>
			<td>Unity Ads</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-unity-ads">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-unity-ads</a></td>
		</tr>
		
		
		<tr>
			<td>Verve</td>
			<td><a href="https://github.com/ChartBoost/chartboost-mediation-ios-adapter-verve">https://github.com/ChartBoost/chartboost-mediation-ios-adapter-verve</a></td>
		</tr>
		
	</tbody>
</table>



## Partner SDK Integration


<table>
<tbody>
  <tr>
    <th style="width:40%">Partner SDK Integration Docs</th>
    <th style="width:60%">Additional Integration Notes</th>
  </tr>

  <tr>
    <td><a href="https://developers.google.com/admob/ios/quick-start" target="_blank">AdMob/Google Bidding</a></td>
    <td>
      <li>For <b>AdMob SDK 10.0.0+</b> and <b>Google Bidding SDK 10.0.0+</b>, Google SDK requires iOS 12 to serve ads.</li>
      <li>For Google SDK versions 11+, iOS 13 is required in order to receive ads.</li></td>
  </tr>

  <tr>
    <td><a href="https://ams.amazon.com/webpublisher/uam/docs/aps-mobile/ios" target="_blank">Amazon Publisher Services</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://dash.applovin.com/docs/integration#iosIntegration" target="_blank">AppLovin</a></td>
    <td></td>
  </tr>

  <tr>
    <td>Bidmachine</td>
    <td>To integrate with Bidmachine SDK, contact your Bidmachine account manager.</td>
  </tr>

  <tr>
    <td><a href="en/monetization/integrate/ios/get-started/" target="_blank">Chartboost Monetization</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://developer.digitalturbine.com/hc/en-us/articles/360010915618-Integrating-the-iOS-SDK" target="_blank">Digital Turbine Exchange (Fyber)</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://documentation.hyprmx.com/ios-hyprmx-sdk/" target="_blank">HyprMX</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://support.inmobi.com/monetize/sdk-documentation/ios-guidelines/overview-ios-guidelines" target="_blank">InMobi</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://developers.ironsrc.com/ironsource-mobile/ios/ios-sdk" target="_blank">ironSource</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://support.vungle.com/hc/en-us/articles/360002925791" target="_blank">Liftoff Monetize (Vungle)</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://developers.facebook.com/docs/audience-network/setting-up/platform-setup/ios" target="_blank">Meta Audience Network</a></td>
    <td>Starting with <a href="https://developers.facebook.com/docs/audience-network/changelog-ios#5_4_0" target="_blank">Meta Audience Network 5.4.x</a>, there are additional frameworks that their SDKs require: <code>FBBSDKCoreKit_Basics</code> and the <code>AudioToolbox</code> framework.<br>
      <ul>
        <li><a href="https://github.com/facebook/facebook-objc-sdk/releases" target="_blank">FBBSDKCoreKit_Basics</a></li>
        <li><a href="https://developers.facebook.com/docs/audience-network/setting-up/platform-setup/ios/add-sdk" target="_blank">FBAudienceNetwork</a></li>
        <li>AudioToolbox - This can be added from Xcode</li>
      </ul>
      CocoaPods automatically integrates Meta Audience Network SDK, therefore manual import is unnecessary.
    </td>
  </tr>

  <tr>
    <td><a href="https://www.mintegral.com/en/publisher-platform/ios-sdk-integration_en/" target="_blank">Mintegral</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://www.pangleglobal.com/integration/integrate-pangle-sdk-for-ios" target="_blank">Pangle</a></td>
    <td></td>
  </tr>

  <tr>
    <td><a href="https://unityads.unity3d.com/help/ios/integration-guide-ios#basic-implementation" target="_blank">Unity Ads</a></td>
    <td></td>
  </tr>


</tbody>
</table>

## Partner Consents

All privacy and consent information is configured via the Chartboost Core SDK's [Consent Management Platform](/en/mediation/integrate/core/ios/integration/#consent-management-platform).

The Mediation SDK will utilize the TCFv2 string as part of auction requests, and will forward consent changes to the partner adapters. 

The following partners utilize complex non-IAB compliant privacy and consent signals that cannot be extrapolated from Core SDK consent signals. Last resort APIs will be exposed via that partner adapter’s `AdapterConfiguration` class and must be manually set.

#### HyprMX

```swift
// Set consent status directly on the adapter configuration
HyprMXAdapterConfiguration.setConsentStatusOverride(CONSENT_GIVEN)
```

#### Pangle

```swift
// Set consent status directly on the adapter configuration
PangleAdapterConfiguration.setGdprConsentOverride(consent) // this is an int
PangleAdapterConfiguration.setDoNotSellOverride(doNotSell) // this is an int
```

#### Unity Ads

```swift
// Set consent status directly on the adapter configuration
UnityAdsAdapterConfiguration.setGDPRConsentOverride(true)
UnityAdsAdapterConfiguration.setPrivacyConsentOverride(true)
```

#### Vungle

```swift
// Set consent status directly on the adapter configuration
VungleAdapterConfiguration.setGDPRStatusOverride(true)
VungleAdapterConfiguration.setCCPAStatusOverride(true)
```


<!-- New starting 4.7.0 ; Does not apply to 5.X 

## Setting Individual Partner Consents

Partner consent can be set on an individual basis using the following API. Using these partner consents will override the global GDPR and CCPA consent used for the Chartboost Mediation SDK with the partner-specific values.

When a consent value for a partner is not present in this dictionary, then general signals provided by calls to ``setUserHasGivenConsent(_:)`` and ``setCCPAConsent(_:)`` are used as fallback.


```swift
public var partnerConsents: [PartnerIdentifier: Bool]
```

iOS exposes `partnerConsents` as a standard Dictionary type. Thus, all the usual Dictionary operations are available when using `partnerConsents`.


### Getting Current Partner Consents
```swift
let consents = Helium.shared().partnerConsents
print(consents)
```

### Setting Single Partner Consent 
```swift
Helium.shared().partnerConsents["admob"] = true
Helium.shared().partnerConsents["mintegral"] = false
```
### Setting Multiple Partner Consent
```swift
Helium.shared().partnerConsents.merge(["admob": true, "mintegral": false], , uniquingKeysWith: { old, new in new })
```

### Individually Remove Partner Consents
```swift
Helium.shared().partnerConsents["admob"] = nil
Helium.shared().partnerConsents["mintegral"] = nil
Helium.shared().partnerConsents["vungle"] = nil
```

### Replacing Consent

To replace consent with an entirely new set of values:
```swift
Helium.shared().partnerConsents = ["vungle": true, "mintegral": true]
```

### Remove All Partner Consent
Globally set consents will re-apply if partner consents are cleared.
```swift
Helium.shared().partnerConsents.removeAll()
Helium.shared().partnerConsents = [:]  // this is equivalent to the previous line
```

### Partner Identifiers

| Partner                    | Partner ID           |
|----------------------------|----------------------|
| AdMob                      | admob                |
| Amazon Publisher Services  | amazon_aps           |
| AppLovin                   | applovin             |
| BidMachine                 | bidmachine           |
| Chartboost                 | chartboost           |
| Digital Turbine Exchange   | fyber                |
| Google Bidding (Google Ads)| google_googlebidding |
| HyprMX                     | hyprmx               |
| InMobi                     | inmobi               |
| ironSource                 | ironsource           |
| Liftoff Monetize (Vungle)  | vungle               |
| Meta Audience Network      | facebook             |
| Mintegral                  | mintegral            |
| MobileFuse                 | mobilefuse           |
| Pangle                     | pangle               | 
| UnityAds                   | unity                |
| Verve                      | verve                |

 -->

