Quickstart
Pick your platform below. Every WhiskrKit SDK follows the same three steps: add the package, initialise once, and present a survey by identifier. Your API key is in the dashboard under Settings → API Keys.
1. Add the package. In Xcode, File → Add Package Dependencies, enter https://github.com/whiskrkit/whiskrkit-swift.git, and set the rule to Up to Next Major Version.
2. Initialise the SDK as early as possible; your App entry point is the right place.
import SwiftUIimport WhiskrKit
@mainstruct MyApp: App { init() { WhiskrKit.shared.initialize(apiKey: "wk_live_your_api_key") }
var body: some Scene { WindowGroup { ContentView() } }}3. Attach a survey. Add the .whiskrKitSurvey(identifier:) modifier to any view where a survey may appear. WhiskrKit evaluates eligibility automatically.
struct HomeView: View { var body: some View { Text("Welcome") .whiskrKitSurvey(identifier: "your-survey-id") }}1. Add the package. In your module’s build.gradle.kts (with mavenCentral() in your repositories and minSdk ≥ 26):
dependencies { implementation("eu.whiskrkit:whiskrkit-android:0.1.3")}2. Initialise the SDK from Application.onCreate() on the main thread.
import eu.whiskrkit.WhiskrKit
class MyApp : Application() { override fun onCreate() { super.onCreate() WhiskrKit.initialize(context = this, apiKey = "wk_live_your_api_key") }}3. Attach a survey. Wrap your root content in WhiskrKitHost once, then drop WhiskrKitSurvey on any screen.
import eu.whiskrkit.ui.WhiskrKitHostimport eu.whiskrkit.ui.WhiskrKitSurvey
setContent { WhiskrKitHost { HomeScreen() }}
@Composablefun HomeScreen() { WhiskrKitSurvey(identifier = "your-survey-id")}1. Add the package (requires the New Architecture):
yarn add react-native-whiskrkitOn iOS, the native SDK is a Swift package consumed via the cocoapods-spm plugin. See the React Native reference for the Podfile setup. On Android it resolves from Maven Central automatically (minSdkVersion ≥ 26).
2. Initialise the SDK once at startup. This also attaches WhiskrKit automatically; there is no component to mount.
import { initialize, checkAndPresent } from 'react-native-whiskrkit';
initialize('wk_live_your_api_key');3. Present a survey. Use checkAndPresent to respect eligibility, or present to trigger one directly.
checkAndPresent('your-survey-id');1. Add the package:
flutter pub add flutter_whiskrkitOn iOS, set your deployment target to 17.0; Flutter resolves the native Swift package automatically when Swift Package Manager support is enabled. On Android it resolves from Maven Central (minSdkVersion ≥ 26).
2. Initialise the SDK once at startup, e.g. in your root widget’s initState. This also attaches WhiskrKit automatically.
import 'package:flutter_whiskrkit/flutter_whiskrkit.dart';
final whiskrkit = FlutterWhiskrkit();
await whiskrkit.initialize('wk_live_your_api_key');3. Present a survey. Use checkAndPresent to respect eligibility, or present to trigger one directly.
await whiskrkit.checkAndPresent('your-survey-id');That’s it. WhiskrKit handles eligibility checks, presentation timing, and response submission.
Next steps
Section titled “Next steps”- Learn how surveys, presentation modes, and theming fit together in Core Concepts.
- See every method for your platform in the SDK Reference: iOS, Android, React Native, Flutter.