PUSHER = Grocer.pusher( certificate: "./config/ck.pem",
passphrase: ENV['grocer_dev_cert_passphrase'],
gateway: ENV['grocer_pusher_gateway'],
port: ENV['grocer_pusher_port'],
retries: 3
)
FEEDBACK = Grocer.feedback( certificate: "./config/ck.pem" ,
passphrase: ENV['grocer_dev_cert_passphrase'],
gateway: ENV['grocer_feedback_gateway'],
port: ENV['grocer_feedback_port'] ,
retries: 3
)
notification = Grocer::Notification.new(
device_token: "df67fbd000a631998a46289f798beb75249afc2db0c5ecff2cc83db5b0bf245a",
alert: "This is God",
badge: 1,
sound: 'siren.aiff',
expiry: Time.now + 60*60,
content_available: true
)
PUSHER.push(notification)
通过APNS返回警报消息的字节数,但在Heroku中,推送通知尚未显示给相应的设备。请提前帮助我。谢谢。