iOS SDK Integration

Follow

Before You Start

We support iOS version 8+. In case you use Xcode version lower than 9.3, we suggest archiving with 'bitcode' disabled.

Overview

This Guideline introduces the integration of AdTiming’s SDK in iOS Apps.

AdTiming offers diversified and competent monetization services and supports a variety of Ad formats including Native Ad, Interstitial Ad, Banner Ad, and Incentive Video Ad. The AdTiming platform mediates AdTiming, AdMob, Facebook, UnityAds, Vungle, Tapjoy, AppLovin, AdColony and Chartboost .

Interested in Mediation? Integrate our Rewarded Video, Interstitial or Banner Ads in your app and follow our Add Mediation Networks and Mediation Integration Guides.

 

Step 1. Add the SDK to Your Project

Importants!Since iOS SDK Version 4.0.0 and Above, the adapter for each ad network is modularized, which means that you need to download and add Not Only the SDK of mediation networks  you choose to work with But Also the adapters for those ad networks. For example, if you want to integrate AdMob and Applovin through AdTiming Mediation, you need to add the AdMob Adapter, AdMob SDK and Applovin Adapter, AppLovin SDK to the libs of your project. See the Add Mediation Networks for more infomation.

AdTiming supports both Cocoapods and manual download for SDK integration:

CocoaPods

CocoaPods is a dependency manager for Objective-C and Swift; it automates and simplifies the SDK integration process. See the CocoaPods Guide on Getting Started and Using CocoaPods for more information.

To integrate our SDK with Cocoapods, enter the following line in your podfile:

pod 'AdTimingSDK','4.1.0'

 

Manual Download SDK Latest release

Download iOS SDK Version 4.1.0

 

Step 2. Build Settings

1. Add Linker Flags

  • Add the following linker flag to the build settings at:
    Target ➣ Build Settings ➣ Linking ➣ Other Linker Flags:
-ObjC

2. App Transport Security Settings

  • Add in a Dictionary called 'App Transport Security Settings'. Make sure you add this dictionary on the 'Top Level Key'.

  • Inside this dictionary, add a Boolean called 'Allow Arbitrary Loads' and send it to YES.

    111111.png

 

Step 3. Initialize the AdTiming SDK

#import <ADTimingSDK/ADTimingSDK.h>
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[AdTiming initWithAppKey:@"YOUR_ADTIMING_APP_KEY"];
}

 

Set IAP Parameter (optional)

IAP, an acronym for in-App Purchase, can be understood as an in-app purchase. We need you to pass the current device user's IAP data to the SDK through the setIAP method in the APP so that we can provide more accurate advertising.

The parameter currency is a String represents the currency code of the ISO, based on the International Organization for Standardization's national code, is published in the ISO 4217:2008 standard and is used to represent money and funds.

You could set IAP any time after SDK initial successfully.

 [AdTiming userPurchase:12.5 currency:@"USD"];

 

GDPR (optional)

#import <ADTimingSDK/ADTimingSDK.h>
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
/// SetUserConsent @"0" is Refuse,@"1" is Accepted. Default is @"1"
[AdTiming setUserContent:@"1"];
}

 

COPPA

To protect children, AdTiming does not advertise for users under the age of 13, be sure to follow the following guidelines:

1. In order to add new application at AdTiming publisher platform and successfully create ad placement, you have to agree to the COPPA compatibility option. Please make sure your app is not designated as a child-directed mobile application. And if it is, please do not check the compatibility option.

222222.png

2. If your app is not a child-directed application but the users may include people under the age of 13, then you must have a mechanism in the app to determine whether the current user is over 13 years old. If the user is under the age of 13, please be aware that you should not initialize AdTiming SDK in the application for load&show ads. If your application initializes AdTiming SDK for load&show ads, we default that the current user for the app is 13 years old or above.

3. If you add a child-directed application at AdTiming publisher platform by using deceptive means or without proactively having a mechanism to determine whether the current user is under the age of 13, or if you have an actual knowledge that the current user is under the age of 13 but you still initialize the AdTiming SDK for load&show ads, AdTiming will not be held legally responsible and AdTiming reserve the right to pursue your legal liability.

0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.