The Nexverse SDK provides a powerful and flexible solution for monetizing your iOS application through various ad formats. This guide walks you through the integration process and demonstrates how to implement each ad type effectively.

Prerequisites to Integrate the SDK

App Prerequisites

Before integrating the SDK, ensure your app meets the following requirements:

  • Minimum iOS Version: 12.0
  • Minimum Swift Version: 5
  • Minimum Xcode Version: 16.4

Account ID & Config ID

Account ID: It is a mandatory parameter to initialise the Nexverse SDK. You can obtain the accountId from Nexverse dashboard.

Config ID: A unique identifier based on the ad format and placement in your app. The SDK uses this ID to request and render appropriate ads for each placement. You can obtain the configId from Nexverse dashboard.

Installation

Initialization

Before using any of the SDK’s features, you must initialize it with your account configuration. This one-time setup should be performed as early as possible in your app’s lifecycle, ideally right after launch.

Here’s how to initialize the SDK in your AppDelegate:

Additional Configuration

Subject to GDPR

Based on user’s region and CMP (Consent Management Platform), GDPR (General Data Protection Regulation) properties need to be set. It should be set while initialising the SDK or before requesting for any ad.

Subject to COPPA

Based on user’s region and age, COPPA (Children’s Online Privacy Protection Act) property needs to be set. It should be set while initialising the SDK or before requesting for any ad.

Location Permission

It is recommended to include location permission in your app to improve ad targeting and provide a better advertising experience. If your app is not requesting for location permission already then it is recommended to use the method provided by Nexverse SDK to request the permission.

First add the below mandatory key value pair in your Info.plist. Update the value to a proper reason why your app needs location permission. Example: Your app name will use the device location to serve better and targeted ads.

  <key>NSLocationWhenInUseUsageDescription</key>
<string>A simple text that describes why your app needs the location</string>
  

Once your Info.plist is updated with necessary details, invoke the method to request location permission from appropriate place in your app.

Once user allows the access to location services, SDK will start using it automatically to serve better and targeted ads. You can change this preference by setting below flag to appropriate value. Set to true if SDK should be allowed the access to location, otherwise set to false.


Load & Render Ads

Nexverse provides all standard ad formats supported by market leaders. Each format is designed to maximize revenue while maintaining a great user experience.

Banner ads are a reliable way to monetize your app with minimal impact on user experience. The BannerView class handles the loading and display of banner ads, supporting various formats including image, video, and HTML (Rich Media).

Create and Load

Here’s how to implement a banner ad:

Delegate Events

Implement these delegate methods to handle banner ad events:


Interstitial Ads

Interstitial ads are full-screen advertisements that provide high-impact experiences at natural transition points in your app. The SDK supports both display and video formats through the InterstitialRenderingAdUnit class.

Create and Load

Here’s how to implement an interstitial ad:

Delegate Events

Handle interstitial ad events through these delegate methods:


Native Ads

Native ads offer the most customizable ad experience, allowing you to match your app’s look and feel perfectly. The SDK provides various classes to load and display native ads that integrate seamlessly with your UI.

Request Native Ad and Assets

Here’s a comprehensive implementation of native ads:

Delegate Events

Implement these methods to handle native ad events:


Rewarded Ads

Rewarded ads offer users in-app rewards for watching video advertisements. This format typically shows high engagement rates and provides a positive user experience through value exchange.

Create and Load

Here’s how to implement rewarded ads:

Delegate Events

Handle rewarded ad events through these delegate methods: