misaf / laravel-sms-gateway-plivo
Plivo SMS gateway driver for Laravel.
Package info
github.com/misaf/laravel-sms-gateway-plivo
pkg:composer/misaf/laravel-sms-gateway-plivo
v3.0.0
2026-07-04 09:53 UTC
Requires
- php: ^8.3
- misaf/laravel-sms-gateway: ^3.0
Requires (Dev)
- guzzlehttp/guzzle: ^7.10
- larastan/larastan: ^3.9.2
- laravel/pint: ^1.29
- mockery/mockery: ^1.6.12
- nunomaduro/collision: ^8.8.3
- orchestra/testbench: ^11.0
- pestphp/pest: ^4.3.2
- pestphp/pest-plugin-laravel: ^4.0
This package is auto-updated.
Last update: 2026-07-04 09:54:16 UTC
README
Plivo SMS gateway driver for misaf/laravel-sms-gateway.
Installation
composer require misaf/laravel-sms-gateway-plivo
Laravel package discovery registers the driver service provider automatically.
Configuration
SMS_GATEWAY_DRIVER=plivo SMS_GATEWAY_PLIVO_AUTH_ID=your-auth-id SMS_GATEWAY_PLIVO_AUTH_TOKEN=your-auth-token
// config/services.php 'plivo' => [ 'auth_id' => env('SMS_GATEWAY_PLIVO_AUTH_ID'), 'auth_token' => env('SMS_GATEWAY_PLIVO_AUTH_TOKEN'), 'base_url' => env('SMS_GATEWAY_PLIVO_BASE_URL'), ],
By default, the auth ID is included in the base URL path. If you override base_url, include the account-specific path segment expected by Plivo.
Driver Behavior
| Option | Value |
|---|---|
| Driver name | plivo |
| Default base URL | https://api.plivo.com/v1/Account/{auth_id}/ |
send() endpoint |
POST Message/ |
| Authentication | HTTP Basic auth from services.plivo.auth_id and services.plivo.auth_token |
| Payload | JSON data sent directly to Plivo |
Usage
use Misaf\LaravelSmsGateway\Facade\SmsGateway; $response = SmsGateway::driver('plivo')->send([ 'src' => '14151234567', 'dst' => '14157654321', 'text' => 'Hello from Plivo', ]);
The payload is passed directly to Plivo, so use the fields expected by the Plivo API.
Use request() when you need direct access to Laravel's HTTP client:
$request = SmsGateway::driver('plivo')->request();
Testing
composer test
composer analyse
License
MIT