Supplementary package for usage with Pygeon mobile application
Project description
Introduction
Pygeon makes it super easy to send yourself custom push notifications
Install Pygeon
pip install pygeon-notifications
Usage with Python (>= 3.3)
Install and open the Pygeon app on your mobile (iOS only) and sign-in. After signing in you will recieve a private key. Use the private key to instantiate a Pygeon object that you can use to send push notifications anywhere in your scripts
example
from pygeon import Pygeon
my_pygeon = Pygeon("YOUR_PRIVATE_KEY")
my_pygeon.send("Cool Title", "Even cooler description")
Usage with POST requests
The Pygeon python package under the hood is a simple program that sends a POST request to Pygeon servers. Hence you can send notifications using a simple POST request to https://pygeon.io/api/sendnotification with your private key, title and description in the body of the request.
curl example
curl -X POST "https://pygeon.io/api/sendnotification" -H 'Content-Type: application/json' -d '{"ppk":"YOUR_PRIVATE_KEY","title":"Cool Title", "desc": "Cool Body"}'
node example
const axios = require('axios')
axios.post('https://pygeon.io/api/sendnotification', {
ppk: 'YOUR_PRIVATE_KEY',
title: 'Cool Title',
desc: 'Even cooler description'
})
.then(res => {
console.log(`statusCode: ${res.status}`)
console.log(res)
})
.catch(error => {
console.error(error)
})
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pygeon-notifications-1.0.0.tar.gz.
File metadata
- Download URL: pygeon-notifications-1.0.0.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0a3ee06645c59a78e23140d3e9ce82a0872c22a4b332df6a27262ff7297ced03
|
|
| MD5 |
95cef71b798a7c0a2547821bf7671f4c
|
|
| BLAKE2b-256 |
53d76b09be965d2e9c952433ce14d7dd7c98e160635c87d8111b9bdce6ab7e50
|
File details
Details for the file pygeon_notifications-1.0.0-py3-none-any.whl.
File metadata
- Download URL: pygeon_notifications-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.8.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7821f4f4ab501e2e86c8011bd219c926cf435a7a97ab72050811013052d766fb
|
|
| MD5 |
9385518f100160faba58aa4245c81af8
|
|
| BLAKE2b-256 |
7a0bf05047ab94e4ad6a676307e44a27c6fa168b5a1865c7d3676e29899e0895
|