Download the PHP package coreproc/laravel-notification-channel-telerivet without Composer

On this page you can find all versions of the php package coreproc/laravel-notification-channel-telerivet. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-notification-channel-telerivet

Laravel Telerivet Notification Channel

Latest Version on Packagist StyleCI Quality Score Total Downloads

This package makes it easy to send notifications using Telerivet with Laravel 5.5+ and 6.0

Contents

Upgrading from v1.x to v2.x

In v2.x, we've moved the configuration settings of Telerivet from config/broadcasting.php to config/telerivet.php.

To migrate to v2.x, simply run the following command to get the configuration file:

Installation

Install this package with Composer:

composer require coreproc/laravel-notification-channel-telerivet

Register the ServiceProvider in your config/app.php (Skip this step if you are using Laravel 5.5):

CoreProc\NotificationChannels\Telerivet\TelerivetServiceProvider::class,

Setting up the Telerivet service

You need to register for an API key and a number for outgoing SMS here: https://telerivet.com

Once you've registered and set up your project and numbers, get the configuration file by running the following command:

Add the API key and project ID to your configuration in config/telerivet.php. You can set the credentials in your .env file with the following variables: TELERIVET_API_KEY and TELERIVET_PROJECT_ID.

Optionally, you can also override these configurations by calling the setApiKey() and setProjectId() methods in your TelerivetMessage object.

Usage

You can now send SMS via Telerivet by creating a TelerivetMessage:

You will have to set a routeNotificationForTelerivet() method in your notifiable model. For example:

Once you have that in place, you can simply send an SMS notification to the user via

Events

You can listen to these event when sending a Telerivet SMS message:

Before an SMS is sent:

TelerivetSmsSending::class

When an SMS is sent (this means that the API call to Telerivet was successful):

TelerivetSmsSent::class

When an SMS fails to send (this means the API call to Telerivet has failed):

TelerivetSmsFailed::class

Available Message methods

All the parameters that can be used for a Telerivet message can be applied through the TelerivetMessage object. The documentation from Telerivet can be found here here.

[Optional] Type of message to send. If text, will use the default text message type for the selected route.

Possible Values: sms, mms, ussd, call, text

Default: text

[Required if sending SMS message] Content of the message to send (if message_type is call, the text will be spoken during a text-to-speech call)

[Required if contact_id not set] Phone number to send the message to. This is automatically set if you have defined the routeNotificationForTelerivet() method in your notifiable object.

[Required if to_number not set] ID of the contact to send the message to. This can be automatically set if you have defined a routeNotificationForTelerivetContactId() method in your notifiable object.

[Optional] ID of the phone or route to send the message from

Default: default sender route ID for your project

[Optional] Webhook callback URL to be notified when message status changes

[Optional] POST parameter 'secret' passed to status_url

[Optional] Set to true to evaluate variables like [[contact.name]] in message content.

(See available variables here)

Default: false

[Optional] If true, URLs in the message content will automatically be replaced with unique short URLs.

Default: false

[Optional] URLs of media files to attach to the text message. If message_type is sms, short links to each media

URL will be appended to the end of the content (separated by a new line).

[Optional] Array string IDs of Label

List of IDs of labels to add to this message

[Optional] Custom variables to store with the message

[Optional] Priority of the message. Telerivet will attempt to send messages with higher priority numbers first (for example, so you can prioritize an auto-reply ahead of a bulk message to a large group).

Possible Values: 1, 2

Default: 1

[Optional] Set to true to test the Telerivet API without actually sending a message from the route

Default: false

[Optional] string ID of Service

Service that defines the call flow of the voice call (when message_type is call)

[Optional] The URL of an MP3 file to play when the contact answers the call (when message_type is call).

If audio_url is provided, the text-to-speech voice is not used to say content, although you can optionally use content to indicate the script for the audio.

For best results, use an MP3 file containing only speech. Music is not recommended because the audio quality will be low when played over a phone line.

[Optional] The language of the text-to-speech voice (when message_type is call)

Possible Values: en-US, en-GB, en-GB-WLS, en-AU, en-IN, da-DK, nl-NL, fr-FR, fr-CA, de-DE, is-IS, it-IT, pl-PL, pt-BR, pt-PT, ru-RU, es-ES, es-US, sv-SE

Default: en-US

[Optional] The name of the text-to-speech voice (when message_type=call)

Possible Values: female, male

Default: female

Changelog

Please see CHANGELOG for more information what has changed recently.

Security

If you discover any security related issues, please email to [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.


All versions of laravel-notification-channel-telerivet with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2
guzzlehttp/guzzle Version ^6.2 || ^7.0
illuminate/notifications Version ~5.5 || ~6.0 || ~7.0 || ~8.0
illuminate/support Version ~5.5 || ~6.0 || ~7.0 || ~8.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package coreproc/laravel-notification-channel-telerivet contains the following files

Loading the files please wait ....