Quickstart — iOS
1. Add the SDK
2. Initialize on launch
import UIKit
import AmplySDK
@main
class AppDelegate: UIResponder, UIApplicationDelegate {
static var amply: Amply?
func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
let config = AmplyConfig(
appId: "com.acme.app",
apiKeyPublic: "YOUR_PUBLIC_KEY",
apiKeySecret: "YOUR_SECRET_KEY",
defaultConfig: nil
)
AppDelegate.amply = Amply(config: config)
AppDelegate.amply?.setLogLevel(level: "debug")
return true
}
}3. Track your first event
4. Manage the session lifecycle
5. Verify in the dashboard
What's next
Related
Last updated