Download the PHP package ocuru/notifyme without Composer

On this page you can find all versions of the php package ocuru/notifyme. 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 notifyme

Ocuru\Notify

Note: This package is under heavy development and is not recommended for production.

Installing New

Install using Composer.

Installing

Install using Composer.

Available Services

Below are the services we currently support, more will be added over time.

Email Service

Service ID Data Required for Notification Optional Data
email ToName, ToEmail, FromName, FromEmail, Subject, MessagePlainText isHTML, MessageHTML (if isHTML = true), ReplyToName, ReplyToEmail
Data
Service ID Data Required for Notification Optional Data
email to.name, to.email, from.name from.email, message.is_html, message.plain_text message.html (if message.is_html = true)
Data Format

Twilio Service

Service ID Data Required for Notification
twilio ToPhoneNumber, FromSMSName, FromPhoneNumber, MessageSMS
Data

Basic Setup

Service ID Data Required for Notification
twilio to.name, to.number, from.name, from.number, message.short
Data Format

Basic Setup

Below is the basic setup you need to run the example code in this document.

Environmental Variables

You need to first set the .env file location using the below code. This is required.

If you haven't already set up your .env file , ocuru/notify installs vlucas/phpdotenv onto the system.

Below is the basic setup of Dotenv where $_ENV['ENV_LOCATION'] is the location of your .env file.

Place the below code before the $Notify variable if setup is needed.

Each service will need a different set some .env variables, these are show below.

Email

======= To set up each service you will need to set some .env variables, these are show below.

Email

Twilio

After Setting .env Variables

In the below example we show you how to setup the services you want to use. You should only run these methods once you have set up all the environmental variables you need shown here. If you don't then an exception will be thrown.

The array can consist of any of the service names shown in the Service ID part of each service List of Services area.

After Setting .env Variables

In the below example we show you how to setup the services you want to use. You should only run these methods once you have set up all the environmental variables you need shown here. If you don't then an exception will be thrown.

The array can consist of any of the service names shown in square brackets in the List of Services area.

The $Notify->start(); method is required for Ocuru\Notify to initialize. However the $Notify->use(); method isn't required but if you run $Notify->start(); without it we will attempt to setup the Email service which is Ocuru\Notify's default service. If no Environmental Variables are found for the Email Service then a exception will be thrown.

Notifying Users

To notify a user you can use the methods shown below. If an error occurs, we will throw an exception.

Below is the first example of how to send a notification, this sends a notification through all services you have set up.

In order to send a notification you will need to make sure all variables needed for each service are set. You can find out how to do this and what variables are required here.

However you can also send via specific services using the same method, all you need to do is pass an array of services as the first parameter. For Example.

The $Notify->start(); method is required for Ocuru\Notify to initialize. However the $Notify->use(); method isn't required but if you run $Notify->start(); without it we will attempt to setup the Email service which is set and Global Default. If no Environmental Variables are found for the Email Service then a exception will be thrown.

Notifying Users

To notify a user you can use the methods shown below.

Below is the first example of how to send a notification, this sends a notification through all services you have set up.

The next example shows you how to send a notification using a specific service. Through the $Notify->notify($data); method.

The final example shows you how to send a notification using the services base Notify Method. For example $Notify->email->notify($data);


All versions of notifyme with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.3
vlucas/phpdotenv Version ^2.4
phpmailer/phpmailer Version ^5.2
twilio/sdk Version ^5.4
plivo/plivo-php Version ^1.1
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 ocuru/notifyme contains the following files

Loading the files please wait ....