PHPackages                             devriyad/giosms - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. devriyad/giosms

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

devriyad/giosms
===============

Official PHP SDK for GioSMS — Send SMS easily from any PHP or Laravel application.

v1.0.1(4mo ago)02MITPHPPHP ^8.1

Since Feb 14Pushed 4mo agoCompare

[ Source](https://github.com/riyadMunauwar/giosms)[ Packagist](https://packagist.org/packages/devriyad/giosms)[ Docs](https://github.com/devriyad/giosms-php)[ RSS](/packages/devriyad-giosms/feed)WikiDiscussions master Synced today

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

GioSMS PHP SDK
==============

[](#giosms-php-sdk)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d5eb116f450a15770df600b314d4773f7af6a3f5d31e76a6d03e70646c813b32/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f64657672697961642f67696f736d732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/devriyad/giosms)[![PHP Version](https://camo.githubusercontent.com/d723c2ffc92472af5637ffe2441c5c945b16878c48b49a9334312fe9dffb2420/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f64657672697961642f67696f736d732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/devriyad/giosms)[![License](https://camo.githubusercontent.com/81d449aa5a2149a00547c44917228f8e811a698ec4f545701c9a619d96dd6a7c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f64657672697961642f67696f736d732e7376673f7374796c653d666c61742d737175617265)](LICENSE)

The official PHP SDK for [GioSMS](https://api.giosms.com) — a fast, reliable SMS gateway for Bangladesh. Works with **Laravel 9+** (zero config, auto-discovery) and **any standalone PHP 8.1+** project.

---

Table of Contents
-----------------

[](#table-of-contents)

- [Requirements](#requirements)
- [Installation](#installation)
- [Setup — Laravel](#setup--laravel)
- [Setup — Standalone PHP (Without Laravel)](#setup--standalone-php-without-laravel)
- [Usage](#usage)
    - [Send Single SMS](#send-single-sms)
    - [Send OTP (High Priority)](#send-otp-high-priority)
    - [Send Bulk SMS](#send-bulk-sms)
    - [Send to Contacts](#send-to-contacts)
    - [Send to Groups](#send-to-groups)
    - [Check Delivery Status](#check-delivery-status)
    - [Check Balance &amp; Cost Estimate](#check-balance--cost-estimate)
    - [Batch Tracking](#batch-tracking)
    - [Health Check](#health-check)
- [Error Handling](#error-handling)
- [Laravel Dependency Injection](#laravel-dependency-injection)
- [Reference](#reference)
    - [All Methods at a Glance](#all-methods-at-a-glance)
    - [SMS Types &amp; Priority](#sms-types--priority)
    - [Encoding &amp; Character Limits](#encoding--character-limits)
    - [HTTP Status Codes &amp; Exceptions](#http-status-codes--exceptions)
- [License](#license)

---

Requirements
------------

[](#requirements)

- PHP **8.1** or higher
- Guzzle **7.x** (installed automatically via Composer)
- A GioSMS account and API token from [api.giosms.com](https://api.giosms.com)

---

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

[](#installation)

```
composer require devriyad/giosms
```

That's it. Guzzle is pulled in automatically if you don't already have it.

---

Setup — Laravel
---------------

[](#setup--laravel)

> **Zero config.** The service provider and facade are auto-discovered. No need to edit `config/app.php`.

### Step 1: Add credentials to `.env`

[](#step-1-add-credentials-to-env)

```
GIOSMS_TOKEN=your-api-token-here
GIOSMS_SENDER_ID=MyBrand
# GIOSMS_SSL_VERIFY=false  # uncomment for local dev without SSL
```

VariableRequiredDescription`GIOSMS_TOKEN`**Yes**Your API bearer token from the GioSMS dashboard`GIOSMS_SENDER_ID`NoDefault sender ID (max 16 chars). Can be overridden per request.`GIOSMS_BASE_URL`NoAPI base URL. Default: `https://api.giosms.com/api/v1``GIOSMS_TIMEOUT`NoRequest timeout in seconds. Default: `30``GIOSMS_SSL_VERIFY`NoSSL certificate verification. Default: `true`. Set `false` for local dev.### Step 2 (Optional): Publish the config file

[](#step-2-optional-publish-the-config-file)

```
php artisan vendor:publish --tag=giosms-config
```

This creates `config/giosms.php` if you need to customize anything beyond `.env` variables.

### Step 3: Start sending

[](#step-3-start-sending)

```
use GioSMS\Facades\GioSMS;

GioSMS::send([
    'to'      => '8801712345678',
    'message' => 'Hello from GioSMS!',
]);
```

---

Setup — Standalone PHP (Without Laravel)
----------------------------------------

[](#setup--standalone-php-without-laravel)

For any PHP project that doesn't use Laravel — plain PHP, Symfony, CodeIgniter, Slim, etc.

### Option A: Pass config directly

[](#option-a-pass-config-directly)

```
