driveop / twilio-bundle
A simple Symfony bundle for Twilio API.
Installs: 48
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- php: >=7.1
- symfony/config: ^3.0
- symfony/dependency-injection: ^3.0
- symfony/framework-bundle: ^3.0
- symfony/http-foundation: ^3.0
- symfony/http-kernel: ^3.0
- symfony/options-resolver: ^3.0
- symfony/validator: ^3.0
- twilio/sdk: ^5.0
This package is auto-updated.
Last update: 2025-04-07 07:10:53 UTC
README
A simple Symfony bundle for Twilio Api.
Only SMS/WhatsApp!
Setup
Step 1: Download DriveOpTwilioBundle using composer
Add Twilio Bundle in your composer.json:
{ "require": { "driveop/twilio-bundle": "^0.1" } }
Now tell composer to download the bundle by running the command:
$ php composer.phar update "driveop/twilio-bundle"
Step 2: Enable the bundle
Enable the bundle in the kernel:
<?php // app/AppKernel.php public function registerBundles() { $bundles = array( // ... new DriveOp\TwilioBundle\DriveOpTwilioBundle() ); }
Step 3: Add configuration
# app/config/config.yml driveop: twilio: twilio_sid: %twilio_sid% twilio_token: %twilio_token%
Usage
Using service
<?php $twilioClient = $this->get('twilio_client'); ?>
##Example
###Send WhatsApp message
<?php $message = $twilioClient->sendWhatsAppMessage($to, $from, $body); ?>