PHPackages                             smsgate/client - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. smsgate/client

ActiveLibrary[HTTP &amp; Networking](/categories/http)

smsgate/client
==============

PHP Client for using SMS Gate HTTP API.

v1.0.1(7y ago)43.5k3MITPHPPHP &gt;=5.6

Since Mar 7Pushed 7y ago1 watchersCompare

[ Source](https://github.com/horisen/smsgate-smshttpclient-php)[ Packagist](https://packagist.org/packages/smsgate/client)[ RSS](/packages/smsgate-client/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (4)Versions (3)Used By (0)

PHP library for SMS Gate
========================

[](#php-library-for-sms-gate)

*This library requires a minimum PHP version of 5.6*

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

[](#installation)

To install the PHP client library to your project, we recommend using [Composer](https://getcomposer.org/).

```
composer require smsgate/client
```

If you're new to Composer, here are some resources that you may find useful:

- [Composer's Getting Started page](https://getcomposer.org/doc/00-intro.md) from Composer project's documentation.
- [A Beginner's Guide to Composer](https://scotch.io/tutorials/a-beginners-guide-to-composer) from the good people at ScotchBox.

Send SMS
--------

[](#send-sms)

```
//use composer's autoload
require 'vendor/autoload.php';

//make sure to set the real URL for bulk gate
$gate = new SMSGate\Client('http://localhost:9000/bulk_server');

$sms = new SMSGate\SMSRequest;
$sms    ->setType(SMSGate\Client::TYPE_TEXT)
        ->setAuthUsername('test')
        ->setAuthPassword('test')
        ->setSender('Test Sender')
        ->setReceiver('41587000201')
        ->setText('Hello there!')
        ////make sure to set the real URL for your webhook handler
        ->setDlrUrl('http://localhost:8000/dlr.php')
        ->setDlrMask(SMSGate\Client::DLR_MASK_STANDARD);
try {
    $response = $gate->send($sms);
} catch (\Exception $exc) {
    echo "Error sending SMS with code: " . $exc->getCode() . " and message: " . $exc->getMessage();
    exit;
}

echo "SMS sent with ID: " . $response->msgId . " and num of parts: " . $response->numParts;
```

Receive DLRs
------------

[](#receive-dlrs)

```
//use composer's autoload
require 'vendor/autoload.php';

$gate = new SMSGate\Client('');

$dlr = $gate->parseDeliveryReport();
if(!isset($dlr)){
    error_log("Cannot parse DLR from the request");
    exit;
}

error_log("Received DLR: " . json_encode($dlr));
```

Check `examples` directory for more details. To run examples locally run from the command line

```
cd examples
./run_srv.sh
```

and then open `http://localhost:8000/`

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

2676d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ee085e58d55ae704b09ac82ade992d14e4ded35101d9c9f7a5f9a61ad8a0bbd1?d=identicon)[rukavinamilan](/maintainers/rukavinamilan)

---

Top Contributors

[![rukavina](https://avatars.githubusercontent.com/u/881367?v=4)](https://github.com/rukavina "rukavina (2 commits)")

---

Tags

smssms-apisms-gateway

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/smsgate-client/health.svg)

```
[![Health](https://phpackages.com/badges/smsgate-client/health.svg)](https://phpackages.com/packages/smsgate-client)
```

###  Alternatives

[php-http/httplug-bundle

Symfony integration for HTTPlug

39021.7M61](/packages/php-http-httplug-bundle)[retailcrm/api-client-php

PHP client for RetailCRM API

681.1M1](/packages/retailcrm-api-client-php)[razorpay/ifsc

Razorpay IFSC Codes Library

385205.4k](/packages/razorpay-ifsc)[richardfullmer/rabbitmq-management-api

An object oriented wrapper for the RabbitMQ Management HTTP Api

40738.0k8](/packages/richardfullmer-rabbitmq-management-api)[http-interop/http-factory-diactoros

An HTTP Factory using Zend Diactoros

14224.1k11](/packages/http-interop-http-factory-diactoros)

PHPackages © 2026

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