javascript - Parse: push notification to specific device -
I want to send a parse notification via the object ID to a specific device.
The API call is from PHP:
& lt ;? Php $ url = 'https://api.parse.com/1/push'; $ AppId = // app id $ left pays = // rest of $ target_device = 'TARGET_INSTALLATION_OBJECT_ID_HERE'; // Target Objective ID using the ID $ Push_payload = json_encode (array ("where" => array ("objectId" = & gt; $ target_device,), "data" = & gt; array ("warning" = & Gt; "This is the alert text."))); // curl exec ...
How can I get TARGET_INSTALLATION_OBJECT_ID_HERE by Javascript (because I'm using PhoneGrap)?
Thanks
For Android you can use this Phonegap plugin:
I can not help you for iOS, because I am not currently working with it
Comments
Post a Comment