Skip to content
Titanium SDK
Titanium Docs
Version13.4.1

Titanium.App.iOS.UserNotificationCenter

moduleiPhoneiPadmacOSsince 7.3.0

Extends Titanium.ModuleTitanium.Proxy

The top-level App iOS Notification Center module. It is used to control scheduled notifications and receive details about the system-wide notification settings.

Properties 1

apiName

Stringsince Android 3.2.0, iPhone 3.2.0, iPad 3.2.0, macOS 9.2.0read-only

Inherited from Titanium.Proxy

The name of the API that this proxy corresponds to.

Methods 5

Fetches the delivered notifications asynchronously.

Parameters
ParametersTypeDescription
callbackCallback<UserNotificationCallbackResponse>

The function that is being called after the notifications have been fetched.

1 field
notifications Array<UserNotificationDictionary>

An array of identifiers used to create notifications.

Fetches the pending notifications asynchronously.

Parameters
ParametersTypeDescription
callbackCallback<UserNotificationCallbackResponse>

The function that is being called after the notifications have been fetched.

1 field
notifications Array<UserNotificationDictionary>

An array of identifiers used to create notifications.

Removes the specified delivered notifications from the notification-center. If no notifications are specified, all delivered notifications will be removed.

Delivered notifications can be obtained via a call to the Titanium.App.iOS.UserNotificationCenter.getDeliveredNotifications method.

Parameters
ParametersTypeDescription
notificationsArray<UserNotificationDictionary>

The delivered notification to remove. If none specified, all pending notifications will be removed.

Removes the specified pending notifications to prevent them from being triggered. If no notifications are specified, all pending notifications will be removed.

Pending notifications can be obtained via a call to the Titanium.App.iOS.UserNotificationCenter.getPendingNotifications method.

Parameters
ParametersTypeDescription
notificationsArray<UserNotificationDictionary>

The pending notification to remove. If none specified, all pending notifications will be removed.

Notification types and user notification categories the application is registered to use.

Parameters
ParametersTypeDescription
callbackCallback<GetUserNotificationSettings>

The callback invoked when requesting user notification settings.

12 fields
alertSetting Number

The current alert settings.

alertStyle Number

The current alert style used to display notifications.

authorizationStatus Number

The current authorization status for using notifications.

badgeSetting Number

The current badge settings.

carPlaySetting Number

The current CarPlay settings.

categories Array<Titanium.App.iOS.UserNotificationCategory>

Set of categories of user notification actions required by the application to use.

criticalAlertSetting Number

The authorization status to play sounds for critical alerts. Available in Titanium SDK 7.4.0 and later.

lockScreenSetting Number

The current lock-screen settings.

notificationCenterSetting Number

The current notification-center settings.

providesAppNotificationSettings Number

A Boolean value indicating the system displays a button for in-app notification settings. Available in Titanium SDK 7.4.0 and later.

soundSetting Number

The current sound settings.

types Array<Number>

Notification types to use.

Compiled from Titanium/App/iOS/UserNotificationCenter.ymlEdit on GitHub