tencent cloud


Last updated: 2024-05-24 18:46:03
    This article explains how to replace the incoming call ringtone of TUICallKit, which is divided into application ringtone and offline push ringtone.

    Setting application ringtone

    There are two ways to set an application ringtone: replace the ringtone audio or call the Setting ringtone interface.

    1. Replace Audio File

    If you integrate the TUICallKit component via source code dependency, you can replace the three audio files in the assets\\audios folder to achieve the purpose of ringtone replacement:
    File Name
    Ringtone when initiating a call
    Ringtone when the call is disconnected
    Ringtone when receiving a call

    2. Set Ringtone Interface

    You can also set the incoming call ringtone through the setCallingBell interface.
    import 'package:tencent_calls_uikit/tencent_calls_uikit.dart';
    void setCallingBell() {
    TUICallKit.instance.setCallingBell('flie path');

    3. Setting Silent Mode

    If you do not need ringing, you can enable the silent mode through enableMuteMode.
    import 'package:tencent_calls_uikit/tencent_calls_uikit.dart';
    void enableMuteMode() {

    Setting Offline Push Ringtone

    1. iOS

    Voip push does not support custom Definition push ringtones. APNs push allows modifying the parameters call and groupcall in the interface params including TUIOfflinePushInfo.iOSSound Setting on the iOS platform for offline message ringtones.

    2. Android

    The interface supports Huawei, Xiaomi, FCM, and APNs.
    FCM's push ringtone is set as the application ringtone.
    For Huawei, Xiaomi, and APNs push ringtone settings, please set the TUIOfflinePushInfo.iOSSound's iOSSound and androidSound fields when calling Call and GroupCall.
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support