SDK Integration

👍

Supported iOS and Android versions

Fully supported on iOS 13 and up.

Fully supported on Android Lollipop (API 21)

Integration of the Smartlook SDK

  1. Add Smartlook to the other dependencies in pubspec.yaml:
dependencies:
  flutter_smartlook: <<current-flutter-sdk-version>>
  1. Create Smartlook.instance.
  2. Call start(), and then setProjectKey() You need to add your unique project key.
  3. Wrap your MaterialApp with SmartlookRecordingWidget.
import 'package:flutter/material.dart';
import 'package:flutter_smartlook/flutter_smartlook.dart';

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  final Smartlook smartlook = Smartlook.instance;
  @override
  void initState() {
    super.initState();
    smartlook.start();
    smartlook.preferences.setProjectKey('YOUR PROJECT KEY');
  }

  @override
  Widget build(BuildContext context) {
    return SmartlookRecordingWidget(
      child: MaterialApp(
        title: 'Flutter App',
        home: HomeScreen(),
    	)
    );
  }
}

📘

region property

The region property identifies the location of the data center where metadata for your organization is stored. However, this does not ensure that all user data is stored in this region. When implementing the SDK, be sure to input the REGION parameter value as shown in the Smartlook project settings. For more information on where to find your region, see Organization settings.

Smartlook can store metadata in the EU and North America. If you want to change your data storage location, contact Smartlook Sales or Support.

Smartlook can now record user sessions. Session recordings will appear in the Smartlook player shortly.

Recording when on a mobile network

The Smartlook SDK only uploads sessions when the device is connected to wifi. If you would like to upload your data when the device is on mobile data, you can enable Upload on mobile (cellular) data in project settings. For more information, see When will session recordings appear on my dashboard?

Mobile upload

Crash reports

Flutter supports native Android and iOS crash reports for Smartlook. When using third-party crash report services, we recommend that you add dSYMs to your app. For more information, see iOS: Crash reports using third-party services.

SDK update & migrations

The Migration guide describes the migration from version 1.x.x to version 2.x.x.