fd6130 / exabytes-sms-bundle
This bundle provide sms service using exabytes malaysia api.
Installs: 334
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- php: >=7.2.5
- symfony/http-client: ^4.4|^5.0|^6.0
- symfony/yaml: ^4.4|^5.0|^6.0
This package is auto-updated.
Last update: 2025-02-25 15:05:33 UTC
README
Send sms using exabytes malaysia api. For more detail regarding the api, please read documentation.
Requirement
- PHP 7.2+
- Symfony 4.4+ and 5+
Installation
composer require fd6130/exabytes-sms-bundle
If you are using flex, it will automatic add this bundle to
bundles.php
.
Configuration
Update your .env to include this two variable:
# .env
EXABYTES_USERNAME=
EXABYTES_PASSWORD=
And then create the config file /config/fd_exabytes.yaml
and put the following content:
fd_exabytes: username: '%env(EXABYTES_USERNAME)%' password: '%env(EXABYTES_PASSWORD)%'
Inject ExabytesInterface
and start sending sms:
private $exabytes; public function __construct(ExabytesInterface $exabytes) { $this->exabytes = $exabytes; } public function sendSMS() { $this->exabytes->send('mobile number', 'message', ExabytesInterface::ASCII); //... }