requestNotificationsPermission method

Future<bool?> requestNotificationsPermission()

Requests the permission for sending notifications. Returns whether the permission was granted.

Requests the POST_NOTIFICATIONS permission on Android 13 Tiramisu (API level 33) and newer. On older versions, it is a no-op.

See also:

Implementation

Future<bool?> requestNotificationsPermission() async =>
    _channel.invokeMethod<bool>('requestNotificationsPermission');