1. Go to this page and download the library: Download banulakwin/laravel-sms library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
banulakwin / laravel-sms example snippets
use Banulakwin\Sms\DTOs\SendSmsRequest;
// Send to a single recipient (uses default driver)
$response = sms()->send(new SendSmsRequest(
recipients: ['94712345678'],
message: 'Your OTP is 1234',
));
// Send to multiple recipients
$response = sms()->send(new SendSmsRequest(
recipients: ['94712345678', '94771234567', '94701234567'],
message: 'Bulk notification message',
));
// Override sender ID per-request
$response = sms()->send(new SendSmsRequest(
recipients: ['94712345678'],
message: 'Hello!',
senderId: 'CustomName',
));