NotificationIOS

iOS Only

The interface for iOS specific options which are applied to a notification.


To learn more about iOS notifications, view the iOS documentation for full examples and usage.

Properties

attachments

Optional array of IOSNotificationAttachment interfaces.

attachments?: IOSNotificationAttachment[];

Attachments allow audio, image, or video content to be displayed with the notification, enriching the user's experience.

View the Attachments documentation for more information and usage examples.

badgeCount

The application badge count number. Set to null to indicate no change, or 0 to hide.

badgeCount?: number | null;

categoryId

The id of a registered IOSCategory (via the setNotificationCategories API) that will be used to determine the appropriate actions to display for the notification.

categoryId?: undefined | string;

critical

iOS >= 12

If the notification is a critical alert set this property to true; critical alerts will bypass the mute switch and also bypass Do Not Disturb.

critical?: undefined | false | true;

criticalVolume

iOS >= 12

The optional audio volume of the critical sound; a float value between 0.0 and 1.0.

criticalVolume?: undefined | number;

This property is not used unless the critical: true option is also set.

foregroundPresentationOptions

Optional property to customise how notifications are presented when the app is in the foreground.

foregroundPresentationOptions?: IOSForegroundPresentationOptions;

By default, Notifee will show iOS notifications in heads-up mode if your app is currently in the foreground.

interruptionLevel

iOS >= 15

Value that indicate the importance and delivery timing of a notification.

interruptionLevel?: IOSNotificationInterruptionLevel;

launchImageName

The launch image that will be used when the app is opened from this notification.

launchImageName?: undefined | string;

sound

The name of the sound file to be played. The sound must be in the Library/Sounds folder of the app's data container or the Library/Sounds folder of an app group data container.

sound?: undefined | string;

If the file is not found in a container, the system will look in the app's bundle.

Use 'default' to use the default system sound.

summaryArgument

iOS >= 12

The argument that is inserted in the IOSCategory.summaryFormat for this notification.

summaryArgument?: undefined | string;

See IOSCategory.summaryFormat.

summaryArgumentCount

iOS >= 12

A number that indicates how many items in the summary are being represented.

summaryArgumentCount?: undefined | number;

For example if a messages app sends one notification for 3 new messages in a group chat, the summaryArgument could be the name of the group chat and the summaryArgumentCount should be 3.

If set, value cannot be 0 or less.

See IOSCategory.summaryFormat.

targetContentId

iOS >= 13

The identifier for the window to be opened when the user taps a notification.

targetContentId?: undefined | string;

This value determines the window brought forward when the user taps this notification on iPadOS.

threadId

A unique id for the thread or conversation related to this notification. This will be used to visually group notifications together.

threadId?: undefined | string;

Copyright 2020 - 2021 © Invertase Limited

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 3.0 License and code samples are licensed under the Apache 2.0 License.

All product names, logos, and brands are property of their respective owners. All company, product and service names used in this website are for identification purposes only. Use of these names, logos, and brands does not imply endorsement.