weboxlt/lutex-api-v1-php-sdk 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

weboxlt/lutex-api-v1-php-sdk

最新稳定版本:v1.2

Composer 安装命令:

composer require weboxlt/lutex-api-v1-php-sdk

包简介

lutex API v1 PHP

关键字:

README 文档

README

Getting started

In order to use this library you need to have at least PHP 5.5 version. You can use it for lutex.lt API.

There are two ways to use lutex PHP SDK:

Use Composer

If you are not familiar with Composer, learn about it here.

Then you will need to run this simple command using CLI:

composer require weboxlt/lutex-api-v1-php-sdk
Manual

Download this archive, extract it and place its contents in your project. The next step is the same as using Composer, you will need to require vendor/autoload.php file in your index.php!

1. Usage example to send SMS message

$smsClient = new eSMS\SmsClient('YOUR_USERNAME', 'YOUR_PASSWORD');
try {
    $smsHandler = $smsClient->sms();
    $smsHandler->setFrom('YOUR NAME');
    $smsHandler->addRecipient('RECIPIENT_NUMBER_1');
    $smsHandler->addRecipient('RECIPIENT_NUMBER_2');
    $smsHandler->setMessage('Hello world!');
	
    $data = $smsHandler->sendSimpleSMS();
    $smsHandler->destroy();
} catch (\Exception $e) {
    print( $e->getMessage());
}

2. Usage example to receive logs

SMS logs are available for the last 48 hours!

$smsClient = new eSMS\SmsClient('YOUR_USERNAME', 'YOUR_PASSWORD');
try {
    $logsHandler = $smsClient->logs();
    $logsHandler->setLimit(10);
    $logsHandler->setMessageId('MESSAGE_ID');
    $logsHandler->setBulkId('BULK_ID');
    $logsHandler->setTo('PHONE_NUMBER');
    $logsHandler->setFrom('SENT_FROM');
    $logsHandler->setSentSince('2022-12-21');
    $logsHandler->setSentUntil('2022-12-25');
    $logsHandler->setGeneralStatus($logsHandler::STATUS_EXPIRED);

    $data = $logsHandler->get();
} catch (\Exception $e) {
    print( $e->getMessage());
}

Support and Feeback

In case you find any bugs, submit an issue directly here in GitHub.

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2019-10-01

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固