PHPackages                             shipu/banglalink-sms-gateway - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. shipu/banglalink-sms-gateway

ActiveLibrary[API Development](/categories/api)

shipu/banglalink-sms-gateway
============================

Banglalink sms gateway

v1.2(7y ago)321.1k20MITPHP

Since Jul 25Pushed 7y ago1 watchersCompare

[ Source](https://github.com/Shipu/banglalink-sms-gateway)[ Packagist](https://packagist.org/packages/shipu/banglalink-sms-gateway)[ RSS](/packages/shipu-banglalink-sms-gateway/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (1)Versions (4)Used By (0)

Banglalink SMS GATEWAY
======================

[](#banglalink-sms-gateway)

 A PHP client for Banglalink SMS Gateway API. This package is also support Laravel and Lumen.

Installation
------------

[](#installation)

Go to terminal and run this command

```
composer require shipu/banglalink-sms-gateway
```

Wait for few minutes. Composer will automatically install the package for your project.

#### For Laravel

[](#for-laravel)

Below **Laravel 5.5** open `config/app` and add this line in `providers` section

```
Shipu\BanglalinkSmsGateway\Providers\BanglalinkSmsGatewayServiceProvider::class,
```

For Facade support you have to add this line in the `aliases` section.

```
'Banglalink'   =>  Shipu\BanglalinkSmsGateway\Facades\Banglalink::class,
```

Then run this command

```
php artisan vendor:publish --provider="Shipu\BanglalinkSmsGateway\Providers\BanglalinkSmsGatewayServiceProvider"
```

For PHP Configuration
---------------------

[](#for-php-configuration)

This package is required two configurations.

1. user\_id = your user\_id which is provided by Banglalink.
2. password = your password which is also provided by Banglalink.

banglalink-sms-gateway is take an array as config file. Lets services

```
use Shipu\BanglalinkSmsGateway\Banglalink;

$config = [
    'user_id' => 'Your User Id',
    'password' => 'Your Password'
];

$sms = new Banglalink($config);
```

### For Laravel Configuration

[](#for-laravel-configuration)

This package is also support Laravel. For laravel you have to configure it as laravel style.

Go to `config/banglalink-sms-gateway.php` and configure it with your credentials.

```
return [
    'user_id' => 'Your User id',
    'password' => 'Your Password'
];
```

Usages
------

[](#usages)

Its very easy to use. This packages has a lot of functionalities and features.

### Send SMS to a single user

[](#send-sms-to-a-single-user)

**In PHP:**

```
use \Shipu\BanglalinkSmsGateway\Services\Banglalink;

...

$sms = new Banglalink($config);
$response = $sms->message('your text here !!!', '01606022000')->send(); // Guzzle Response with request data

// For another example please see below laravel section.

return $response->autoParse(); // Getting only response contents.
```

**In Laravel:**

```
use \Shipu\BanglalinkSmsGateway\Facades\Banglalink;

...

$sms = Banglalink::message('your text here !!!', '01606022000')->send(); // Guzzle Response with request data

// or

$sms = Banglalink::message('your text here !!!')->to('01606022000')->send();

// or

$sms = Banglalink::send(
    [
        'message' => "your text here",
        'to' => '01616022000'
    ]
);
return $sms->autoParse(); // Getting only response contents.
```

### Send same message to all users

[](#send-same-message-to-all-users)

```
$sms = Banglalink::message('your text here !!!')
            ->to('01616022669')
            ->to('01845736124')
            ->to('01745987364')
            ->send();

// or you can try below statements also

$sms = Banglalink::message('your text here !!!', '01616022669')
            ->to('01845736124')
            ->to('01745987364')
            ->send();

// or

$users = [
    '01616022669',
    '01845736124',
    '01745987364'
];
$sms = Banglalink::message('your text here !!!',$users)->send();
```

### Send SMS to more user

[](#send-sms-to-more-user)

```
$sms = Banglalink::message('your text here one !!!')->to('01616022669')
            ->message('your text here two !!!')->to('01845736124')
            ->message('your text here three !!!')->to('01745987364')
            ->send();
// or

$sms = Banglalink::message('your text here one !!!', '01616022669')
            ->message('your text here two !!!', '01845736124')
            ->message('your text here three !!!', '01745987364')
            ->send();

// or

$sms = Banglalink::send([
    [
        'message' => "your text here one !!!",
        'to' => '01616022669'
    ],
    [
        'message' => "your text here two !!!",
        'to' => '01707722669'
    ],
    [
        'message' => "your text here three !!!",
        'to' => '01745987364'
    ]
]);

// or

$sms = Banglalink::message('your text here one !!!', '01616022669')->send([
    [
        'message' => "your text here two !!!",
        'to' => '01707722669'
    ],
    [
        'message' => "your text here three !!!",
        'to' => '01745987364'
    ]
]);
```

### Send SMS with SMS template

[](#send-sms-with-sms-template)

Suppose you have to send SMS to multiple users but you want to mention their name dynamically with message. So what can you do? Ha ha this package has already handled this situation. Lets see

```
$users = [
    ['01670420420', ['Nahid', '1234']],
    ['01970420420', ['Rana', '3213']],
    ['01770420420', ['Shipu', '5000']],
    ['01570420420', ['Kaiser', '3214']],
    ['01870420420', ['Eather', '7642']]
]
$sms = new \Shipu\BanglalinkSmsGateway\Services\Banglalink(config('banglalink-sms-gateway'));
$msg = $sms->message("Hello %s , Your promo code is: %s", $users)->send();

// or

$users = [
    '01670420420' => ['Nahid', '1234'],
    '01970420420' => ['Rana', '3213'],
    '01770420420' => ['Shipu', '5000'],
    '01570420420' => ['Kaiser', '3214'],
    '01870420420' => ['Eather', '7642']
]
$sms = new \Shipu\BanglalinkSmsGateway\Services\Banglalink(config('banglalink-sms-gateway'));
$msg = $sms->message("Hello %s , Your promo code is: %s", $users)->send();
```

Here this message will be sent to every users with his/her name and promo code like:

- `8801670420420` - Hello Nahid , Your promo code is: 1234
- `8801970420420` - Hello Rana , Your promo code is: 3213
- `8801770420420` - Hello Shipu , Your promo code is: 5000
- `8801570420420` - Hello Kaiser , Your promo code is: 1234
- `8801870420420` - Hello Eather , Your promo code is: 7642

### Change Number Prefix

[](#change-number-prefix)

```
$sms = Banglalink::numberPrefix('91')->message('your text here !!!', '01606022000')->send();
```

Default number prefix is `88`;

### Send sms with sender name

[](#send-sms-with-sender-name)

```
$sms = Banglalink::sender('XYZ Company')->message('your text here !!!', '01606022000')->send();
```

Default sender name is `null`. for details please contact to banglalink customer support;

### Debugging

[](#debugging)

```
$sms = Banglalink::debug(true)->message('your text here !!!', '01606022000')->send(); // // debug true or blank.
```

Default value is `false`. When debug `true` it's stop sending SMS and return sending query strings.

### Response Data auto parse

[](#response-data-auto-parse)

```
$sms = Banglalink::autoParse(true)->message('your text here !!!', '01606022000')->send(); // autoParse true or blank.
```

Default value is `false`.

### Disable Template

[](#disable-template)

```
$sms = Banglalink::template(false)->message('your text here !!!', '01606022000')->send();
```

Default value is `true`.

### Response Data

[](#response-data)

```
dd($sms);
```

Response :

```
Response {#463 ▼
  #response: Response {#446 ▶}
  #request: Request {#428 ▼
    -method: "GET"
    -requestTarget: null
    -uri: Uri {#429 ▶}
    -headers: []
    -headerNames: []
    -protocol: "1.1"
    -stream: null
    +"details": array:3 [▼
      "url" => "https://vas.banglalinkgsm.com/sendSMS/sendSMS"
      "method" => "GET"
      "parameters" => array:1 [▼
        "query" => array:5 [▶]
      ]
    ]
  }
  #contents: "Success Count : 2 and Fail Count : 0"
}
```

Response auto parse:

```
dd($sms->autoParse());
```

Response

```
"Success Count : 2 and Fail Count : 0"

```

### Response Details

[](#response-details)

```
$sms = Banglalink::details()->message('your text here !!!', '01606022000')->send();
```

Response:

```
[
    'success' => 1,
    'failed' => 0
]

```

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity30

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

3

Last Release

2846d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/91fdb46a4f45685ae0d448fbc943b1e4a662b56864b17224a65d14c92ee4e247?d=identicon)[shipu](/maintainers/shipu)

---

Top Contributors

[![Shipu](https://avatars.githubusercontent.com/u/4118421?v=4)](https://github.com/Shipu "Shipu (8 commits)")[![zisuzon](https://avatars.githubusercontent.com/u/6716994?v=4)](https://github.com/zisuzon "zisuzon (2 commits)")

---

Tags

apibanglalinklaravelpackagephp-clientsms-gateway

### Embed Badge

![Health badge](/badges/shipu-banglalink-sms-gateway/health.svg)

```
[![Health](https://phpackages.com/badges/shipu-banglalink-sms-gateway/health.svg)](https://phpackages.com/packages/shipu-banglalink-sms-gateway)
```

###  Alternatives

[stripe/stripe-php

Stripe PHP Library

4.0k143.3M480](/packages/stripe-stripe-php)[twilio/sdk

A PHP wrapper for Twilio's API

1.6k92.9M272](/packages/twilio-sdk)[knplabs/github-api

GitHub API v3 client

2.2k15.8M187](/packages/knplabs-github-api)[facebook/php-business-sdk

PHP SDK for Facebook Business

90121.9M34](/packages/facebook-php-business-sdk)[meilisearch/meilisearch-php

PHP wrapper for the Meilisearch API

73813.7M114](/packages/meilisearch-meilisearch-php)[google/gax

Google API Core for PHP

263103.1M454](/packages/google-gax)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
