定制 tomal2000/laravel-sms-pro 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

tomal2000/laravel-sms-pro

Composer 安装命令:

composer require tomal2000/laravel-sms-pro

包简介

A Package For Sending Sms From Various Bulk Sms Service Provider

README 文档

README

Laravel SMS Pro allows you to send SMS from your Laravel application using multiple bulk sms service provider's api. Note: Now Only SMSQ Provider Availble. (Othrs Are Comming Soon)

Requirements

  • PHP >=8.1

Installation

Step 1

You can install the package via composer:

composer require tomal2000/laravel-sms-pro

Laravel 5.5 and above

The package will automatically register itself, so you can start using it immediately.

Laravel 5.4 and older

In Laravel version 5.4 and older, you have to add the service provider in config/app.php file manually:

'providers' => [
    // ...
    Tomal2000\LaravelSmsPro\LaravelSmsProServiceProvider::class,
];

Lumen

After installing the package, you will have to register it in bootstrap/app.php file manually:

// Register Service Providers
    // ...
    $app->register(Tomal2000\LaravelSmsPro\LaravelSmsProServiceProvider::class);
];

Env Keys

SMS_SENDER=
SMSQ_APIKEY=
SMSQ_CLINTID=

Step 2 - Publishing files

Run: php artisan vendor:publish --tag=laravel-sms-pro This will move the migration file, seeder file and config file to your app. You can set your sms details in the config file or via env

Step 3 - Adding SMS credentials

  • Add the env keys to your .env file
  • Or edit the config/laravel-sms-pro.php file

Usage

//using SMSQ Provider
use use Tomal2000\LaravelSmsPro\Concrete\SMSQ;

sms = new SMSQ();

$sms->text('This Laravel Test Message')->to('8801307366733')->from('MyLaravel')->send(); //return true/false for success/failed

//to('880130736673','8801736744457') use like this if you want to sent message to multiple numbers. Country Code is Mandatory
//from(string 'MyLaravel') Thsi Optional If Not set it then got Sender Id Form SMS_SENDER env key from .env or laravel-sms-pro.php file.

$sms->getResponse(); //also you can get response payload using this

$sms->getException(); //also you can get exception if error occured using this,exceptions will be logged in your laravel log file

Available SMS Providers

Provider URL Tested
SMSQ https://api.smsq.global/swagger/index.html Yes

Contributing

  • Fork this project
  • Clone to your repo
  • Clone your forked repo
  • Make your changes and test
  • Push and create Pull request
  • Push and create Pull Request
  • Make sure your PR passes all checks

统计信息

  • 总下载量: 1
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-11-14

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固