Django Safari Push Notifications
Support for Safari Push Notifications from within Django. Note that this package helps registering notifications, not sending them. Safari Push works with APNs, so for sending, please use APNs Clerk.
Documentation
The full documentation will soon be at https://django-safari-notifications.readthedocs.io.
For the Safari Push documentations, refer to Apple Safari Push.
Quickstart
Install django_safari_notifications:
pip install django-safari-notifications
If you already have a valid pushPackage.zip, please serve it directly via your web server (Nginx/Apache) at the corresponding url: {webServiceUrl}/{version}/pushPackages/{websitePushID} (refer to Apple Safari Push)
Else, you must subclass django_safari_notifications.apps.DjangoSafariNotificationsConfig and set the cert and passphrase values.
from django_safari_notifications.apps import DjangoSafariNotificationsConfig
class MySafariNotificationsConfig(DjangoSafariNotificationsConfig):
cert = '/path/to/cert.pem'
passphrase = 'passphrase for key'
then add your config to your INSTALLED_APPS:
INSTALLED_APPS = (
...
'my_safari_app.apps.MySafariNotificationsConfig', # if you need the pushPackage to be dynamically built
## OR ##
'django_safari_notifications.apps.DjangoSafariNotificationsConfig', # If you are serving your own push package via Nginx
...
)
Add django_safari_notifications’s URL patterns:
from django_safari_notifications import urls as django_safari_notifications_urls
urlpatterns = [
...
url(r'^', include(django_safari_notifications_urls, namespace='safari_pn')),
...
]
Do not use any prefix for the urls, unless you are serving your own pushPackage.zip statically
Features
TODO
Running Tests
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate (myenv) $ pip install tox (myenv) $ tox
Credits
Tools used in rendering this package:
History
0.1.0 (2016-12-10)
First release on PyPI.
Metadata
Release files for django-safari-notifications 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| django-safari-notifications-0.1.1.tar.gz | 10.2 kB | Without provenance | Details |
Release files / django-safari-notifications-0.1.1.tar.gz
| Download URL | django-safari-notifications-0.1.1.tar.gz |
|---|---|
| Size | 10.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d325a0e43bf38b3f3cea9e62a040ebbf836f000415a7065eba94db372d2c66a3
|
|
BLAKE2b-256 checksum How to use checksums |
dac8819fdcb5ebc321cc631321ab83863f1dc22005b32cfeb5568e167929569a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-safari-notifications 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.