Disable FCM firebase push notification sound FLUTTER

Viewed 202

How to disable sound when FCM is send, I want to send FCM without sound.. I'm able right now to send succesfuly FCM with sound

var body = jsonEncode(<String, dynamic>{
  'notification': <String, dynamic>{
    "body": userModel.userName  +' '+ 'Followed you',
    // 'title': "${userModel.userName}"
    'title':'',
    'sound':""
  },

  'priority': 'high',
  'data': <String, dynamic>{
    'click_action': 'FLUTTER_NOTIFICATION_CLICK',
    'id': '1',
    'status': 'done',
    "type": NotificationType.Follow.toString(),
    "senderId": userModel.userId,
    "title": "title",
    "body": userModel.userName  +' '+ 'Followed you',
    "postId": ""
  },
  'to': userModel.userName
});

    body: body);
print(response.body.toString());

}

0 Answers
Related