1.0.5 • Published 7 years ago

pusha v1.0.5

Weekly downloads
2
License
MIT
Repository
github
Last release
7 years ago

Pusha Node Package

This Node package provides a simplified way to interact with the Pusha API.

Documentation

See the full documentation on Pusha's documentation.

Installation

npm install --save pusha

Requirements

Usage

This library needs to be configured with your API Key which can be found here.

const pusha = require('pusha')('YOUR_API_KEY');

Basic example

The user token is needed from every user you wanna send notifications to. They can find it here.

const pusha = require('pusha')('YOUR_API_KEY');

pusha.send({
    recipients: ['USER_TOKEN_1', 'USER_TOKEN_2'],
    message: 'hello from node'
}).then(response => {
    console.log(response)
}).catch(error => {
    console.error(error)
})
1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago