pushwoosh-client
Advanced tools
Comparing version 1.1.0 to 1.1.1
{ | ||
"name": "pushwoosh-client", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "A node js client to consume the Pushwoosh API to send push notifications to mobile devices", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -1,12 +0,16 @@ | ||
# pushwoosh-node-client [![Build Status](https://travis-ci.org/nluo/pushwoosh-node-client.svg?branch=master)](https://travis-ci.org/nluo/pushwoosh-node-client) [![Join the chat at https://gitter.im/nluo/pushwoosh-node-client](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/nluo/pushwoosh-node-client?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) | ||
# pushwoosh-node-client | ||
[![Build Status](https://travis-ci.org/nluo/pushwoosh-node-client.svg?branch=master)](https://travis-ci.org/nluo/pushwoosh-node-client) [![Join the chat at https://gitter.im/nluo/pushwoosh-node-client](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/nluo/pushwoosh-node-client?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) | ||
A node js client to consume the Pushwoosh API to send push notifications to mobile devices | ||
## Installation | ||
## Quick Reference | ||
#### Installation | ||
npm i pushwoosh-client --save | ||
## Usage | ||
Send messages to all devices | ||
#### Send message to all devices | ||
```javascript | ||
@@ -25,2 +29,3 @@ var Pushwoosh = require('pushwoosh-client'); | ||
#### To a specific device or devices | ||
To send messages to a specificed device or devices, you can pass a device token or an arrays with devices | ||
@@ -39,2 +44,3 @@ | ||
#### Extra options/payload | ||
To pass extra options (please refer to the Pushwoosh [doc](https://www.pushwoosh.com/programming-push-notification/pushwoosh-push-notification-remote-api/) for the available options) , you could define an option object and pass it to the function as a 2nd or 3rd parameter. E.g. if you want to pass addtional payload to the device, you could do: | ||
@@ -74,3 +80,5 @@ | ||
``` | ||
To use Puswoosh `applications_group` code instead of `application` code, you must pass a third `options` argument when creating the client with `useApplicationsGroup` set to true: | ||
#### Applications group | ||
To use Puswoosh `applications_group` code(which allows you to send to multilple applications) instead of `application` code, you must pass a third `options` argument when creating the client with `useApplicationsGroup` set to true: | ||
```javascript | ||
@@ -94,3 +102,3 @@ var Pushwoosh = require('pushwoosh-client'); | ||
## Tests | ||
### Tests | ||
@@ -97,0 +105,0 @@ npm test |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33669
104