Skip to content

Commit

Permalink
Fix conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
Ariful Islam committed Dec 4, 2022
2 parents 26f5208 + 4eac952 commit 6a16a1d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,15 +168,14 @@ $status = $sender->send();


# Currently Supported SMS Gateways

| Provider | Credentials Required <br> For Sending SMS | Status | Comment | Contact |
|-----------------|-------------------------------------------------------------------|--------|------------------------|-------------------------------------------------------------|
| AjuraTech | apikey, secretkey , callerID | Done | - | - |
| Adn | api_key, type, senderid | Done | - | - |
| Banglalink | userID, passwd , sender | Done | - | - |
| BDBulkSMS | token | Done | - | - |
| BoomCast | masking , userName , password | Done | - | - |
| BulksmsBD | username, password | Done | - | - |
| BulksmsBD | api_key,senderid | Done | - | - |
| DianaHost | api_key, type, senderid | Done | - | - |
| DianaSMS | ApiKey, ClientId, SenderId | Done | - | - |
| Esms | api_token, sender_id | Done | - | - |
Expand All @@ -196,6 +195,7 @@ $status = $sender->send();
| TwentyFourSmsBD | apiKey, sender_id | Done | - | - |
| Viatech | api_key, mask | Done | - | - |


We are continuously working in this open source library for adding more Bangladeshi sms gateway. If you feel something
is missing then make a issue regarding that. If you want to contribute in this library, then you are highly welcome to
do that....
Expand Down
20 changes: 12 additions & 8 deletions src/Provider/BulkSmsBD.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,19 @@ public function sendRequest()
$queue = $this->senderObject->getQueue();

$query = [
'username' => $config['username'],
'password' => $config['password'],
'api_key' => $config['api_key'],
'type' => 'text',
'number' => $number,
'message' => $text,
];

$requestObject = new Request('http://66.45.237.70/api.php', $query, $queue);
if (array_key_exists('senderid', $config)) {
$query = [
'senderid' => $config['senderid'],
];
}

$requestObject = new Request('https://bulksmsbd.net/api/smsapi', $query, $queue);
$response = $requestObject->get();
if ($queue) {
return true;
Expand All @@ -64,11 +70,9 @@ public function sendRequest()
*/
public function errorException()
{
if (!array_key_exists('username', $this->senderObject->getConfig())) {
throw new ParameterException('username key is absent in configuration');
}
if (!array_key_exists('password', $this->senderObject->getConfig())) {
throw new ParameterException('password key is absent in configuration');
if (!array_key_exists('api_key', $this->senderObject->getConfig())) {
throw new ParameterException('api_key key is absent in configuration');
}

}
}

0 comments on commit 6a16a1d

Please sign in to comment.