init static method

void init(
  1. String appId,
  2. String appKey,
  3. String domain, {
  4. bool responseExpectationEnabled = true,
  5. bool teamMemberInfoVisible = true,
  6. bool cameraCaptureEnabled = true,
  7. bool gallerySelectionEnabled = true,
  8. bool userEventsTrackingEnabled = true,
  9. String? stringsBundle,
  10. String? themeName,
  11. bool errorLogsEnabled = true,
  12. bool showNotificationBanneriOS = true,
  13. bool fileSelectionEnabled = true,
})

Initialize Freshchat SDK with the necessary configuration

appId, appKey and domain can be found in Mobile SDK settings page of your Freshchat account.

Implementation

static void init(String appId, String appKey, String domain,
    {bool responseExpectationEnabled = true,
    bool teamMemberInfoVisible = true,
    bool cameraCaptureEnabled = true,
    bool gallerySelectionEnabled = true,
    bool userEventsTrackingEnabled = true,
    String? stringsBundle,
    String? themeName,
    bool errorLogsEnabled = true,
    bool showNotificationBanneriOS = true,
    bool fileSelectionEnabled = true}) async {
  await _channel.invokeMethod('init', <String, dynamic>{
    'appId': appId,
    'appKey': appKey,
    'domain': domain,
    'responseExpectationEnabled': responseExpectationEnabled,
    'teamMemberInfoVisible': teamMemberInfoVisible,
    'cameraCaptureEnabled': cameraCaptureEnabled,
    'gallerySelectionEnabled': gallerySelectionEnabled,
    'userEventsTrackingEnabled': userEventsTrackingEnabled,
    'stringsBundle': stringsBundle,
    'themeName': themeName,
    'errorLogsEnabled': errorLogsEnabled,
    'showNotificationBanneriOS': showNotificationBanneriOS,
    'fileSelectionEnabled': fileSelectionEnabled
  });
}