**Download Script **Download Sample
Here’s the simple steps to integrate Pushwoosh plugin into your BlackBerry 10 Webworks 2.0 application:
1. Add the following list of plugins into your project:
com.blackberry.app com.blackberry.identity com.blackberry.invoked com.blackberry.notification com.blackberry.push com.blackberry.ui.dialog com.blackberry.utils
**2.** Add the *http://cp.pushwoosh.com* access url into your **config.xml**:
In the code above you have to put any unique identification value of the app instead of the “GENERATE”
**4.** Add the following permissions:
Download our plugin (pushwoosh.js) here and place it in “js” subfolder (ex: “js/pushwoosh.js”).
Download jQuery library and place it in “js” subfolder (ex: “js/jquery-1.10.2.min.js”).
6. Add the following script to the index.html:
NOTE:
**7.** Change the following application settings in the **pushwoosh.js** with app setting you receive from BlackBerry:
– We recommend adding this script inside the body tag in the very end of it;
– You can use the different jQuery library. You can download them here;
– You don’t have to look for the cordova.js anywhere – everything will be done by the web worker builder.
var config = { ops : { invokeTargetId : "GENERATE.invoke.push", // the same id value that you used in the config.xml appId : "XXXX-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX", // AppId from the configuration email you receive from BlackBerry ppgUrl : "http://cpXXXX.pushapi.eval.blackberry.com" // ppgUrl from the configuration email you receive from BlackBerry }, pushwooshAppId : "XXXXX-XXXXX", // Pushwoosh Application Code invokeTargetIdOpen : "GENERATE.invoke.open" // the same id value that you used in the config.xml };
Make sure PGG Url is HTTP. If you enter it as HTTPS push notifications channel won’t subscribe.