Puship.PushipAppId = puship_id; // an example of puship_id might be: "h1mCVGaP9dtGnwG" var serverUrl = "http://cpXXX.pushapi.eval.blackberry.com"; // the url of production or development provided by blackberry var appId = "396-577a13e9r57070Mnn75549ii0ch2r9l41808"; // this appid is provided by blackberry with the url var port = 32200; Puship.BPNS.Register(port, serverUrl, appId, { successCallback: function (pushipresult){ navigator.notification.alert("device registered with DeviceId:" + pushipresult.DeviceId); }, failCallback: function (pushipresult){ navigator.notification.alert("error during registration: "+ JSON.stringify(pushipresult)); } });
It’s now possible to connect to the Puship Manager and start sending push notification to your devices!
Download a complete example using the link below to better understand the whole process
Adding tags, geolocations management and all the other api are described in the guide common to all the platform that can be consulted at the following link: