joaobarbosa / Onesignal Python
Licence: mit
Python client for OneSignal push notification service
Stars: ✭ 33
Programming Languages
python
139335 projects - #7 most used programming language
Projects that are alternatives of or similar to Onesignal Python
Onesignal Website Sdk
OneSignal is a push notification service for web and mobile apps. This SDK makes it easy to integrate your website with OneSignal Push Notifications. https://onesignal.com
Stars: ✭ 338 (+924.24%)
Mutual labels: notifications, push-notifications, onesignal
React Native Onesignal
React Native Library for OneSignal Push Notifications Service
Stars: ✭ 1,270 (+3748.48%)
Mutual labels: notifications, push-notifications, onesignal
Onesignal Ios Sdk
OneSignal is a free push notification service for mobile apps. This plugin makes it easy to integrate your native iOS app with OneSignal. https://onesignal.com
Stars: ✭ 370 (+1021.21%)
Mutual labels: notifications, push-notifications, onesignal
Apprise
Apprise - Push Notifications that work with just about every platform!
Stars: ✭ 4,307 (+12951.52%)
Mutual labels: notifications, push-notifications
OneSignal-WordPress-Plugin
OneSignal is a free push notification service for web and mobile apps. This plugin makes it easy to integrate your website with OneSignal Push Notifications. https://onesignal.com
Stars: ✭ 71 (+115.15%)
Mutual labels: notifications, onesignal
apprise-api
A lightweight REST framework that wraps the Apprise Notification Library
Stars: ✭ 147 (+345.45%)
Mutual labels: notifications, push-notifications
react-native-notifee
Moved to https://github.com/invertase/notifee
Stars: ✭ 477 (+1345.45%)
Mutual labels: notifications, onesignal
Laravel Onesignal
OneSignal Push Notifications for Laravel
Stars: ✭ 369 (+1018.18%)
Mutual labels: notifications, onesignal
React Native Notifee
⚛️ A feature rich notifications library for React Native Android & iOS, built by @invertase, the authors of @react-native-firebase.
Stars: ✭ 381 (+1054.55%)
Mutual labels: notifications, onesignal
Countly Server
Countly helps you get insights from your application. Available self-hosted or on private cloud.
Stars: ✭ 4,857 (+14618.18%)
Mutual labels: notifications, push-notifications
Onesignal Android Sdk
OneSignal is a free push notification service for mobile apps. This plugin makes it easy to integrate your native Android or Amazon app with OneSignal. https://onesignal.com
Stars: ✭ 503 (+1424.24%)
Mutual labels: push-notifications, onesignal
Socket.io Push
整合了小米,华为,友盟,谷歌,苹果推送的统一解决方案
Stars: ✭ 605 (+1733.33%)
Mutual labels: notifications, push-notifications
spontit-api-python-wrapper
Send functional, flexible push notifications to iOS, Android, and desktop devices (without your own app or website).
Stars: ✭ 35 (+6.06%)
Mutual labels: notifications, push-notifications
webpush-example
A basic push notifications app built on Laravel and Vanilla Javascript.
Stars: ✭ 26 (-21.21%)
Mutual labels: notifications, push-notifications
Webpush
webpush, Encryption Utilities for Web Push protocol
Stars: ✭ 308 (+833.33%)
Mutual labels: notifications, push-notifications
andpush
Android Push Notification in Ruby: The fastest client for FCM (Firebase Cloud Messaging)
Stars: ✭ 83 (+151.52%)
Mutual labels: notifications, push-notifications
Demo Progressive Web App
🎉 A demo for progressive web application with features like offline, push notifications, background sync etc,
Stars: ✭ 798 (+2318.18%)
Mutual labels: notifications, push-notifications
OneSignal-Codeigniter-Push-Notification
OneSignal is a free push notification service for web and mobile apps. This Codeigniter example makes it easy to integrate your website with OneSignal Push Notifications. https://onesignal.com/ DEMO - http://ci3onesignal.codefort.ru/
Stars: ✭ 27 (-18.18%)
Mutual labels: push-notifications, onesignal
mobile-messaging-sdk-ios
Mobile Messaging SDK for iOS
Stars: ✭ 45 (+36.36%)
Mutual labels: notifications, push-notifications
Ntfy
🖥️📱🔔 A utility for sending notifications, on demand and when commands finish.
Stars: ✭ 4,089 (+12290.91%)
Mutual labels: notifications, push-notifications
onesignal-python
Python client for OneSignal push notification service
Installing
pip install onesignal-python
pip install git+https://github.com/joaobarbosa/onesignal-python.git
Usage
Example, sending push to specific devices (currently, only way supported).
from requests.exceptions import HTTPError
from onesignalclient.app_client import OneSignalAppClient
from onesignalclient.notification import Notification
player_id = 'sample00-play-er00-id00-000000000000'
os_app_id = 'sample00-app0-id00-0000-000000000000'
os_apikey = 'your-rest-api-key-goes-here'
# Init the client
client = OneSignalAppClient(app_id=os_app_id, app_api_key=os_apikey)
# Creates a new notification
notification = Notification(app_id, Notification.DEVICES_MODE)
notification.include_player_ids = [player_id] # Must be a list!
try:
# Sends it!
result = client.create_notification(notification)
except HTTPError as e:
result = e.response.json()
print(result)
# Success: {'id': '1d63fa3a-2205-314f-a734-a1de7e27cc2a', 'recipients': 1}
# Error: {'errors': ['Invalid app_id format']} - or any other message
Requirements
- Python 3.3+
-
requirements.txt
orrequirements-test.txt
Running tests
Using make:
make run_tests
Using pytest:
py.test --pep8 --cov=. --cov-report=term-missing --cov-config=.coveragerc -r a -v -s
Todo
API Methods
List of API methods to be covered by our client.
[U] - requires User Auth | [A] - requires App API Key
- [A] Create notification
- Segments mode settings & params
-
Devices mode settings & params- Improve tests as new params are added
- Filters mode settings & params
- Common Parameters
- App
app_id
app_ids
- Content
-
contents
- Behaviour when using
template_id
- Behaviour when using
headings
subtitle
template_id
content_available
mutable_content
-
- Attachments
data
url
ios_attachments
big_picture
adm_big_picture
chrome_big_picture
- Appearance
android_background_layout
small_icon
large_icon
chrome_web_icon
firefox_icon
adm_small_icon
adm_large_icon
chrome_icon
ios_sound
android_sound
adm_sound
wp_sound
wp_wns_sound
android_led_color
android_accent_color
android_visibility
ios_badgeType
ios_badgeCount
collapse_id
- Delivery
send_after
delayed_option
delivery_time_of_day
ttl
priority
- Others coming soon
- App
- Export data for request
[A] Cancel notification[U] View apps[U] View an app- [U] Create an app
- [U] Update an app
- [A] View devices
- View device
- [U] Add a device
- Edit device
- [U] New session
- New purchase
- Increment session length
- [A] CSV export
Regular exportExtra fields- Make it available in the user client
- [U] View notification
- [A] View notifications
- Track open
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].