PHP code example of urukalo / localytics-push

1. Go to this page and download the library: Download urukalo/localytics-push library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

urukalo / localytics-push example snippets


        $data = [
            "device" => ["ios" => ["badge" => 1]]
        ];

        $query = new LocalyticsPush(
            config('localytics.api_key'), 
            config('localytics.api_sec'),
            config('localytics.app_key')
            );

        $query->equalTo('push_enabled', 1); //lookup for more criterias

        $query->send(str_slug('catalog-badge-brand-' . $catalogName), $data, "and");