Download the PHP package overmob/pusher-push-notifications without Composer
On this page you can find all versions of the php package overmob/pusher-push-notifications. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download overmob/pusher-push-notifications
More information about overmob/pusher-push-notifications
Files in overmob/pusher-push-notifications
Package pusher-push-notifications
Short Description Pusher native Push Notifications driver.
License MIT
Homepage https://github.com/LaravelNotificationChannels/pusher-push-notifications
Informations about the package pusher-push-notifications
Pusher push notifications channel for Laravel 5.5
This package makes it easy to send Pusher push notifications with Laravel 5.5.
Contents
- Installation
- Setting up your Pusher account
- Usage
- Available Message methods
- Changelog
- Testing
- Security
- Contributing
- Credits
- License
Installation
You can install the package via composer:
You could install the service provider:
Setting up your Pusher account
Before using this package you should set up a Pusher account. Here are the steps required.
- Login to https://dashboard.pusher.com/
- Select your app from the sidebar or create a new app.
- Click on the "Push Notifications" tab.
- Upload your APNS Certificate or add your GCM API key.
- Now select the "App Keys" tab.
- Copy your
app_id
,key
, andsecret
. - Update the values in your
config/broadcasting.php
file under the pusher connection. - You're now good to go.
Usage
Now you can use the channel in your via()
method inside the Notification class.
Available Message methods
platform('')
: Accepts a string value ofiOS
orAndroid
.iOS()
: Sets the platform value to iOS.android()
: Sets the platform value to Android.title('')
: Accepts a string value for the title.body('')
: Accepts a string value for the body.sound('')
: Accepts a string value for the notification sound file. Notice that if you leave blank the default sound value will bedefault
.icon('')
: Accepts a string value for the icon file. (Android Only)badge(1)
: Accepts an integer value for the badge. (iOS Only)setOption($key, $value)
: Allows you to set any value in the message payload. For more information check here for iOS, or here for Android.
Sending to multiple platforms
You can send a single message to an iOS device and an Android device at the same time using the withiOS()
and withAndroid()
method:
- Notice that iOS is the default platform, which means you don't have to call
->iOS()
.- When using
withAndroid()
orwithiOS()
you don't have to define the platform, it's done behind the scenes for you.
Routing a message
By default the pusher "interest" messages will be sent to will be defined using the {notifiable}.{id} convention, for example App.User.1
, however you can change this behaviour by including a routeNotificationForPusherPushNotifications()
in the notifiable class method that returns the interest name.
Changelog
Please see CHANGELOG for more information what has changed recently.
Testing
Security
If you discover any security related issues, please email [email protected] instead of using the issue tracker.
Contributing
Please see CONTRIBUTING for details.
Credits
- Mohamed Said
- Marcel Pociot
- Freek Van der Herten
- Sebastian De Deyne
- All Contributors
License
The MIT License (MIT). Please see License File for more information.
All versions of pusher-push-notifications with dependencies
illuminate/events Version 5.4.*
illuminate/notifications Version 5.4.*
illuminate/queue Version 5.4.*
illuminate/support Version 5.4.*
pusher/pusher-php-server Version 2.6.*