The Zesty Ads SDK for visionOS enables developers to seamlessly integrate native advertising into their visionOS applications. Connect your app to the Zesty Network and start monetizing with high-quality, contextually relevant advertisements.
- 🎯 Native visionOS Integration - Built specifically for Apple's spatial computing platform
- 🖼️ Multiple Ad Formats - Support for banners, billboards, interstitials, and video ads
- 📱 Responsive Design - Automatic scaling and aspect ratio preservation
- 🔄 Fallback Handling - Default ads when network requests fail
- 📊 Analytics Integration - Built-in click and impression tracking
- 🚀 Easy Setup - Simple SwiftUI component integration
| Format | Dimensions | Use Case |
|---|---|---|
| Medium Rectangle | 300×250 | Standard banner ads |
| Billboard | 970×250 | Large horizontal banners |
| Mobile Interstitial | 640×1136 | Full-screen ads |
| Video | 1920×1080 | Video advertisements |
Add the Zesty Ads SDK to your Xcode project:
- Open your project in Xcode
- Go to File → Add Package Dependencies
- Enter the repository URL:
https://github.com/zestyxyz/zesty-ads-sdk-visionos.git - Click Add Package
- Select your target and add the ZestyAdsSDK library
- Add this repository as a package dependency via URL
- Under Targets → YOUR_TARGET → Build Phases → Link Binary With Libraries, add this package
You can see more comprehensive documentation here.
import SwiftUI
import RealityKit
import RealityKitContent
import ZestyAdsSDK
struct ContentView: View {
var body: some View {
VStack {
ZestyBannerView(adUnitId: "<YOUR_AD_UNIT_ID_HERE>", format: Formats.Billboard)
}
.padding()
}
}- Sign up for a Zesty Network account at zesty.market
- Create an ad space for your visionOS app
- Copy your Ad Unit ID (must be a valid UUID format)
- Ad Unit ID Validation: Your Ad Unit ID must be a valid UUID format. Invalid UUIDs will show default ads only.
- Network Connectivity: The SDK gracefully handles network failures by displaying default Zesty ads.
- Analytics: Click and impression tracking is automatically handled by the SDK.
The main component for displaying advertisements.
public init(
adUnitId: String,
format: Formats,
width: CGFloat? = nil,
height: CGFloat? = nil
)adUnitId: Your unique ad unit identifier (must be valid UUID)format: The ad format type (seeFormatsenum)width: Optional custom width (maintains aspect ratio if height not provided)height: Optional custom height (maintains aspect ratio if width not provided)
public enum Formats {
case MediumRectangle // 300×250
case Billboard // 970×250
case MobilePhoneInterstitial // 640×1136
case Video // 1920×1080
}swift buildswift testswift build -c debug- visionOS: 1.0+
- Swift: 6.0+
- Xcode: 15.0+
- Kingfisher (8.1.1+) - Efficient image loading and caching
We welcome contributions to the Zesty Ads SDK! Please feel free to submit issues and pull requests.
For technical support and questions:
- 📧 Email: contact@zesty.xyz
- 📖 Documentation: docs.zesty.xyz
- 💬 Discord: Join our community
Made with ❤️ by Zesty