You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Android SMS Gateway transforms your Android smartphone into an SMS gateway. It is a lightweight application that enables you to send SMS messages programmatically via an API, making it ideal for integrating SMS functionality into your applications or services.
8
7
8
+
## 🚀 Installation
9
9
10
-
11
-
12
-
## Installation
13
-
14
-
To install the rootscratch/sms via Composer, run the following command:
10
+
To install the `rootscratch/sms` via Composer, run the following command:
15
11
16
12
```bash
17
-
composer require rootscratch/sms
13
+
composer require rootscratch/sms
18
14
```
19
-
20
-
## Usage/Examples
21
-
To use the Rootscratch SMS in your PHP project, include the Composer autoloader:
22
15
16
+
## 📖 Usage/Examples
17
+
18
+
To use the Rootscratch SMS in your PHP project, include the Composer autoloader:
23
19
24
20
```php
25
21
require_once __DIR__ . '/vendor/autoload.php';
22
+
26
23
use Rootscratch\SMS\Configuration;
27
24
$configuration = new Configuration();
25
+
28
26
// Set API Key
29
-
Configuration::setApiKey('your_api_key');
27
+
$configuration->setApiKey('your_api_key');
28
+
```
29
+
30
+
## ⚙️ Configuration Usage
31
+
32
+
```php
33
+
/**
34
+
* Configuration
35
+
*
36
+
* Get Devices = getDevices()
37
+
* Get Balance = getBalance()
38
+
*
39
+
* Get Message By ID = getMessageByID($id) : if $id int = message id, if $id string = group id
40
+
*
41
+
* Get Message By Status = getMessagesByStatus($status, $deviceID = null, $simID = null, $time = null, $endTimestamp = null)
42
+
* Get messages "received" on SIM 1 of device ID 8 in last 24 hours = getMessagesByStatus("Received", 8, 0, time() - 86400)
43
+
*
44
+
* Get USSD Request By ID = getUssdRequestByID($id)
45
+
* Get USSD requests with request text "*150#" sent in last 24 hours. = getUssdRequests("*150#", null, null, time() - 86400)
46
+
*
47
+
* Add a new contact to contacts list 1 or resubscribe the contact if it already exists. = addContact(1, "+11234567890", "Test", true);
48
+
* Unsubscribe a contact using the mobile number. = unsubscribeContact(1, "+11234567890");
0 commit comments