{"action":"closed","issue":{"url":"https://api.github.com/repos/node-apn/node-apn/issues/532","repository_url":"https://api.github.com/repos/node-apn/node-apn","labels_url":"https://api.github.com/repos/node-apn/node-apn/issues/532/labels{/name}","comments_url":"https://api.github.com/repos/node-apn/node-apn/issues/532/comments","events_url":"https://api.github.com/repos/node-apn/node-apn/issues/532/events","html_url":"https://github.com/node-apn/node-apn/issues/532","id":209231046,"number":532,"title":"Notification is sent but never delivered to the device...","user":{"login":"tunds","id":13179531,"avatar_url":"https://avatars.githubusercontent.com/u/13179531?v=3","gravatar_id":"","url":"https://api.github.com/users/tunds","html_url":"https://github.com/tunds","followers_url":"https://api.github.com/users/tunds/followers","following_url":"https://api.github.com/users/tunds/following{/other_user}","gists_url":"https://api.github.com/users/tunds/gists{/gist_id}","starred_url":"https://api.github.com/users/tunds/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tunds/subscriptions","organizations_url":"https://api.github.com/users/tunds/orgs","repos_url":"https://api.github.com/users/tunds/repos","events_url":"https://api.github.com/users/tunds/events{/privacy}","received_events_url":"https://api.github.com/users/tunds/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2017-02-21T18:24:38Z","updated_at":"2017-02-23T13:15:38Z","closed_at":"2017-02-23T13:15:38Z","body":"So i've followed the documentation to send a notification and it seems to give me a success in the logs since the result of the closure is this.\r\n\r\n```\r\n{\r\n\"result\": {\r\n\"sent\": [\r\n{\r\n\"device\": \"xxxxxxxxxxxxx\"\r\n}\r\n],\r\n\"failed\": []\r\n}\r\n}\r\n```\r\n\r\nThe only issue is that the notification is never actually delivered to the device although i'm recivieing a 200 response of success below is the code i'm using to send the notification.\r\n\r\n\r\n```\r\n    var options = {\r\n        token: {\r\n            key: __dirname + \"/public/key.p8\",\r\n            keyId: \"xxxx\",\r\n            teamId: \"xxxxx\"\r\n        },\r\n        production: false\r\n    };\r\n\r\n    var apnProvider = new apn.Provider(options);\r\n\r\n    var notification = new apn.Notification();\r\n\r\n\r\n    notification.rawPayload = {\r\n        sound : \"Wakeup.wav\",\r\n        aps: {\r\n            alert: {\r\n                title : \"Good morning!\",\r\n                subtitle: \"Today's forcast in \",\r\n                body: \"\"\r\n            },\r\n            \"mutable-content\" : 1,\r\n            icon: \"cloudy\"\r\n        }\r\n    };\r\n\r\n    notification.expiry = Math.floor(Date.now() / 1000) + 3600; // Expires 1 hour from now.\r\n    notification.topic = \"tunds.myapp\";\r\n\r\n    apnProvider.send(notification, \"xxxxxxx\").then(function (result) {\r\n        response.success(result);\r\n    });\r\n    \r\n```"}}
{"actor":{"display_login":"tunds"}}