Class

CKNotificationInfo

An object that specifies the push notification data that the server sends to your app when a subscription finds a match.

Declaration

@interface CKNotificationInfo : NSObject

Overview

When configuring a CKSubscription object, create one of these objects and use it to specify the type of push notifications you want generated when the subscription’s trigger condition is met. You can provide a message for an alert panel, information about the sounds to play, and information about whether the app should be badged. You can also ask the server to provide information about the record that triggered the notification.

When you receive a push notification generated by a subscription, use the notificationFromRemoteNotificationDictionary: method of CKNotification to create a notification object from the payload data. That object contains the data you specified using this class when configuring the subscription.

For more information about push notification alerts and how they are displayed to the user, see Apple Push Notification Service in Local and Remote Notification Programming Guide.

Topics

Accessing the Notification Info

alertBody

The text to use for the alert message.

alertLocalizationKey

The key that identifies the localized string to use for the alert message.

alertLocalizationArgs

The array of fields to use when building an alert message.

alertActionLocalizationKey

The key that identifies the text to use for the action button in the alert panel.

alertLaunchImage

The filename of an image to use as a launch image.

category

Name of the action group corresponding to this notification.

soundName

The name of the sound file to play when a notification arrives.

shouldBadge

A Boolean setting that controls whether a badge value should be incremented.

shouldSendContentAvailable

A Boolean value indicating whether the push notification should include the content-available flag.

Accessing the Record’s Data

desiredKeys

The names of fields to include in the push notification payload.

Relationships

Inherits From

See Also

Notification Information

CKNotificationID

An object that uniquely identifies a push notification sent from a container.