macOS SDK integration
Ship the macOS SDK binary inside your app bundle, sign it with the rest of your application, and start it after consent.
1. Install
# Bundle the binary inside your .app's Contents/MacOS/ directory.
curl -L https://getpassive.io/sdk/binaries/getpassive-sdk-macos-aarch64 -o getpassive-sdk
chmod +x getpassive-sdk
2. Initialize
// Swift — spawn after the user has accepted the consent screen.
let sdkPath = Bundle.main.path(forResource: "getpassive-sdk", ofType: nil)!
let task = Process()
task.executableURL = URL(fileURLWithPath: sdkPath)
task.arguments = [
"--dev-api-key", "${apiKey}",
"--device-uuid", stableDeviceUuid
]
try task.run()
// On opt-out / app close:
task.terminate()
3. Binary downloads
4. Lifecycle notes
- Place the executable in Contents/MacOS or another signed location inside your app bundle.
- Code sign the bundled binary together with your app so Gatekeeper sees one trusted bundle.
- Include the binary in your notarization upload and staple the notarization result before distribution.
- Terminate the Process when the user opts out or before app shutdown completes.
5. Consent flow
Start the SDK only after your app has shown the required disclosure and the user has accepted it. Use the shared consent guide for the wording and placement expectations.
6. Verify
Use the in-dashboard tester at app.getpassive.io for your app key, or follow the shared quickstart verification steps while the key is in test mode.
Last updated June 14, 2026