PHPackages                             digiaonline/lumen-sns-middleware - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. digiaonline/lumen-sns-middleware

AbandonedArchivedLibrary[HTTP &amp; Networking](/categories/http)

digiaonline/lumen-sns-middleware
================================

Collection of middleware and helpers for dealing with AWS SNS notifications

1.1.0(5y ago)240.1k2MITPHPPHP &gt;=7.0

Since Oct 9Pushed 3y ago8 watchersCompare

[ Source](https://github.com/digiaonline/lumen-sns-middleware)[ Packagist](https://packagist.org/packages/digiaonline/lumen-sns-middleware)[ RSS](/packages/digiaonline-lumen-sns-middleware/feed)WikiDiscussions main Synced 2mo ago

READMEChangelogDependencies (7)Versions (4)Used By (0)

lumen-sns-middleware
====================

[](#lumen-sns-middleware)

[![Build Status](https://camo.githubusercontent.com/9aa37f6f50acb87a5f79083ca77b13ffcb667452ee659062700eee93137a2cfc/68747470733a2f2f7472617669732d63692e6f72672f64696769616f6e6c696e652f6c756d656e2d736e732d6d6964646c65776172652e7376673f6272616e63683d6d61696e)](https://travis-ci.org/digiaonline/lumen-sns-middleware)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/bcea1d7c643b9ec5d043f1ad867a9699ad41c920b0a27a58b012b68eb400aca5/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f64696769616f6e6c696e652f6c756d656e2d736e732d6d6964646c65776172652f6261646765732f7175616c6974792d73636f72652e706e673f623d6d61696e)](https://scrutinizer-ci.com/g/digiaonline/lumen-sns-middleware/?branch=main)[![Coverage Status](https://camo.githubusercontent.com/fc8bbf2642bb2a094801bd287f174df2c56c0478533c9ff5a3d616b42a04e313/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f64696769616f6e6c696e652f6c756d656e2d736e732d6d6964646c65776172652f62616467652e7376673f6272616e63683d6d61696e)](https://coveralls.io/github/digiaonline/lumen-sns-middleware?branch=main)

This library contains a collection of middleware and helpers for dealing with AWS SNS notifications.

Features
--------

[](#features)

- a middleware for validating the signatures of SNS notifications
- middleware for transparently handling subscription and unsubscribe confirmations
- a factory for creating SNS `Message` objects from HttpFoundation request objects (which Lumen uses)
- a basic enum class for notification types

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

[](#requirements)

- PHP &gt;= 7.0
- Lumen &gt;= 5.5

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

[](#installation)

Add the library as a dependency:

```
composer require digiaonline/lumen-sns-middleware
```

Register the service provider:

```
$app->register(Digia\Lumen\SnsMiddleware\Providers\SnsMiddlewareServiceProvider::class);
```

Usage
-----

[](#usage)

Apply any of the following middleware to your routes:

- `MessageValidatorMiddleware` - validates requests and throws an exception they don't contain a valid SNS message
- `HandleSubscriptionConfirmationMiddleware` - automatically confirms `SubscriptionConfirmation` messages
- `HandleUnsubscribeConfirmationMiddleware` - automatically confirms `UnsubscribeConfirmation` messages

### Using a custom HTTP client

[](#using-a-custom-http-client)

If for some reason you need to use a custom HTTP client when validating messages or confirming subscription/unsubscribe messages, bind an implementation of `HttpClientInterface` to your container, e.g.:

```
$app->bind(HttpClientInterface::class, MyImplementation::class);
```

License
-------

[](#license)

MIT

Testing
-------

[](#testing)

Run `composer test`

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 50% 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 ~530 days

Total

3

Last Release

2077d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d7e28ec3bf2ff3ffcdd8c947f54d53d4dae86939bea2a7316cfde0b10410e9ee?d=identicon)[Jalle19](/maintainers/Jalle19)

---

Top Contributors

[![hugovk](https://avatars.githubusercontent.com/u/1324225?v=4)](https://github.com/hugovk "hugovk (2 commits)")[![Jalle19](https://avatars.githubusercontent.com/u/1106133?v=4)](https://github.com/Jalle19 "Jalle19 (2 commits)")

---

Tags

awslumenSNS

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/digiaonline-lumen-sns-middleware/health.svg)

```
[![Health](https://phpackages.com/badges/digiaonline-lumen-sns-middleware/health.svg)](https://phpackages.com/packages/digiaonline-lumen-sns-middleware)
```

###  Alternatives

[renoki-co/laravel-aws-webhooks

Easy webhook handler for Laravel to catch AWS SNS notifications for various services.

73248.5k](/packages/renoki-co-laravel-aws-webhooks)[joggapp/laravel-aws-sns

Laravel package for the SNS events by AWS

3171.8k](/packages/joggapp-laravel-aws-sns)[ankurk91/laravel-ses-webhooks

Handle AWS SES webhooks in Laravel php framework

2534.2k](/packages/ankurk91-laravel-ses-webhooks)[joblocal/laravel-sqs-sns-subscription-queue

A simple Laravel service provider which adds a new queue connector to handle SNS subscription queues.

48416.3k](/packages/joblocal-laravel-sqs-sns-subscription-queue)

PHPackages © 2026

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