Getting Started (iOS)
Introduction
FireworkVideo is a library to integrate video feeds from Firework - a short form video platform - into your iOS app.
To integrate FireworkVideo into your application, you have to register your application with Firework platform and get unique FireworkVideo app ID. To get the app ID:
Provide your application's bundle identifier or package name to the business team / engineering team you are co-ordinating with.
You will receive via email the app ID and then follow the setup steps below under Firework IDs to include both in your app.
The app ID is used to authenticate your application with the server. Authentication will fail if you use wrong app ID.
Requirements
FireworkVideo is compatible with:
iOS 13+
Xcode 14+
Swift 5.5+
Installation
FireworkVideo can be added as a Swift binary package using Swift Package Manager or it can be imported manually as framework. Instructions for both installation methods are below.
Importing Using Swift Package Manager
In your Xcode project, select File > Swift Packages > Add Package Dependency and enter the following URL: https://github.com/loopsocial/firework_ios_sdk.git
If you are new to Xcode's Swift Pacakage Manager integration, please refer to Apple's documentation on Adding a Package Dependency to Your App
Select Version > Up to Next Major > {Latest Version from CHANGELOG.md}
Latest version release notes can be found here
Importing Using Cocoapods
In your Podfile add FireworkVideo: pod FireworkVideo
and then run pod install
.
Importing FireworkVideo Framework Manually
Clone the SDK repo located at
https://www.github.com/loopsocial/firework_ios_sdk/
Download the SDK binary and unzip if needed.
Drag the unzipped
FireworkVideo.xcframework
into the Xcode project navigator and drop it at root of your project. Make sureCopy items if needed
checkbox is selected in the confirmation dialog. Check to make sure your project directory now hasFireworkVideo.xcframework
in it and it is visible and linked in your Xcode project navigator.In your apps Project pane select your app Target > Build Phases, click the + button, and add a Copy Files step. Select
Frameworks
as the destination and click the + within the Copy Files step and select FireworkVideo.xcframework. Your Copy Files step should look like below.
Configure App Id
Include the app ID in your app Info.plist
file using the key FireworkVideoAppID
see image below. If the app ID is not included or is included under a differently spelled key, the SDK will return an error. See Troubleshooting for more details.
Initialization
Before using any components video components are used you must initialize FireworkVideo
.
Start by importing the SDK into your App Delegate. Then initialize the Firework Video SDK in the App Delegate method application(:, didFinishLaunchingWithOptions:) -> Bool
.
Next
ATT compliance
Please refer to ATT compliance (iOS).
Video Feed
If you want to integrate the video feed, please follow the instruction here.
Story Block
If you want to integrate the story block, please follow the instruction here.
Customization
If you want to customize SDK, please refer to Customization.
Live stream support
If you want to integrate the live stream, please follow the instruction here.
Shopping
If you want to integrate video shopping, please follow the instruction here.
Analytics
If you want to integrate video shopping, please follow the instruction here.
Last updated
Was this helpful?