truhuddle_widget 2.0.0
truhuddle_widget: ^2.0.0 copied to clipboard
TruHuddle customer support for Flutter using the hosted widget with live messaging, voice notes and workspace settings.
TruHuddle Widget for Flutter #
Open customer support with the same design as your TruHuddle web widget.
Install #
flutter pub add truhuddle_widget
Add your Android package name or iOS bundle ID once in TruHuddle → Widget settings → Integration & Security. The package reads the installed app's identifier automatically.
Open support #
import 'package:truhuddle_widget/truhuddle_widget.dart';
await TruhuddleWidget.open(context, options: TruhuddleOptions(
appId: 'YOUR_APP_ID',
));
You can also prefill a guest's details:
TruhuddleOptions(
appId: 'YOUR_APP_ID',
name: 'Amara Johnson',
email: 'amara@example.com',
)
Your workspace controls the logo, colors, greeting and features. The hosted widget receives design updates automatically.
Signed-in customers #
For private account history, pass a session from your signed-in backend:
TruhuddleOptions(
appId: 'YOUR_APP_ID',
getSession: () async => TruhuddleSession.fromJson(
await yourApi.createSupportSession(),
),
)
You can pass session: yourSession directly instead. A callback can renew expiring sessions. Names and emails alone are guest details, not verified identity. Close support when the customer logs out or changes accounts. Verified customer guide.
Devices and permissions #
Requires Flutter 3.41+, Android API 24+, or iOS 13+ and an internet connection.
Android AndroidManifest.xml:
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
iOS Info.plist, if you enable voice notes or photos:
<key>NSMicrophoneUsageDescription</key>
<string>Record a voice note for support.</string>
<key>NSCameraUsageDescription</key>
<string>Take a photo to share with support.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>Share a photo with support.</string>
For iOS projects using CocoaPods, enable PERMISSION_MICROPHONE=1 in the permission_handler build settings described in its setup guide. Gallery selection uses the system picker; broad storage access is not requested.