The simplest Pushover API wrapper for Python.
Project description
The simplest Pushover API wrapper for Python.
Features
No extraneous requests - just sends non-emergency messages quickly and without fuss
Aims to get the basics right, and be open to extension for more advanced use cases
Timeouts and automatic back-off should Pushover be experiencing issues
Intuitive command-line interface with sane, parseable output
Unit and integration tested
Signed PyPi releases
Installation
$ pip install pullover
Demo
The following code snippets demonstrate how to use the main features of pullover.
High-level API
import pullover
response = pullover.send('message', 'user key', 'app token')
if response.ok:
print(response.id) # 647d2300-702c-4b38-8b2f-d56326ae460b
Low-level API
from pullover import Application, User, Message, ClientSendError, \
ServerSendError
try:
aws = Application('app token')
george = User('user key')
message = Message('message', title='hello')
response = message.send(aws, george)
response.raise_for_status()
print(response.id) # 647d2300-702c-4b38-8b2f-d56326ae460b
except ClientSendError as e:
# it was our fault
print(e.status, e.errors)
except ServerSendError:
# Pushover is having issues
print(e.response.text)
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
pullover-1.0.0rc2.tar.gz
(10.4 kB
view details)
Built Distribution
File details
Details for the file pullover-1.0.0rc2.tar.gz
.
File metadata
- Download URL: pullover-1.0.0rc2.tar.gz
- Upload date:
- Size: 10.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1cc567360370d91a5b73f8215970be5a3a7005279d114a66d002515d48cbf3d2 |
|
MD5 | 6625aea325d2455a00971a859a596203 |
|
BLAKE2b-256 | 27394388a42b1122958a1f31c0958aa88393b49dc4cc4f1c47e0e812b92694cb |
File details
Details for the file pullover-1.0.0rc2-py2.py3-none-any.whl
.
File metadata
- Download URL: pullover-1.0.0rc2-py2.py3-none-any.whl
- Upload date:
- Size: 15.3 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f6c45395d56a51981201a5d81b69c97d7b07b453b42a263175e3bbd2864af4d8 |
|
MD5 | b35c97b1774f543e753142bd8ede2b2f |
|
BLAKE2b-256 | e8704518d723af247a65830a119df79b77edc7b7f67323a43f756625b01f36a5 |