Flutter based call recording app with native UI integration

5,118

Since there is no guide for integrating flutter with CallKit and ConnectionService ...

In short, mentioned via comments, you’ll have to refer to https://flutter.dev/docs/development/platform-integration/platform-channels to do it yourself by implementing platform-specific code such as CallKit/ConnectionService.

First, because there’s currently likely no Flutter library that has already conveniently packaged this up for you, at least not at https://pub.dev/flutter, so this is why you need to do it yourself.

Now, assuming all the restrictions, permissions, rooting, jailbreaking, etc. poses no issue to you, then you would need to implement these APIs natively in iOS/Android first, for example, Android:

@Override
public void onMethodCall(MethodCall call, Result result) {
    if (call.method.equals("recordCall")) {
        result.success(recordCall());
    }
}

Which will then allow you to call them from Flutter:

_recordCall() {
  var recording = await platform.invokeMethod('recordCall');
}

So don’t think of how to do this in Flutter, the above was the easy part.

Your perspective should be: how to do this on iOS/Android, because the magic is in recordCall()

Share:
5,118
Admin
Author by

Admin

Updated on December 06, 2022

Comments

  • Admin
    Admin over 1 year

    I am trying to get call-recording to work with native UI integration using flutter, CallKit (iOS) and ConnectionService (Android).

    Since there is no guide for integrating flutter with CallKit and ConnectionService or any other service to enable system-like call recording without root access or jailbreak, this question has come to existence. There are a lot of apps available for jailbroken devices and android does natively support call recording, but there is no concrete guide for implementing the same using flutter.

    Using flutter 1.7 with AndroidX support for back-compatibility of marshmallow+ ConnectionService.

    The expected result is to automatically record calls or prompt user to do so whenever there is an incoming call.

    Currently unable to do it at all, maybe I am missing something essential in the documentation or I don't have the sufficient know-how for the successful execution of creating a system-supported call-recording app using flutter.

  • orimdominic
    orimdominic over 4 years
    MOre like creating a library on it