dev-master
9999999-dev https://github.com/PushAssist/Web-Push-NotificationsWeb Push Notifications for websites
MIT
The Requires
- php >=5.3.2
push notifications web push notifications
 Wallogit.com
                    
                    2017 © Pedro Peláez
                         Wallogit.com
                    
                    2017 © Pedro Peláez
                    
                    
                    
                    
                
                
            
Web Push Notifications for websites
Push Notification Delivery & Analytics for Websites and Mobile, (*1)
Web Push Notifications is a PHP Library to quickly integrate and send push notifications with PushAssist REST API. Setup is easy just create a Free Account, verify your email address and login to your PushAssist Control Panel to get the API & Secret Keys., (*2)
Simply require and initialize the PushAssist class like:, (*3)
require_once 'PushAssist.php';
To install PushAssist Class, simply:, (*4)
$ composer require PushAssist/Web-Push-Notifications
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$notification_array = array("notification" => array(                                    
                            "title" => 'YOUR NOTIFICATION TITLE',
                            "message" => 'YOUR NOTIFICATION TITLE',
                            "redirect_url" => 'URL TO REDIRECT IF MESSAGE IS CLICKED',
                            "image" => 'MESSAGE IMAGE FULL PATH'),
                            //UTM is optional Keep it empty if you are not passing utm_params.
                            "utm_params" => array("utm_source" => $utm_source,  
                            "utm_medium" => $utm_medium,
                            "utm_campaign" => $utm_campaign),
                            //Segments is optional notification send only for those who subscribers by this  segment.
                            "segments" => ('Sports', 'Hockey'); 
                        );
$push_notification->pushassist_send_notification($notification_array)
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$campaign_array = array("campaign" => array(                                    
                            "title" => 'YOUR CAMPAIGN TITLE',
                            "message" => 'YOUR CAMPAIGN TITLE',
                            "redirect_url" => 'URL TO REDIRECT IF MESSAGE IS CLICKED',
                            "timezone" => 'TIME ZONE FORMAT(Y-M-D) 24 HOUR FORMAT',
                            "image" => 'MESSAGE IMAGE FULL PATH'),
                            //UTM is optional Keep it empty if you are not passing utm_params.
                            "utm_params" => array("utm_source" => $utm_source,  
                            "utm_medium" => $utm_medium,
                            "utm_campaign" => $utm_campaign),
                            //Segments is optional Campaign send only for those who subscribers by this  segment.
                            "segments" => ('Sports', 'Hockey'); 
                        );
$push_notification->pushassist_create_campaigns($campaign_array)
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$segment_array = array("segment" => array(
                                "segment_name" => 'YOUR SEGMENT NAME')
                            );
$push_notification->pushassist_create_segments($segment_array);
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_account_details();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_dashboard_details();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_notification_history();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_notification_details_by_id(ID);
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_notification_details_by_subdomain('ACCOUNT NAME');
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_campaigns_history();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_campaigns_details_by_id(ID);
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_campaigns_details_by_subdomain('ACCOUNT NAME');
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_segment_details();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_segment_details_by_id(ID);
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_segment_details_by_name('SEGMENT NAME');
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_segment_count();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_subscribers_details();
// Create an object
$push_notification = new PushAssist('YOUR API KEY', 'YOUR SECRET KEY');
$push_notification->pushassist_subscribers_details_by_subdomain('ACCOUNT NAME');
Feel free to integrate web-push-notification by PushAssist into your favorite PHP Framework. If you need any assistance just let us know., (*5)
PushAssist is a Push Notification SaaS service for sites. You can contact us by email at support@pushassist.com., (*6)
Web Push Notifications for websites
MIT
push notifications web push notifications