You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#### Step 6 - Add callback to handle call in terminated state
382
+
383
+
When an iOS app is terminated, the Flutter engine is not running. The engine needs to be started up to handle Stream call events whenever a call is received by the app. The Stream SDK performs the job of running a Flutter engine instance whenever a call is received. However, on the app side, a callback handle needs to be registered that will connect to `StreamVideo`.
384
+
385
+
```dart
386
+
@pragma('vm:entry-point')
387
+
Future<void> _backgroundVoipCallHandler() async {
388
+
WidgetsFlutterBinding.ensureInitialized();
389
+
390
+
// Get stored user credentials
391
+
var credentials = yourUserCredentialsGetMethod();
392
+
if (credentials == null) return;
393
+
394
+
// Initialise StreamVideo
395
+
StreamVideo(
396
+
// ...
397
+
// Make sure you initialise push notification manager
0 commit comments