Skip to main content

Swift Video SDK

A Swift SDK that puts ads into your video player: a strip over the content, a card while it is paused, or a full-screen spot between episodes.
The Video SDK is a separate SDK from the Swift SDK for chat apps. It speaks the same ad server, but its model is the one video apps know from mobile ad SDKs: ask for an ad, look at its price, load it, show it at the moment you pick, and get one callback when it ends.

The three formats

Overlay

A strip across the player while the content plays. Ends by itself after its duration, or when the viewer closes it.

Pause

A card, or the full player, while the content is paused. Stays until the viewer resumes or you dismiss it.

Linear

A full-screen video at a moment you choose: between episodes, before a premium one. Skippable when the advertiser allows.

Requirements

  • iOS 14.0+
  • Swift 5.9+
  • Xcode 15+
You’ll need a publisher account to obtain your publisherToken.

Installation

Add the package, initialize the SDK, configure ATT and SKAdNetwork.

Showing your first ad

Create the video’s ads, get an ad, load it, show it: overlay, pause and linear.

API reference

Every type, method, callback and error.

Guides

Loading several ads at once, your own auction, no-fill, the playhead, and more.

Example app

A SwiftUI player with all three formats, runnable against your publisher token.