PHPackages                             broken-titan/laravel-klaviyo-channel - 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. broken-titan/laravel-klaviyo-channel

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

broken-titan/laravel-klaviyo-channel
====================================

Klaviyo notification channel for Laravel.

v2.0.2(4y ago)18.8k2[1 issues](https://github.com/broken-titan/laravel-klaviyo-channel/issues)MITPHPPHP &gt;=7.2

Since Jun 14Pushed 1y ago1 watchersCompare

[ Source](https://github.com/broken-titan/laravel-klaviyo-channel)[ Packagist](https://packagist.org/packages/broken-titan/laravel-klaviyo-channel)[ RSS](/packages/broken-titan-laravel-klaviyo-channel/feed)WikiDiscussions master Synced yesterday

READMEChangelog (6)Dependencies (4)Versions (7)Used By (0)

Laravel Klaviyo Notification Channel
====================================

[](#laravel-klaviyo-notification-channel)

This package makes it easy to integrate Laravel with Klaviyo for sending notifications via a channel.

Contents
--------

[](#contents)

- [Installation](#installation)
- [Configuration](#configuration)
- [Usage](#usage)
- [Testing](#testing)
- [Security](#security)
- [Contributing](#contributing)
- [Credits](#credits)
- [License](#license)

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

[](#installation)

Install this package with Composer:

```
composer require broken-titan/laravel-klaviyo-channel

```

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

[](#configuration)

Before you may begin using the Klaviyo service, you must obtain a private and public API key from your Klayivo account settings. The key must be assigned to KLAVIYO\_API\_KEY and KLAVIYO\_API\_PUBLIC\_KEY in your .env file.

You should also publish the config file that will generate klaviyo.php in your config folder.

Usage
-----

[](#usage)

Once installation is complete, you can send events to Klaviyo by creating standard Laravel notifications. For example:

```
    namespace App\Notifications;

    use Illuminate\Notifications\Notification;
    use BrokenTitan\Klaviyo\Channels\KlaviyoChannel;
    use BrokenTitan\Klaviyo\Messages\KlaviyoTrackMessage;
    use DateTimeImmutable;

    class UserCreated extends Notification {
        /**
         * Get the notification's delivery channels.
         *
         * @method via
         * @param mixed $notifiable
         * @return array
         */
        public function via($notifiable) {
            return [KlaviyoChannel::class];
        }

        /**
         * Sends the notification to Klaviyo.
         *
         * @method toKlaviyo
         * @param mixed $notifiable
         * @return BrokenTitan\Klaviyo\Messages\KlaviyoTrackMessage
         */
        public function toKlaviyo($notifiable) : KlaviyoTrackMessage {
            $customerProperties = ['$email' => $notifiable->email];
            $properties = ['user_id' => $notifiable->user_id];

            return new KlaviyoTrackMessage("User Created", $customerProperties, $properties, new DateTimeImmutable);
        }
    }

```

There are multiple notification message types you may return in toKlayivo: KlaviyoTrackMessage, KlaviyoTrackOnceMessage, KlaviyoIdentifyMessage. Using one or the other will produce the appropriate event for Klaviyo. See the method parameters for the appropriate arguments to pass.

Testing
-------

[](#testing)

```
$ composer test

```

Security
--------

[](#security)

If you discover any security issues that would affect existing users, please email  instead of using the issue tracker.

Contributing
------------

[](#contributing)

Feel free to contribute to the package.

Credits
-------

[](#credits)

- [Klaviyo](https://github.com/klaviyo)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 78.9% 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 ~24 days

Recently: every ~31 days

Total

6

Last Release

1670d ago

Major Versions

v1.0.2 → v2.0.02021-07-17

### Community

Maintainers

![](https://www.gravatar.com/avatar/0349b2c67312de7cd10ed2a5f75a49cce795055f9f6697860c6f8335362425c1?d=identicon)[TheThird](/maintainers/TheThird)

---

Top Contributors

[![th3third](https://avatars.githubusercontent.com/u/7121736?v=4)](https://github.com/th3third "th3third (15 commits)")[![antongorodezkiy](https://avatars.githubusercontent.com/u/580599?v=4)](https://github.com/antongorodezkiy "antongorodezkiy (4 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/broken-titan-laravel-klaviyo-channel/health.svg)

```
[![Health](https://phpackages.com/badges/broken-titan-laravel-klaviyo-channel/health.svg)](https://phpackages.com/packages/broken-titan-laravel-klaviyo-channel)
```

###  Alternatives

[laravel-notification-channels/telegram

Telegram Notifications Channel for Laravel

1.1k3.4M35](/packages/laravel-notification-channels-telegram)[laravel-notification-channels/webpush

Web Push Notifications driver for Laravel.

7984.5M16](/packages/laravel-notification-channels-webpush)[laravel-notification-channels/fcm

FCM (Firebase Cloud Messaging) Notifications Driver for Laravel

5917.0M16](/packages/laravel-notification-channels-fcm)[s-ichikawa/laravel-sendgrid-driver

This library adds a 'sendgrid' mail driver to Laravel.

4139.3M1](/packages/s-ichikawa-laravel-sendgrid-driver)[laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

2587.7M12](/packages/laravel-notification-channels-twilio)[laravel-notification-channels/apn

Apple APN Push Notification Channel

2021.9M4](/packages/laravel-notification-channels-apn)

PHPackages © 2026

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