Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Pusher Push Notifications Python server SDK

Project Description

Full documentation for this SDK can be found here

Installation

The Pusher Notifications Python server SDK is available on PyPi here.

You can install this SDK by using pip:

$ pip install pusher_push_notifications

Usage

Configuring the SDK for Your Instance

Use your instance id and secret (you can get these from the dashboard) to create a PushNotifications instance:

from pusher_push_notifications import PushNotifications

pn_client = PushNotifications(
    instance_id='YOUR_INSTANCE_ID_HERE',
    secret_key='YOUR_SECRET_KEY_HERE',
)

Publishing a Notification

Once you have created your PushNotifications instance you can publish a push notification to your registered & subscribed devices:

response = pn_client.publish(interests=['hello'], publish_body={'apns': {'aps': {'alert': 'Hello!'}}})

print(response['publishId'])

Release History

This version
History Node

0.9.1

History Node

0.9.0

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, Size & Hash SHA256 Hash Help File Type Python Version Upload Date
pusher_push_notifications-0.9.1.tar.gz
(3.7 kB) Copy SHA256 Hash SHA256
Source None Jan 15, 2018

Supported By

Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Google Google Cloud Servers DreamHost DreamHost Log Hosting