https://github.com/unisharp/sms
https://github.com/unisharp/sms
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/unisharp/sms
- Owner: UniSharp
- License: mit
- Created: 2018-07-20T07:50:59.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-10-30T07:59:32.000Z (over 7 years ago)
- Last Synced: 2025-06-04T03:17:19.938Z (about 1 year ago)
- Language: PHP
- Size: 8.79 KB
- Stars: 2
- Watchers: 11
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SMS package for Laravel
Only support APTG SMS for now.
## Installation
```
composer require unisharp/sms
```
## Usage
### Using facade
Edit `.env`:
```
APTG_MDN=xxx
APTG_UID=yyy
APTG_UPASS=zzz
SMS_IS_DRY_RUN=false // If set to true, no sms will be sent. Only log messages are recorded.
```
Code:
```
\Sms::send($phone_number, $message); // boolean value is returned.
```
### Pass credentials manually
```
$client = new AptgSmsClient('your APTG_MDN', 'your APTG_UID', 'your APTG_UPASS');
$response = $client->send([$phone_number], $message); // Instance of AptgClient is returned.
```