Skip to content

bradenkeith/receive-mms-laravel

 
 

Repository files navigation

Twilio

Recieve SMS and MMS Messages. Powered by Twilio - PHP/Laravel

Build Status

Use Twilio to receive SMS and MMS messages. For a step-by-step tutorial see the Twilio docs.

Local development

First you need to install PHP and Composer.

To run the app locally:

  1. Clone this repository and cd into it

    git clone [email protected]:TwilioDevEd/receive-mms-laravel.git && \
    
    cd receive-mms-laravel
  2. Install dependencies

    composer install
  3. Copy the sample configuration file and edit it to match your configuration

    cp .env-example .env

    You can find your TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN in your Twilio Account Settings. You will also need a TWILIO_NUMBER, which you may find here.

    Run source .env to export the environment variables

  4. Create database file and run migrations:

    touch ./database/database.sqlite && \
    php artisan migrate --force
  5. Run the application

    php artisan serve --port 8000
  6. Run ngrok:

    ngrok http 8000
    

Be sure to copy the ngrok http url and associate it with your Twilio Phone Number in your twilio console. The incoming SMS webhook url for your number should be as follows: https://<given-ngrok-domain>/api/incoming

  1. Check it out at http://localhost:8000

That's it

Run the tests

You can run the tests locally by typing

phpunit

Meta

  • No warranty expressed or implied. Software is as is. Diggity.
  • MIT License
  • Lovingly crafted by Twilio Developer Education.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 89.0%
  • HTML 5.5%
  • JavaScript 2.9%
  • CSS 1.3%
  • Vue 0.6%
  • ApacheConf 0.6%
  • Shell 0.1%