public static interface APNSMessage.Builder extends CopyableBuilder<APNSMessage.Builder,APNSMessage>
Modifier and Type | Method and Description |
---|---|
APNSMessage.Builder |
action(Action action)
The action that occurs if the user taps a push notification delivered by the campaign: OPEN_APP - Your app
launches, or it becomes the foreground app if it has been sent to the background.
|
APNSMessage.Builder |
action(String action)
The action that occurs if the user taps a push notification delivered by the campaign: OPEN_APP - Your app
launches, or it becomes the foreground app if it has been sent to the background.
|
APNSMessage.Builder |
badge(Integer badge)
Include this key when you want the system to modify the badge of your app icon.
|
APNSMessage.Builder |
body(String body)
The message body of the notification, the email body or the text message.
|
APNSMessage.Builder |
category(String category)
Provide this key with a string value that represents the notification's type.
|
APNSMessage.Builder |
collapseId(String collapseId)
Multiple notifications with the same collapse identifier are displayed to the user as a single notification.
|
APNSMessage.Builder |
data(Map<String,String> data)
The data payload used for a silent push.
|
APNSMessage.Builder |
mediaUrl(String mediaUrl)
The URL that points to a video used in the push notification.
|
APNSMessage.Builder |
preferredAuthenticationMethod(String preferredAuthenticationMethod)
The preferred authentication method, either "CERTIFICATE" or "TOKEN"
|
APNSMessage.Builder |
priority(String priority)
Is this a transaction priority message or lower priority.
|
APNSMessage.Builder |
rawContent(String rawContent)
The Raw JSON formatted string to be used as the payload.
|
APNSMessage.Builder |
silentPush(Boolean silentPush)
Indicates if the message should display on the users device.
|
APNSMessage.Builder |
sound(String sound)
Include this key when you want the system to play a sound.
|
APNSMessage.Builder |
substitutions(Map<String,? extends Collection<String>> substitutions)
Default message substitutions.
|
APNSMessage.Builder |
threadId(String threadId)
Provide this key with a string value that represents the app-specific identifier for grouping notifications.
|
APNSMessage.Builder |
timeToLive(Integer timeToLive)
This parameter specifies how long (in seconds) the message should be kept if APNS is unable to deliver the
notification the first time.
|
APNSMessage.Builder |
title(String title)
The message title that displays above the message on the user's device.
|
APNSMessage.Builder |
url(String url)
The URL to open in the user's mobile browser.
|
copy
applyMutation, build
APNSMessage.Builder action(String action)
action
- The action that occurs if the user taps a push notification delivered by the campaign: OPEN_APP - Your
app launches, or it becomes the foreground app if it has been sent to the background. This is the
default action. DEEP_LINK - Uses deep linking features in iOS and Android to open your app and display
a designated user interface within the app. URL - The default mobile browser on the user's device
launches and opens a web page at the URL you specify. Possible values include: OPEN_APP | DEEP_LINK |
URLAction
,
Action
APNSMessage.Builder action(Action action)
action
- The action that occurs if the user taps a push notification delivered by the campaign: OPEN_APP - Your
app launches, or it becomes the foreground app if it has been sent to the background. This is the
default action. DEEP_LINK - Uses deep linking features in iOS and Android to open your app and display
a designated user interface within the app. URL - The default mobile browser on the user's device
launches and opens a web page at the URL you specify. Possible values include: OPEN_APP | DEEP_LINK |
URLAction
,
Action
APNSMessage.Builder badge(Integer badge)
badge
- Include this key when you want the system to modify the badge of your app icon. If this key is not
included in the dictionary, the badge is not changed. To remove the badge, set the value of this key
to 0.APNSMessage.Builder body(String body)
body
- The message body of the notification, the email body or the text message.APNSMessage.Builder category(String category)
category
- Provide this key with a string value that represents the notification's type. This value corresponds
to the value in the identifier property of one of your app's registered categories.APNSMessage.Builder collapseId(String collapseId)
collapseId
- Multiple notifications with the same collapse identifier are displayed to the user as a single
notification. The value of this key must not exceed 64 bytes.APNSMessage.Builder data(Map<String,String> data)
data
- The data payload used for a silent push. This payload is added to the notifications'
data.pinpoint.jsonBody' objectAPNSMessage.Builder mediaUrl(String mediaUrl)
mediaUrl
- The URL that points to a video used in the push notification.APNSMessage.Builder preferredAuthenticationMethod(String preferredAuthenticationMethod)
preferredAuthenticationMethod
- The preferred authentication method, either "CERTIFICATE" or "TOKEN"APNSMessage.Builder priority(String priority)
priority
- Is this a transaction priority message or lower priority.APNSMessage.Builder rawContent(String rawContent)
rawContent
- The Raw JSON formatted string to be used as the payload. This value overrides the message.APNSMessage.Builder silentPush(Boolean silentPush)
silentPush
- Indicates if the message should display on the users device. Silent pushes can be used for Remote
Configuration and Phone Home use cases.APNSMessage.Builder sound(String sound)
sound
- Include this key when you want the system to play a sound. The value of this key is the name of a
sound file in your app's main bundle or in the Library/Sounds folder of your app's data container. If
the sound file cannot be found, or if you specify defaultfor the value, the system plays the default
alert sound.APNSMessage.Builder substitutions(Map<String,? extends Collection<String>> substitutions)
substitutions
- Default message substitutions. Can be overridden by individual address substitutions.APNSMessage.Builder threadId(String threadId)
threadId
- Provide this key with a string value that represents the app-specific identifier for grouping
notifications. If you provide a Notification Content app extension, you can use this value to group
your notifications together.APNSMessage.Builder timeToLive(Integer timeToLive)
timeToLive
- This parameter specifies how long (in seconds) the message should be kept if APNS is unable to deliver
the notification the first time. If the value is 0, APNS treats the notification as if it expires
immediately and does not store the notification or attempt to redeliver it. This value is converted to
the expiration field when sent to APNSAPNSMessage.Builder title(String title)
title
- The message title that displays above the message on the user's device.APNSMessage.Builder url(String url)
url
- The URL to open in the user's mobile browser. Used if the value for Action is URL.Copyright © 2017 Amazon Web Services, Inc. All Rights Reserved.