PHPackages                             cyberwani/trai-sms-header - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. cyberwani/trai-sms-header

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

cyberwani/trai-sms-header
=========================

A PHP library for inspecting TRAI-compliant SMS headers (operator, circle, and message type mapping) with DLT sender lookup.

v1.0.4(6mo ago)05MITPHPPHP &gt;=7.4

Since Nov 4Pushed 6mo agoCompare

[ Source](https://github.com/cyberwani/trai-sms-header)[ Packagist](https://packagist.org/packages/cyberwani/trai-sms-header)[ RSS](/packages/cyberwani-trai-sms-header/feed)WikiDiscussions main Synced 1mo ago

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

TRAI SMS Header
===============

[](#trai-sms-header)

**TRAI SMS Header** is a PHP library and CLI tool developed by [Cyberwani](https://github.com/Cyberwani)for inspecting and decoding TRAI-compliant SMS headers under TCCCPR 2025 guidelines.

It helps telecom developers, SMS gateway providers, and compliance teams to easily parse headers such as `VM-ABCDEF-S` into detailed information like **Operator**, **Circle**, **Sender Name**, and **Message Type**.

---

🚀 Features
----------

[](#-features)

- 🔍 Parse and validate TRAI SMS headers (`VM-ABCDEF-S`, `VK-MYCOMP-P`, etc.)
- 🏢 Lookup registered **Sender Names** via included `sender-list.json`
- 🛰️ Identify Operator &amp; Circle based on TRAI prefix mapping
- 💬 Detect message type suffix (`-P`, `-S`, `-T`, `-G`)
- 🧩 Works as a **Composer library** *and* a **CLI tool**
- ⚡ Lightweight, dependency-free (optional PhpSpreadsheet for data import)

---

🧰 Installation
--------------

[](#-installation)

Install via [Composer](https://getcomposer.org):

```
composer require cyberwani/trai-sms-header
```

This will install both the PHP library and the CLI binary:

```
vendor/bin/trai-sms-header

```

---

🧑‍💻 PHP Usage Example
---------------------

[](#‍-php-usage-example)

```
