/twilio-whatsapp-invoice

Companion repo for my article on sending PDFs via Whatsapp using Laravel and the Twilio API for Whatsapp

Primary LanguagePHP

Installation

Clone this repository to your local machine with:

$ git clone https://github.com/idoqo/twilio-whatsapp-invoice

Next, change into the project directory:

$ cd twilio-whatsapp-invoice

and install the project dependencies with:

$ composer install

Copy the .env.example to .env with:

$ cp .env.example .env

Remember to update the following with your actual credentials in the env file.

  • STRIPE_PUB_KEY
  • STRIPE_SECRET_KEY
  • TWILIO_ACCOUNT_SID
  • TWILIO_AUTH_TOKEN
  • TWILIO_SANDBOX_NUMBER

Note: If you're developing locally, the NGROK_URL will be gotten when you run the ngrok command later, remember to fill that in as well.

Start the application server and fire up nginx to listen on the server port.

php artisan serve
ngrok http 8000

Now, the application should be accessible at http://localhost:8000.

Resources

License

This project is open-sourced software licensed under the MIT license.