cloudrebue / api
PHP Cloud Rebue Bulk sms API SDK
v1.0.3
2023-01-02 16:37 UTC
Requires
- php: ^7.3 || ^8.1
- guzzlehttp/guzzle: ^6.5|^7.0.1
Requires (Dev)
- phpunit/phpunit: >=8.0
- squizlabs/php_codesniffer: ^3.0
This package is auto-updated.
Last update: 2024-10-30 01:48:11 UTC
README
This PHP SDK provides convenient methods for consuming CloudRebue API.
Documentation
CloudRebue API Documentation can be found at https://developers.cloudrebue.co.ke
Install
Via Composer (recommended)
$ composer require cloudrebue/api
Via Download
1. Clone or Download this Repo. 2. run `composer install` in the root of the project
Usage
Sending a Message
Detailed samples can be obtained from examples folder
<?php //include if your project wasent initialized with composer prior to downloading. //ensure path to vendor is correct require_once 'vendor/autoload.php'; use CloudRebue\Api\CloudRebue; use CloudRebue\Api\Models\Sms; $instance = new CloudRebue("TOKEN_string"); //create an Sms Object $sms= new Sms("CLOUD_REBUE", "0708361797", "Test Message 1", "101"); //send Sms object $response = $instance->sendSMS($sms); var_dump($response);
Sending Messages in batches
<?php //include if your project wasent initialized with composer prior to downloading. //ensure path to vendor is correct require_once 'vendor/autoload.php'; use CloudRebue\Api\CloudRebue; use CloudRebue\Api\Models\Sms; $instance = new CloudRebue("TOKEN_string"); //create multiple Sms Object(s) $sms1= new Sms("CLOUD_REBUE", "0708361797", "Test Message 1", "101"); $sms2 = new Sms("BizTxt", "0735343603"", "Test Message 2", "102"); //send Sms object $response = $instance->sendBatchSMS($sms1, $sms2); var_dump($response);
Available Methods are:
- sendSMS()
- sendBatchSMS()
- sendVoiceSMS()
- sendBatchVoiceSMS()
- accountBalance()
- accountTopUp()
Change log
Please see CHANGELOG for more information on what has changed recently.
Testing
$ composer test
Contributing
Please see CONTRIBUTING and CODE_OF_CONDUCT for details.
Security
If you discover any security related issues, please email edwardmuss5@gmail.com instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.