PHPackages                             seven.io/craft - 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. seven.io/craft

ActiveCraft-plugin

seven.io/craft
==============

Send SMS and make text-to-speech calls via seven

v1.0.0(5y ago)11[1 issues](https://github.com/seven-io/craft/issues)MITPHP

Since Apr 20Pushed 7mo agoCompare

[ Source](https://github.com/seven-io/craft)[ Packagist](https://packagist.org/packages/seven.io/craft)[ RSS](/packages/sevenio-craft/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (2)Versions (2)Used By (0)

[![](https://camo.githubusercontent.com/b4669bbc8fd3ead5911fb6525c456c6d2cff4957f29012d27b677a4da0a5efee/68747470733a2f2f7777772e736576656e2e696f2f77702d636f6e74656e742f75706c6f6164732f4c6f676f2e737667)](https://camo.githubusercontent.com/b4669bbc8fd3ead5911fb6525c456c6d2cff4957f29012d27b677a4da0a5efee/68747470733a2f2f7777772e736576656e2e696f2f77702d636f6e74656e742f75706c6f6164732f4c6f676f2e737667)

Official Craft [CMS](https://craftcms.com) + [Commerce](https://craftcms.com/commerce) Plugin
=============================================================================================

[](#official-craft-cms--commerce-plugin)

Send SMS and voice (text-to-speech) messages directly from your Craft CMS control panel or programmatically via service APIs.

Features
--------

[](#features)

- **SMS Messaging**

    - Send individual SMS via control panel
    - Programmatic SMS API with fluent interface
    - Bulk SMS to Craft Commerce customers
    - Advanced options: delay, flash SMS, performance tracking, custom labels
- **Voice Messaging**

    - Send individual voice calls via control panel
    - Programmatic voice API with fluent interface
    - Bulk voice calls to Craft Commerce customers
    - Text-to-speech with XML support
- **Craft Commerce Integration** (optional)

    - Bulk messaging to all customers
    - Country-based filtering
    - Automatic phone number extraction from customer addresses

Prerequisites
-------------

[](#prerequisites)

- [Craft CMS](https://craftcms.com) 3.1.5 or later
- An API key from [seven.io](https://www.seven.io)
- (Optional) [Craft Commerce](https://craftcms.com/commerce) 2.x for bulk messaging features

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

[](#installation)

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

```
# Navigate to your Craft project root
cd /path/to/your/craft-project

# Install the plugin
composer require seven.io/craft

# Install via Craft CLI
./craft install/plugin seven
```

Alternatively, install from the Craft Plugin Store.

Configuration
-------------

[](#configuration)

1. Navigate to **Settings → seven** in your Craft control panel
2. Enter your seven.io API key (required)
3. Optionally set a default sender ID/from number (max 16 characters)

Usage
-----

[](#usage)

### Control Panel

[](#control-panel)

Access the plugin via the main navigation:

- **seven SMS** - Send individual or bulk SMS messages
- **seven Voice** - Send individual or bulk voice calls

For bulk messaging with Craft Commerce, leave the recipient field empty and optionally filter by country.

### Programmatic Usage

[](#programmatic-usage)

#### Send SMS

[](#send-sms)

```
use Seven\Craft\Plugin;

$instance = Plugin::getInstance();
$sms = $instance->getSms();

$sms->params
    ->setTo('+4901234567890')           // Required: recipient(s), comma-separated
    ->setText('Your message here')      // Required: message text
    ->setFrom('YourCompany')            // Optional: sender ID (max 16 chars)
    ->setDelay('2024-12-31 23:59')     // Optional: scheduled delivery
    ->setFlash(true)                    // Optional: flash SMS
    ->setLabel('campaign-2024')         // Optional: custom label
    ->setPerformanceTracking(true);     // Optional: enable tracking

$success = $sms->send(); // Returns true on success, false on failure
```

#### Send Voice Call

[](#send-voice-call)

```
use Seven\Craft\Plugin;

$instance = Plugin::getInstance();
$voice = $instance->getVoice();

$voice->params
    ->setTo('+4901234567890')           // Required: recipient(s), comma-separated
    ->setText('Your message here')      // Required: message text (TTS)
    ->setFrom('YourCompany')            // Optional: caller ID
    ->setXml(false)                     // Optional: XML mode
    ->setJson(true);                    // Optional: JSON response

$success = $voice->send(); // Returns true on success, false on failure
```

#### Available Parameters

[](#available-parameters)

**SMS Parameters** (via `SmsParams`):

- `setTo(string)` - Recipient phone number(s), comma-separated
- `setText(string)` - Message text
- `setFrom(string)` - Sender ID (alphanumeric, max 16 chars)
- `setDelay(string)` - Scheduled delivery timestamp
- `setFlash(bool)` - Send as flash SMS
- `setForeignId(string)` - Custom foreign ID
- `setJson(bool)` - JSON response format
- `setLabel(string)` - Custom label for tracking
- `setPerformanceTracking(bool)` - Enable performance tracking

**Voice Parameters** (via `VoiceParams`):

- `setTo(string)` - Recipient phone number(s), comma-separated
- `setText(string)` - Text-to-speech message
- `setFrom(string)` - Caller ID
- `setXml(bool)` - XML mode
- `setJson(bool)` - JSON response format

### Error Handling

[](#error-handling)

The `send()` method returns a boolean:

- `true` - Message sent successfully (API response code 100)
- `false` - Sending failed (logged via Craft's error handler)

Check Craft logs for detailed error messages.

Craft Commerce Bulk Messaging
-----------------------------

[](#craft-commerce-bulk-messaging)

When Craft Commerce is installed, you can send messages to all customers:

1. Navigate to **seven SMS** or **seven Voice**
2. Leave the recipient field empty
3. Optionally select countries to filter recipients
4. Enter your message and send

The plugin automatically extracts phone numbers from customer billing/shipping addresses.

API Response Codes
------------------

[](#api-response-codes)

- `100` - Success
- Other codes indicate errors (see [seven.io API documentation](https://www.seven.io/en/docs/gateway/http-api/) for details)

Support
-------

[](#support)

Need help? Contact us:

- Email:
- Website: [seven.io/en/company/contact](https://www.seven.io/en/company/contact/)
- Issues: [GitHub Issues](https://github.com/seven-io/craft/issues)

License
-------

[](#license)

[![MIT](https://camo.githubusercontent.com/e19d32ddd0fe35c406741f25b9b857f291780424f61b66afa7f884354256b8ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d7465616c2e737667)](LICENSE.md)

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance24

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 91.7% 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

Unknown

Total

1

Last Release

1854d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2630735456c80aab26c3c9c05b7de0528601df89fdc587ae0b428458e251b59a?d=identicon)[matthiez](/maintainers/matthiez)

---

Top Contributors

[![matthiez](https://avatars.githubusercontent.com/u/12965261?v=4)](https://github.com/matthiez "matthiez (11 commits)")[![cl77](https://avatars.githubusercontent.com/u/33660027?v=4)](https://github.com/cl77 "cl77 (1 commits)")

---

Tags

craft-commercecraft-plugincraft3craftcmsseven-pluginsmssmscmsCraftcommercettstext2speech

### Embed Badge

![Health badge](/badges/sevenio-craft/health.svg)

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

PHPackages © 2026

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