Warning: is_writable(): open_basedir restriction in effect. File(/var/www/clients/client2/web93/web/wp-content/uploads/broken-link-checker/blc-log.txt) is not within the allowed path(s): (/var/www/clients/client1/web15/web:/var/www/clients/client1/web15/private:/var/www/clients/client1/web15/tmp:/var/www/supersonic-knowledge.rtl.co.il/web:/srv/www/supersonic-knowledge.rtl.co.il/web:/usr/share/php5:/usr/share/php:/tmp:/usr/share/phpmyadmin:/etc/phpmyadmin:/var/lib/phpmyadmin) in /var/www/clients/client1/web15/web/wp-content/plugins/broken-link-checker/core/init.php on line 141
Getting Started with the Supersonic iOS SDK - Supersonic Knowledge Center

Getting Started with the Supersonic iOS SDK

To begin monetizing your application with the Supersonic SDK, follow these 2 easy steps:

  1. Add the Supersonic SDK to your project
  2. Create Supersonic Instance

Before You Start

Make sure you have integrated the latest version of our SDK. Find it here.
We support iOS versions 7 and up.

Note: If you are upgrading from a previous version of the Supersonic SDK, you must completely remove it from your project, otherwise it will cause issues with the update. We also recommend erasing older builds from test devices and making a new build.

Step 1. Add the Supersonic SDK to Your Project

Follow these steps to add the Supersonic SDK to your project:

  1. Add Supersonic Framework
    After you download the SDK; unzip it and add Supersonic.framework into your Xcode Project.
  2. Adding Required Frameworks
    Go to Targets ➣ Build Phases ➣ Link Binary With Libraries.
    Click ‘+’ to add the following frameworks:

    Foundation
    AVFoundation
    CoreMedia
    CoreVideo
    QuartzCore
    SystemConfiguration
    CoreGraphics
    CFNetwork
    MobileCoreServices
    libz.tbd
    StoreKit
    AdSupport
    CoreLocation
    CoreTelephony
    Security
    
  3. Status Bar Control
    To enable the Supersonic SDK to hide the status bar (even if your app displays it),
    in your info.plist, add the View controller-based status bar appearance flag’s value and set it to NO.
  4. Linker Flags
    Add the following linker flag to the build settings at:
    Target ➣ Build Settings ➣ Linking ➣ Other Linker Flags:
    ObjC
  5. iOS9 App Transport Security settings

    Important! In iOS9, Apple has added in controls around ‘ATS’. In order to ensure uninterrupted support for Supersonic Ad delivery across all Mediation Networks, it’s important to make the following changes in your info.plist:

    • Add in a dictionary called ‘NSAppTransportSecurity‘. Make sure you add this dictionary on the ‘Top Level Key‘.
    • Inside this dictionary, add a Boolean called ‘NSAllowsArbitraryLoads‘ and set it to YES.
      iOS9 App Transport Security Settings

Step 2. Create Supersonic Instance

Supersonic supports both Objective-C and Swift
If you are using Swift, read our Swift guidelines here before you continue on this document.

Follow these steps to create a Supersonic Instance:

    1. Import the following file:
      OBJECTIVE-C

      #import "Supersonic/Supersonic.h"

      SWIFT
      No import required with Swift.
    2. Create a Supersonic instance by calling the following method on your application start:
      OBJECTIVE-C

      [Supersonic sharedInstance];

      SWIFT

      Supersonic.sharedInstance()

    3. Optional: To receive detailed log events, you can register to the log delegate. Skip to Appendix A for more information.

 

Done!
You are now ready to start working with Supersonic’s Ad Units and Mediation Tools.


 

What’s Next?
Follow our integration guides to begin integrating your Ad Units:

Interested in Video mediation? Integrate our Rewarded Video and follow our mediation docs.

Appendix A – Registering to the Log Delegate

A log delegate is [] Before initializing the SDK you should first register to the log delegate for receiving detailed log events.

OBJECTIVE-C

[[Supersonic sharedInstance] setLogDelegate:YOUR_LOG_DELEGATE];

SWIFT

Supersonic.sharedInstance().setLogDelegate(YOUR_LOG_DELEGATE)