Flutter – CallKit Incoming not working in ios when app is in terminated

to impliment call kit i used flutter_callkit_incoming package and use local notification to trigger call kit.

so this is working in android when app is foreground or background but not working in ios background.

here are step which i follow for setup.

on flutter : https://github.com/hiennguyen92/flutter_callkit_incoming/blob/master/example/lib/main.dart

on app delegate : https://github.com/hiennguyen92/flutter_callkit_incoming/blob/master/example/ios/Runner/AppDelegate.swift

and for ios steup: https://github.com/hiennguyen92/flutter_callkit_incoming/blob/master/PUSHKIT.md

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>//lisent notificaiton in background and trigger call kit.
Future<void> _firebaseMessagingBackgroundHandler(RemoteMessage message) async {
debugPrint("-----[FIREBASE-BACK]------><><>Handling a background message: ${message.data}");
if (message.data['topic'] == 'screen.sharing.invite') {
showCallkitIncoming(data: message.data);
}
}
</code>
<code>//lisent notificaiton in background and trigger call kit. Future<void> _firebaseMessagingBackgroundHandler(RemoteMessage message) async { debugPrint("-----[FIREBASE-BACK]------><><>Handling a background message: ${message.data}"); if (message.data['topic'] == 'screen.sharing.invite') { showCallkitIncoming(data: message.data); } } </code>
//lisent notificaiton in background and trigger call kit.
Future<void> _firebaseMessagingBackgroundHandler(RemoteMessage message) async {
  debugPrint("-----[FIREBASE-BACK]------><><>Handling a background message: ${message.data}");
  if (message.data['topic'] == 'screen.sharing.invite') {
    showCallkitIncoming(data: message.data);
  }
}

Function implimention

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>//Here is full implimentation of showCallKitIncomeing function
Future<void> showCallkitIncoming({required Map<String?, dynamic> data}) async {
CallKitParams params = CallKitParams(
id: const Uuid().v4(),
nameCaller: 'APP Screen Sharing Call',
appName: 'APP Title', ///<<< this is also not working...
avatar: data['senderImageUrl'],
handle: data['senderName'],
type: 0, // 0 for audio and 1 for video
duration: 60000, //60 seconds
textAccept: 'Accept',
textDecline: 'Decline',
missedCallNotification: const NotificationParams(
showNotification: true,
isShowCallback: false,
subtitle: 'Missed call',
callbackText: '',
),
extra: <String, dynamic>{'guestRoomCode': data['guestRoomCode'], 'receiverName': data['receiverName']},
headers: <String, dynamic>{},
android: const AndroidParams(
isShowLogo: true,
textColor: "#ffffff",
actionColor: '#dda088',
backgroundColor: '#dda088',
isShowCallID: true,
isCustomNotification: true,
isShowFullLockedScreen: true,
isCustomSmallExNotification: true,
ringtonePath: 'system_ringtone_default',
incomingCallNotificationChannelName: 'screen_share_call',
missedCallNotificationChannelName: "screen_share_miss_call",
),
ios: const IOSParams(
iconName: 'AppIcon',
handleType: '',
supportsVideo: true,
maximumCallGroups: 2,
maximumCallsPerCallGroup: 1,
audioSessionMode: 'default',
audioSessionActive: true,
audioSessionPreferredSampleRate: 44100.0,
audioSessionPreferredIOBufferDuration: 0.005,
supportsDTMF: true,
supportsHolding: true,
supportsGrouping: false,
supportsUngrouping: false,
ringtonePath: 'system_ringtone_default',
),
);
await FlutterCallkitIncoming.showCallkitIncoming(params);
}
</code>
<code>//Here is full implimentation of showCallKitIncomeing function Future<void> showCallkitIncoming({required Map<String?, dynamic> data}) async { CallKitParams params = CallKitParams( id: const Uuid().v4(), nameCaller: 'APP Screen Sharing Call', appName: 'APP Title', ///<<< this is also not working... avatar: data['senderImageUrl'], handle: data['senderName'], type: 0, // 0 for audio and 1 for video duration: 60000, //60 seconds textAccept: 'Accept', textDecline: 'Decline', missedCallNotification: const NotificationParams( showNotification: true, isShowCallback: false, subtitle: 'Missed call', callbackText: '', ), extra: <String, dynamic>{'guestRoomCode': data['guestRoomCode'], 'receiverName': data['receiverName']}, headers: <String, dynamic>{}, android: const AndroidParams( isShowLogo: true, textColor: "#ffffff", actionColor: '#dda088', backgroundColor: '#dda088', isShowCallID: true, isCustomNotification: true, isShowFullLockedScreen: true, isCustomSmallExNotification: true, ringtonePath: 'system_ringtone_default', incomingCallNotificationChannelName: 'screen_share_call', missedCallNotificationChannelName: "screen_share_miss_call", ), ios: const IOSParams( iconName: 'AppIcon', handleType: '', supportsVideo: true, maximumCallGroups: 2, maximumCallsPerCallGroup: 1, audioSessionMode: 'default', audioSessionActive: true, audioSessionPreferredSampleRate: 44100.0, audioSessionPreferredIOBufferDuration: 0.005, supportsDTMF: true, supportsHolding: true, supportsGrouping: false, supportsUngrouping: false, ringtonePath: 'system_ringtone_default', ), ); await FlutterCallkitIncoming.showCallkitIncoming(params); } </code>
//Here is full implimentation of showCallKitIncomeing function
Future<void> showCallkitIncoming({required Map<String?, dynamic> data}) async {
  CallKitParams params = CallKitParams(
    id: const Uuid().v4(),
    nameCaller: 'APP Screen Sharing Call',
    appName: 'APP Title',                 ///<<< this is also not working...
    avatar: data['senderImageUrl'],
    handle: data['senderName'],
    type: 0, // 0 for audio and 1 for video
    duration: 60000, //60 seconds
    textAccept: 'Accept',
    textDecline: 'Decline',
    missedCallNotification: const NotificationParams(
      showNotification: true,
      isShowCallback: false,
      subtitle: 'Missed call',
      callbackText: '',
    ),
    extra: <String, dynamic>{'guestRoomCode': data['guestRoomCode'], 'receiverName': data['receiverName']},
    headers: <String, dynamic>{},
    android: const AndroidParams(
      isShowLogo: true,
      textColor: "#ffffff",
      actionColor: '#dda088',
      backgroundColor: '#dda088',
      isShowCallID: true,
      isCustomNotification: true,
      isShowFullLockedScreen: true,
      isCustomSmallExNotification: true,
      ringtonePath: 'system_ringtone_default',
      incomingCallNotificationChannelName: 'screen_share_call',
      missedCallNotificationChannelName: "screen_share_miss_call",
    ),
    ios: const IOSParams(
      iconName: 'AppIcon',
      handleType: '',
      supportsVideo: true,
      maximumCallGroups: 2,
      maximumCallsPerCallGroup: 1,
      audioSessionMode: 'default',
      audioSessionActive: true,
      audioSessionPreferredSampleRate: 44100.0,
      audioSessionPreferredIOBufferDuration: 0.005,
      supportsDTMF: true,
      supportsHolding: true,
      supportsGrouping: false,
      supportsUngrouping: false,
      ringtonePath: 'system_ringtone_default',
    ),
  );
  await FlutterCallkitIncoming.showCallkitIncoming(params);
}

Getting Notification when app is killed but call kit not showing up.

Apart from this i also want to how can i hide notification for this call only other notification need to show as usual.

Thanks in advance.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật