Clickatell notifications driver

Clickatell notifications driver

README

Latest Version on Packagist
Software License
Build Status
StyleCI
SensioLabsInsight
Quality Score
Code Coverage
Total Downloads

This package makes it easy to send notifications using clickatell.com with Laravel 5.3, 5.4, 5.5, 5.6, 5.7

Contents

Installation

You can install the package via composer:

composer require laravel-notification-channels/clickatell

In Laravel 5.5+ the service provider will automatically get registered. In older versions of the framework just add the service provider in config/app.php file:

'providers' => [
    ...
    NotificationChannelsClickatellClickatellServiceProvider::class,
],

Setting up the clickatell service

Add your Clickatell user, password and api identifier to your config/services.php:

// config/services.php
...
'clickatell' => [
    'user'  => env('CLICKATELL_USER'),
    'pass' => env('CLICKATELL_PASS'),
    'api_id' => env('CLICKATELL_API_ID'),
],
...

Usage

You can use the channel in your via() method inside the notification:

use IlluminateNotificationsNotification;
use NotificationChannelsClickatellClickatellMessage;
use NotificationChannelsClickatellClickatellChannel;

class AccountApproved extends Notification
{
    public function via($notifiable)
    {
        return [ClickatellChannel::class];
    }

    public function toClickatell($notifiable)
    {
        return (new ClickatellMessage())
            ->content("Your {$notifiable->service} account was approved!");
    }
}

Available methods

TODO

Changelog

Please see CHANGELOG for more information what has changed recently.

Testing

$ composer test

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

License

The MIT License (MIT). Please see License File for more information.

Source

Add a Comment

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *