Skip to content
This repository was archived by the owner on Jun 16, 2023. It is now read-only.

Commit 8bd2692

Browse files
author
Michael Khmelnitsky
committed
Updated the documentation.
1 parent 717e5a1 commit 8bd2692

3 files changed

+24
-3
lines changed

doc_source/sns-document-history.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ The following table lists changes to the *Amazon Simple Notification Service Dev
55

66
| Date | Documentation Update |
77
| --- | --- |
8-
| September 5, 2019 | Revised the information in the [Send Custom Platform\-Specific Payloads to Mobile Devices](sns-send-custom-platform-specific-payloads-mobile-devices.md) section\. |
8+
| September 10, 2019 | [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/sns/latest/dg/sns-document-history.html) |
99
| August 29, 2019 | Revised the information in the following sections: [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/sns/latest/dg/sns-document-history.html) |
1010
| August 26, 2019 | [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/sns/latest/dg/sns-document-history.html) |
1111
| August 19, 2019 | Added the [Allow a CloudWatch Alarm in an AWS Account to Publish to an Amazon SNS Topic in a Different AWS Account](sns-access-policy-use-cases.md#sns-allow-cloudwatch-alarm-to-publish-to-topic-in-another-account) section\. |

doc_source/sns-release-notes.md

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ The following table lists Amazon SNS feature releases and improvements\. For cha
55

66
| Date | Feature Release |
77
| --- | --- |
8+
| September 10, 2019 | Amazon SNS supports the apns\-push\-type header field for mobile notifications sent through APNs\. For more information, see [Sending Messages to APNs as Background Notifications](sns-send-custom-platform-specific-payloads-mobile-devices.md#mobile-push-send-message-apns-background-notification)\. |
89
| July 24, 2019 | You can troubleshoot messages passing through Amazon SNS topics using AWS X\-Ray\. For more information, see [Troubleshooting Amazon Simple Notification Service Topics Using AWS X\-Ray](sns-troubleshooting-using-x-ray.md) section\. |
910
| July 5, 2019 | [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/sns/latest/dg/sns-release-notes.html) |
1011
| May 16, 2019 | [\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/sns/latest/dg/sns-release-notes.html) |

doc_source/sns-send-custom-platform-specific-payloads-mobile-devices.md

+22-2
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,26 @@ The following example shows a message to send to subscribed mobile endpoints on
4343
one of the notification platforms.",
4444
"APNS": "{\"aps\":{\"alert\": \"Check out these awesome deals!\",\"url\":\"www.amazon.com\"} }",
4545
"FCM": "{\"data\":{\"message\":\"Check out these awesome deals!\",\"url\":\"www.amazon.com\"}}",
46-
"ADM": "{ \"data\": { \"message\": \"Check out these awesome deals!\",\"url\":\"www.amazon.com\" }}"
46+
"ADM": "{\"data\":{\"message\":\"Check out these awesome deals!\",\"url\":\"www.amazon.com\"}}"
4747
}
48-
```
48+
```
49+
50+
## Sending Messages to APNs as Background Notifications<a name="mobile-push-send-message-apns-background-notification"></a>
51+
52+
Amazon SNS sets the `apns-push-type` APNs header to `alert` or `background` depending on the `content-available` field in your APNs JSON payload configuration\. For more information, see [Pushing Background Updates to Your App](https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/pushing_background_updates_to_your_app) in the APNs documentation\.
53+
+ An `alert` APNs notification informs your users by displaying an alert message, playing a sound, or adding a badge to your application’s icon\.
54+
+ A `background` APNs notification wakes up or instructs your application to act upon the content of the notification, without informing the user\.
55+
56+
**Important**
57+
If Amazon SNS sends a raw configuration object for APNs, you must specify the appropriate `content-available` field within the configuration object\.
58+
If the value of the `content-available` field isn’t an integer or a Boolean, the notification defaults to `alert`\.
59+
60+
The following is an example raw configuration object\.
61+
62+
```
63+
{
64+
"APNS": "{\"aps\":{\"content-available\":1},\"Foo1\":\"\Bar\",\"Foo2\":123}"
65+
}
66+
```
67+
68+
In this example, Amazon SNS sets the `apns-push-type` APNs header to `alert` for the message\. When Amazon SNS detects that `content-available` is set to `1`, it sets the header to `background.`

0 commit comments

Comments
 (0)