定制 lelevar/sms 二次开发

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

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

lelevar/sms

最新稳定版本:v1.0.0

Composer 安装命令:

composer require lelevar/sms

包简介

Lelevar SMS Package for Laravel simplifies SMS sending via the Lelevar SMS API. It supports single and bulk SMS messaging with easy API key configuration, optional facades, and a helper function for quick integration. Ideal for integrating SMS into Laravel apps effortlessly.

README 文档

README

The Lelevar SMS Package is a Laravel package for sending SMS messages via the Lelevar SMS API (https://sms.lelevar.com). This package simplifies SMS sending functionality in your Laravel application.

Features

  • Send single SMS messages
  • Send multiple SMS messages
  • Easy integration with Laravel
  • Support for API key configuration

Installation

Via Composer

Install the package via Composer by running the following command in your Laravel project directory:

composer require lelevar/sms

Service Provider

If you are using Laravel 5.5 or later, the package will automatically be discovered. If you are using an earlier version of Laravel, you need to manually add the service provider to your config/app.php:

'providers' => [
    // Other service providers...
    Lelevar\Sms\SmsServiceProvider::class,
],

Facades (Optional)

For easier access to the package's functionality, you can add facades to your config/app.php:

'aliases' => [
    // Other aliases...
    'SmsService' => Lelevar\Sms\Facades\SmsService::class,
],

Configuration

The package uses an API key for authentication. Set your API key in your .env file:

LELEVAR_SMS_API_KEY=your_api_key_here
LELEVAR_SMS_SENDER_NAME=your_sender_name_here

Usage

Sending a Single SMS

You can send a single SMS message using the LelevarSendSms helper function:

use Lelevar\Sms\Facades\SmsService;

$response = LelevarSendSms([
    'mobile' => '**********',
    'content' => 'Hello World!',
    'sender_name' => '*******',
]);

dd($response);

License

This package is licensed under the MIT License.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-08-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固