Giter Site home page Giter Site logo

laratwilio's Introduction

Laratwilio

  • simple wrapper for sending sms messages via twilio with Laravel4.
  • calls or anything else other than sending sms messages is not currently supported (pull requests welcome)

Installation

  1. add the following to your composer require:

     "twilio/laratwilio": "dev-master"
    
  2. run from terminal:

     composer update
    
  3. add Laratwilio to the list of providers. In config/app.php add the following line to the providers array:

     'Twilio\Laratwilio\LaratwilioServiceProvider'
    
  4. add a Facade for more convenient usage. In config/app.php add the following line to the aliases array:

     'Sms' => 'Twilio\Laratwilio\Facades\Laratwilio'
    
  5. publish config files so that you can put your Twilio details in the right place. In your terminal:

     php artisan config:publish twilio/laratwilio
    
  6. edit the new config file in the config/packages/twilio/laratwilio and enter your data

Usage

Anywhere in your application when you need to send an sms message, just do:

Sms::send(array('to'=>'+12345678', 'text'=>'hello world'));

Disclaimer

This is my first package and I'm very new to all this.

Most likely I'm doing lots of things wrong. Use at your own risk.

If there is a better way of doing anything here - I'm looking forward to your pull requests.

May the force be with you.

laratwilio's People

Contributors

georgestrakhov avatar mclassic avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.