{"action":"created","issue":{"url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/599","repository_url":"https://api.github.com/repos/phonegap/phonegap-plugin-push","labels_url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/599/labels{/name}","comments_url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/599/comments","events_url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/599/events","html_url":"https://github.com/phonegap/phonegap-plugin-push/issues/599","id":132634299,"number":599,"title":"Message parameter displays full JSON instead of message data","user":{"login":"darrylemoonman","id":9206497,"avatar_url":"https://avatars.githubusercontent.com/u/9206497?v=3","gravatar_id":"","url":"https://api.github.com/users/darrylemoonman","html_url":"https://github.com/darrylemoonman","followers_url":"https://api.github.com/users/darrylemoonman/followers","following_url":"https://api.github.com/users/darrylemoonman/following{/other_user}","gists_url":"https://api.github.com/users/darrylemoonman/gists{/gist_id}","starred_url":"https://api.github.com/users/darrylemoonman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darrylemoonman/subscriptions","organizations_url":"https://api.github.com/users/darrylemoonman/orgs","repos_url":"https://api.github.com/users/darrylemoonman/repos","events_url":"https://api.github.com/users/darrylemoonman/events{/privacy}","received_events_url":"https://api.github.com/users/darrylemoonman/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/labels/android","name":"android","color":"BFD4F2"},{"url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-10T08:23:41Z","updated_at":"2016-02-10T21:39:56Z","closed_at":null,"body":"Hi, trying to implement this add-on I can send the push notifications ok, however the message field always displays the full JSON instead of just the message component. Is this a bug?\r\n\r\nI'm using Kinvey back end + Phonegap.\r\n\r\nIn the Kinvey back end, I create the androidPayload object (based on their documentation) then send the push notification.\r\n```\r\nvar androidPayload = {\"title\":\"Friend Request Accepted\",\"message\":\"Your friend request was accepted\"};\r\npush.sendPayload(user, iOSAps, iOSExtras, androidPayload, function(err,result){\r\n    if(err){\r\n        logger.error(err);\r\n   }else{\r\n        logger.info(result);\r\n    }\r\n});\r\n```\r\nOut the other end when I call push.on('notification')\r\n```\r\napp.pushN.on('notification', function(data) {\r\n    console.log(data.message);\r\n    console.log(data.title);\r\n    console.log(data.count);\r\n    console.log(data.sound);\r\n    console.log(data.image);\r\n    console.log(data.additionalData);\t\t\r\n    if(data.sound){\r\n        var media = new Media(data.sound);\r\n        media.play();\r\n    }\r\n});\r\n```\r\nThe push notification comes up in android like this\r\n```\r\nTitle> Friend Request\r\nMessage> {\"title\":\"Friend Request Accepted\",\"message\":\"Your friend request was accepted\"}\r\n```\r\ninstead of like this\r\n```\r\nTitle> Friend Request\r\nMessage> Your friend request was accepted\r\n```\r\nIs this a bug in the plugin? It doesn't appear to be mapping the data.message object correctly"},"comment":{"url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/comments/182593187","html_url":"https://github.com/phonegap/phonegap-plugin-push/issues/599#issuecomment-182593187","issue_url":"https://api.github.com/repos/phonegap/phonegap-plugin-push/issues/599","id":182593187,"user":{"login":"darrylemoonman","id":9206497,"avatar_url":"https://avatars.githubusercontent.com/u/9206497?v=3","gravatar_id":"","url":"https://api.github.com/users/darrylemoonman","html_url":"https://github.com/darrylemoonman","followers_url":"https://api.github.com/users/darrylemoonman/followers","following_url":"https://api.github.com/users/darrylemoonman/following{/other_user}","gists_url":"https://api.github.com/users/darrylemoonman/gists{/gist_id}","starred_url":"https://api.github.com/users/darrylemoonman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darrylemoonman/subscriptions","organizations_url":"https://api.github.com/users/darrylemoonman/orgs","repos_url":"https://api.github.com/users/darrylemoonman/repos","events_url":"https://api.github.com/users/darrylemoonman/events{/privacy}","received_events_url":"https://api.github.com/users/darrylemoonman/received_events","type":"User","site_admin":false},"created_at":"2016-02-10T21:39:56Z","updated_at":"2016-02-10T21:39:56Z","body":"```\r\n02-11 08:38:42.503 23308 23411 V PushPlugin: execute: action=init\r\n02-11 08:38:42.510 23308 23426 V PushPlugin: execute: data=[{\"android\":{\"senderID\":\"680482295413\",\"icon\":\"notificationicon\",\"iconColor\":\"#ff931e\",\"forceShow\":true},\"ios\":{\"alert\":true,\"badge\":true,\"sound\":true}}]\r\n02-11 08:38:42.511 23308 23426 V PushPlugin: execute: jo={\"senderID\":\"680482295413\",\"icon\":\"notificationicon\",\"iconColor\":\"#ff931e\",\"forceShow\":true}\r\n02-11 08:38:42.511 23308 23426 V PushPlugin: execute: senderID=680482295413\r\n02-11 08:38:42.515 23308 23426 V PushPlugin: onRegistered: {\"registrationId\":\"diZTeSoh8Po:APA91bEIn6iKHl2n6Kfd4UtjlRe0oupwvyJXvos_dGEq2h_E-temVEZM-fUvhBjWXw0IYzaqRaQP3kH7MZEqRCD0RpHYHlqK_SaY0IdSRMEUREPDfyJ9Kh5yUuY6-aSZEPNZntBidOCQ\"}\r\n02-11 08:39:09.562 23308 23377 D PushPlugin_GCMIntentService: onMessage - from: 680482295413\r\n02-11 08:39:09.562 23308 23377 D PushPlugin_GCMIntentService: normalize extras\r\n02-11 08:39:09.562 23308 23377 D PushPlugin_GCMIntentService: key = message\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: extracting nested message data from key = message\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: key = data/title\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: key = data/message\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: replace key message with message\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: key = collapse_key\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: replace key collapse_key with collapse_key\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: background\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: message =[{\"title\":\"Friend Request Accepted\",\"message\":\"Your friend request was accepted\"}]\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: title =[Friend Request Accepted]\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: contentAvailable =[null]\r\n02-11 08:39:09.563 23308 23377 D PushPlugin_GCMIntentService: create notification\r\n02-11 08:39:09.564 23308 23377 E PushPlugin_GCMIntentService: Number format exception - Error parsing notId: Invalid int: \"null\"\r\n02-11 08:39:09.568 23308 23377 D PushPlugin_GCMIntentService: stored icon=notificationicon\r\n02-11 08:39:09.568 23308 23377 D PushPlugin_GCMIntentService: stored iconColor=#ff931e\r\n02-11 08:39:09.569 23308 23377 D PushPlugin_GCMIntentService: stored sound=true\r\n02-11 08:39:09.569 23308 23377 D PushPlugin_GCMIntentService: stored vibrate=true\r\n02-11 08:39:09.572 23308 23377 D PushPlugin_GCMIntentService: using icon from plugin options\r\n02-11 08:39:09.578 23308 23377 D PushPlugin_GCMIntentService: create actions\r\n```"}}