Skip to content

[firebase_messaging] Notification banner not showing on Android #1327

Closed
@MichaelM97

Description

@MichaelM97

When receiving an FCM from cloud functions in a Flutter app, on iOS the notification appears with a banner and in the system tray as expected. However, on Android the notification appears straight in the system tray without displaying a banner.

Shouldn't the behaviour be the same for both platforms when sending the exact same FCM?

Here is the FCM:

const payload = {
          notification: {
            title: 'You have a new message!',
            body: 'Tap to reply'
          },
          data: {
            click_action: 'FLUTTER_NOTIFICATION_CLICK',
            uid: sendingUserID
          }
        };

const options = {
      priority: 'high'
    };

admin.messaging().sendToDevice(token, payload, options);

Is there additional flag that I can set in options or the payload?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions