Skip to main content

Installation

Add the Pulse iOS SDK to your project and initialize it.

Requirements

  • iOS 13.0+
  • Swift 5.10+
  • Xcode 15.0+

Step 1 — Add the SDK

In Xcode: File → Add Package Dependencies, search for:

https://github.com/dream-horizon-org/pulse-ios

Add PulseKit to your app target. Or in Package.swift:

dependencies: [
.package(url: "https://github.com/dream-horizon-org/pulse-ios", from: "<version>"),
],
targets: [
.target(
name: "YourApp",
dependencies: [
.product(name: "PulseKit", package: "pulse-ios"),
]
),
]

CocoaPods

pod 'PulseKit', '~> <version>'

Then run pod install and open the .xcworkspace.

Check the latest release for the most recent version before adding the dependency.


Step 2 — Initialize the SDK

Initialize Pulse as early as possible — before any other code runs. The right place depends on your app's entry point.

AppDelegate

import PulseKit

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {

func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {

Pulse.shared.initialize(
endpointBaseUrl: "https://your-backend.com",
apiKey: "your-api-key"
)

return true
}
}

That's all that's required. With just endpointBaseUrl and apiKey, the SDK starts collecting:

  • ✅ URLSession network requests (all HTTP traffic)
  • ✅ Crashes (Mach exceptions, signals, NSException)
  • ✅ Screen transitions (UIViewController lifecycle)
  • ✅ App startup duration
  • ✅ Session tracking (every span gets a session.id)
  • ✅ App lifecycle events (foreground / background)
  • ✅ Device/App resource attributes (eg: app_version, device_name)
Want more?

See SDK Initialization for opt-in instrumentations — including session replay, tap tracking, and location.


Step 3 — Verify

if Pulse.shared.isSDKInitialized() {
print("Pulse is running")
}

Telemetry appears in your Pulse dashboard within seconds of the first app launch.

This covers the basics — but Pulse offers much more through initialize(): opt-in instrumentations, session replay, consent control, custom headers, and more. See SDK Initialization for the full configuration reference.


Next Steps