pushd
Version:
Blazing fast multi-protocol mobile push notification service
67 lines (59 loc) • 2.33 kB
text/coffeescript
exports.server =
access_log: yes
acl:
# restrict publish access to private networks
publish: ['127.0.0.1', '10.0.0.0/8', '172.16.0.0/12', '192.168.0.0/16']
exports['event-source'] =
enabled: yes
exports.apns =
enabled: yes
class: require('./lib/pushservices/apns').PushServiceAPNS
# Convert cert.cer and key.p12 using:
# $ openssl x509 -in cert.cer -inform DER -outform PEM -out apns-cert.pem
# $ openssl pkcs12 -in key.p12 -out apns-key.pem -nodes
cert: 'apns-cert-beta.pem'
key: 'apns-key-beta.pem'
# Selects data keys which are allowed to be sent with the notification
# Keep in mind that APNS limits notification payload size to 256 bytes
payloadFilter: ['tile']
cacheLength: 100
# uncommant for dev env
gateway: 'gateway.sandbox.push.apple.com'
address: 'feedback.sandbox.push.apple.com'
errorCallback: =>
console.log arguments
# exports.c2dm =
# enabled: yes
# class: require('./lib/pushservices/c2dm').PushServiceC2DM
# # App credentials
# user: 'apps@dailymotion.com'
# password: 'rJ8kpcHy9@'
# source: 'com.dailymotion.dailymotion'
exports.gcm =
enabled: yes
class: require('./lib/pushservices/gcm').PushServiceGCM
key: 'AIzaSyBDXbbwK_usEoRF3zHgH4obz5hFelbBZkU'
exports['http'] =
enabled: yes
class: require('./lib/pushservices/http').PushServiceHTTP
exports['mpns-toast'] =
enabled: yes
class: require('./lib/pushservices/mpns').PushServiceMPNS
type: 'toast'
exports['mpns-tile'] =
enabled: yes
class: require('./lib/pushservices/mpns').PushServiceMPNS
type: 'tile'
# Mapping defines where - in the payload - to get the value of each required properties
tileMapping:
id: "/Views/UserProfileView.xaml?event=${event.name}"
title: "${data.title}"
backgroundImage: "${data.background_image_url}"
backBackgroundImage: "#005e8a"
backTitle: "${data.back_title}"
backContent: "${data.message}"
# param for WP8 flip tile (sent when subscriber declare a minimum OS version of 8.0)
smallBackgroundImage: "${data.small_background_image_url}"
wideBackgroundImage: "${data.wide_background_image_url}"
wideBackContent: "${data.message}"
wideBackBackgroundImage: "#005e8a"