Skip to content

Commit

Permalink
Switch apn dependency to @parse/node-apn. Add support for apns push-t…
Browse files Browse the repository at this point in the history
…ype.
  • Loading branch information
alex-friedl committed Oct 26, 2019
1 parent a160ed7 commit 791c7bb
Show file tree
Hide file tree
Showing 5 changed files with 100 additions and 88 deletions.
6 changes: 4 additions & 2 deletions README.md
Expand Up @@ -175,8 +175,8 @@ const data = {
truncateAtWordEnd: true, // apn and gcm for ios
mutableContent: 0, // apn
threadId: '', // apn
// if both expiry and timeToLive are given, expiry will take precedence
expiry: Math.floor(Date.now() / 1000) + 28 * 86400, // seconds
pushType: undefined, // apn. valid values are 'alert' and 'background' (https://github.com/parse-community/node-apn/blob/master/doc/notification.markdown#notificationpushtype)
expiry: Math.floor(Date.now() / 1000) + 28 * 86400, // unit is seconds. if both expiry and timeToLive are given, expiry will take precedence
timeToLive: 28 * 86400,
headers: [], // wns
launch: '', // wns
Expand Down Expand Up @@ -385,6 +385,8 @@ The following parameters are used to create an APN message:
truncateAtWordEnd: data.truncateAtWordEnd,
collapseId: data.collapseKey,
mutableContent: data.mutableContent || 0,
threadId: data.threadId,
pushType: data.pushType
}
```
Expand Down
143 changes: 60 additions & 83 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 791c7bb

Please sign in to comment.