Follow

Integrate AerServ in Tapjoy IOS SDK

AerServ Mediation Overview

The following diagram illustrates the interaction between LTV Platform services, Tapjoy’s AerServ Adaptor, the AerServ SDK and adaptors / SDKs of optional video demand sources:

 

 

Required Software 
Tapjoy SDK:   IOS 
AerServ SDK:  IOS   
Adapter Code:  IOS 
Sample App:  IOS 
 
 
Prerequisites

These instructions assume you have ALREADY done the following:

  1. AerServ Account Setup
  2. Tapjoy Account Setup
  3. Integrate AerServ (Android SDK)
  4. Integrate the Tapjoy (Android SDK)
  5. Set up a placement and content unit in the Tapjoy dashboard and in your application:
    1. Setting up placements in the Tapjoy dashboard
    2. Connect a content unit to that placement
    3. Call using Tapjoy Android SDK placement code from your application’s code
  6. Test to make sure you can see Tapjoy content from your application. Download the sample app to verify integration.

 

Step 1: Xcode Project Setup

A. Adding the AerServ iOS SDK

  1. Extract aerserv-iso-sdk-latest.zip
  2. Copy lib & network-support to a temporary location
  3. In Xcode set Others Link Flag = -ObjC
  4. Set Framework Search Paths = *path_to_AerServ_Library* and select: recursive

 

 

  1. Add AerservSDK.framework to your project framework
  • Click the + button to link required frameworks and libraries to your project
  • Add AerServSDK.framework
  • Add libxml2.2.dylib
 


 

Required IOS 9 & XCode 7 integration:
 

Disable App Transport Security    

One of the changes in iOS9 is a default setting that requires apps to make network connections only over SSL; this is known as App Transport Security. We are working with our advertisers to ensure they are compliant. In the meantime, developers that want to release apps that build against iOS9 will need to disable ATS in order to ensure ads continues to work as expected.

  1. Open you project the info.plist 
  2. Add the following 
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowArbitraryLoads</key>
<true/>
<dict>

 

You can edit the plist by adding NSAppTransportSecurity key of dictionary type with a dictionary element of NSAllowsArbitraryLoads of boolean type set to “Yes”.

Disable Bitcode

  1. Go to project Build Settings
  2. Built Options 
  3. Enable Bitcode = No 

 

 

AerServSDK (Init method *Recommended) 

This method is  recommended if you are planning to use Adcolony, Vungle, Chartboost, Unity, Applovin SDK Mediation as it will improve ads delivery. 

  1. Import AerServSDK.h to AppDelegate.m  
  2. Add this line of code to Init AerServ SDK your SITE ID
  3. To locate your site ID - Click  Inventory Tab - Edit App - Look for APP ID
#import "AerServSDK/AerServSDK.h"
...
[AerServSDK initializeWithSiteID:@[@"SITE ID"]];

return Yes;

B. Adding Tapjoy AerServ Mediation Adapters: iOS

After downloading and unzipping the Tapjoy SDK, right-click the project icon in your project explorer in Xcode, then select "Add Files to "<your app name>"":

 

 

Navigate to the AerServ folder in the the Tapjoy SDK:

 TapjoySDK_iOS_<version>/Libraries/ThirdPartySupport/AerServ 

Choose the following files:

AerServCustomPlacement.h
AerServCustomPlacement.m
ASTapjoyInterstitialAdProvider.h
ASTapjoyInterstitialAdProvider.m
 

Then click "Add":

 

 

Step 2: AerServ Dashboard Setup: Add Tapjoy

To add Tapjoy to your AerServ waterfall, follow the instructions for adding an Ad Source on the AerServ dashboard. Make sure to prioritize the Tapjoy source at the top when testing Tapjoy.

Add the placement name you’re using on the Tapjoy dashboard as a publisher-specific parameter.

A. Adding an Ad Source

  1. Click the Ad Sources tab
  2. Click the + button to add an ad source
 

B. Fill in the Tapjoy Ad Source Details

  1. Enter a Name for the ad source (example: Tapjoy Android Interstitial)
  2. Select Tapjoy in the dropdown box
  3. Enter Tapjoy Placement Name (example: aerserv_config_video 
  4. Enter in the estimated CPM
  5. Select the Payment Terms
  6. Set Placement 
  7. Select Countries targeting (optional)
  8. Select Device targeting (optional)
  9. Click Save

 

C. How to locate your Tapjoy Placement ID:

  1. Click "Monetize" in the left menu bar
  2. Click the White "Manage Placement" button in the upper right corner of the dashboard.
  3. Select the Tapjoy Placement Name 

 

 

Step 3: Tapjoy dashboard Setup

A. Link your AerServ and Tapjoy Accounts and Applications

PLEASE NOTE: Tapjoy-AerServ account linking is strictly one-to-one: a single Tapjoy account links to a single AerServ account. It is not possible to link multiple Tapjoy accounts to a single AerServ account or vice-versa.

  1. Link your AerServ account to your Tapjoy account. From the Tapjoy dashboard, go to App Settings → Content → Mediation. Select “AerServ” as the Mediation Provider. Give the configuration a name of your choosing. Click Save:
  2. An “Authentication Status” section will appear. Click the “Login” button.
  3. Next you will see the AerServ login page. Enter your AerServ account credentials and click "Login."
  4. On the following confirmation page, be sure to select "Approve," then click "Submit":
  5. You will be redirected back to the Tapjoy App Settings page. Your accounts are now linked. Use the dropdown menus to select the AerServ app that corresponds to your current Tapjoy iOS and/or Android Tapjoy app. (If your Tapjoy app is only on a single platform, you can leave the other platform blank.)

 

 

Create a Mediated Content Card on the Tapjoy dashboard

  1. On the Tapjoy Dashboard, Go to "Monetize", then click the "Create Content" button in the upper right.
  2. Scroll down the list of content types until you get to Mediated Auto Play Video (also called "Direct Play")  or Mediated Display Ad (also called "FSI"). Select the appropriate content card and click the "AerServ" button:
  3. Fill out the resulting Content Card creation form. Be sure to select the Tapjoy placement at which you want the AerServ Mediated content to appear:
  4. In the "Network Settings" section, select the AerServ placement you want this Mediated Content Card to call from the dropdown menu:
  5. Click the green "Save" button on the bottom left:

Prioritize the Mediated Content Card on the Tapjoy dashboard

  1. Prioritize the Mediated Content Card you just created relative to the other Content Cards at that Tapjoy Placement. On the Tapjoy Dashboard, go to "Monetize", "Manage Placements":
  2. Drag the Mediated Content Card you just created up and down the placement to prioritize it. Content Cards on top of the stack are checked first:

  1.  By calling the Tapjoy placement from your application’s code, you should be getting AerServ mediated content (which may include Tapjoy content).

Step 4: Adding Additional Mediation Networks 

Instructions on the adding Additional Ad sources on AerServ dashboard

List AerServ Partners 

Here’s a list of SDK Mediation partners:

 

Step 5: Configure Rewards and Virtual Currency

iOS

// itemId = currency name specified on AerServ’s dashboard
// quantity = amount to reward
- (void)placement:(TJPlacement*)placement didRequestReward:(TJActionRequest*)request itemId:(NSString*)itemId quantity:(int)quantity

 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk