承接 autoxloo/yii2-twilio 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

autoxloo/yii2-twilio

Composer 安装命令:

composer require autoxloo/yii2-twilio

包简介

Yii2 wrap of Twilio sms PHP SDK

README 文档

README

Yii2 wrap of Twilio sms PHP SDK

Note: This package is not supported properly

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist autoxloo/yii2-twilio "*"

or

composer require --prefer-dist autoxloo/yii2-twilio "*"

or add

"autoxloo/yii2-twilio": "*"

to the require section of your composer.json file.

Config

In your application config add:

// ...
'components' => [
        // ...
        'twilioSms' => [
            'class' => \autoxloo\yii2\twilio\sms\TwilioSms::class,
            'sid' => 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX',          // Your Account Sid from twilio.com/user/account
            'token' => 'your_auth_token',                           // Your Account Auth Token from twilio.com/user/account
        ],
],

Usage

Once the extension is installed, simply use it in your code by:

\Yii::$app->twilioSms->sendSms(
    '+15558675309',                                         // the number you'd like to send the message to
    [
        TwilioSms::OPTION_FROM => '+15017250604',                           // A Twilio phone number you purchased at twilio.com/console
        TwilioSms::OPTION_BODY => 'Hey Jenny! Good luck on the bar exam!',  // the body of the text message you'd like to send
    ]
);

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2018-09-20

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固