📱AdSter iOS-SDK Documentation
Overview
The AdSter iOS-SDK provides integration for multiple ad types, including Banner, Interstitial, Rewarded, RewardedInterstitial and Native Ads. To use the SDK, you need to configure ad requests, Initialise the SDK, and conform to the necessary protocols to handle ad events such as loading, impressions, and clicks.
Prerequisites
Use Xcode 16.0 or higher
Target iOS 13.0 or higher
SDK Initialisation
Before requesting any ads, you need to initialise the SDK. This is a one-time setup step that should be done at the start of your application.
Installation via CocoaPods
To integrate AdSter SDK into your Xcode project using CocoaPods, follow these steps:
Open your project's Podfile and add:
pod 'Adster', '~> 1.3.1'Run the following command in the terminal:
pod installAfter installation, close Xcode and open the .xcworkspace file instead of .xcodeproj.
Installation via SPM
In Xcode, install the AdSter SDK Swift Package by navigating to File > Add Package Dependencies.
In the prompt that appears, search for the below GitHub repository: https://github.com/adster-tech/orchestration-sdk-ios
Select the version of the AdSter SDK Swift Package you want to use. For new projects, we recommend using the Up to Next Major Version.
Update your Info.plist
If you don't have an admob account and want to test the initialization of the SDK, please also add these to the info.plist so that the SDK initialization can be completed.
Key - GADApplicationIdentifier
Value -ca-app-pub-3940256099942544~3347511713
Initialising the SDK
completionHandler: A callback to confirm whether the initialization was successful.
Ad Request
To request an ad, you need to initialize the AdSterAdLoader and configure it with the required parameters:
Parameters:
placement: Unique key for the ad placement.viewController: ViewController where the ad will be presented.publisherProvidedId: Identifier for the ad unit.customTargetingValues: Optional custom targeting values to personalize the ad request.
Last updated