tommykivits/statamic-spam-sentry

There is no license information available for the latest version (v1.0.0) of this package.

Spam Sentry adds a smart validator to form fields in your Statamic site.

Maintainers

Package info

github.com/tommykivits/statamic-spam-sentry

pkg:composer/tommykivits/statamic-spam-sentry

Transparency log

Statistics

Installs: 0

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.0.0 2026-08-04 13:16 UTC

This package is auto-updated.

Last update: 2026-08-04 18:39:22 UTC


README

Spam Sentry adds a smart validator to form fields in your Statamic site. Input is automatically checked against a comprehensive, up-to-date list of known spam terms. Easily extend it with your own blacklist or whitelist entries via simple configuration. Includes per-IP reputation checks via AbuseIPDB and logging of detected spam.

Features

  • Text Spam Checking: Automatically validates form input against a large list of known spam words.
  • Custom Blacklist/Whitelist: Add your own words or regex patterns to the blacklist, or allow specific words via the whitelist.
  • IP Reputation: Check the submitter's IP address against the AbuseIPDB database.
  • Logging: All detected spam (both words and IP matches) are logged to your Laravel logs and a dedicated Spam Log in the Statamic Control Panel.
  • Spam Log Utility: Easily view and manage blocked submissions directly from the Statamic Control Panel.
  • Caching: IP reputation checks are cached for 28 days to minimize API calls.

Installation

Install the addon via Composer:

composer require tommykivits/statamic-spam-sentry

The addon will automatically publish its assets and configuration upon installation.

Features & Usage

Text Spam Checking

To use the spam validator on a form field, add the NoKnowSpam rule to your field's validation rules in the blueprint:

# In your blueprint YAML
sections:
  main:
    display: Main
    fields:
      - handle: message
        field:
          type: textarea
          display: Message
          validate:
            - required
            - 'new \Tommykivits\SpamSentry\Rules\NoKnowSpam()'

IP Reputation

Spam Sentry can check the submitter's IP address against the AbuseIPDB database. If an IP is found to be abusive, the submission will be blocked automatically.

Add your AbuseIPDB API Key to your .env file:

ABUSEIPDB_API_KEY=your_api_key_here

Spam Log

All detected spam is recorded in a dedicated log. You can access this log in the Statamic Control Panel under Utilities > Spam Sentry. It provides a clear overview of:

  • Time: When the spam was detected.
  • Type: Whether it was a word match or an IP match.
  • Message: The reason for blocking.
  • IP Address: The sender's IP.
  • Path: The URL where the submission occurred.

Configuration

Settings

You can manage the following settings in the Statamic Control Panel under Settings > Spam Sentry:

  • Blocked Words: Add additional words or regular expressions (prefixed with regex:) to the blacklist.
  • Allowed Words: Specify words that should always be permitted (whitelist).
  • Enable AbuseIPDB: Toggle IP reputation checks on or off.
  • Minimum Confidence Score: Set the threshold (0-100) for considering an IP address as abusive.

Advanced Configuration

Optionally, override how long a checked IP's verdict is cached (defaults to 28 days) in your .env:

SPAM_SENTRY_ABUSEIP_CACHE_DAYS=28

The default list of spam words can be found and modified in storage/spamsentry/spam-words.php after installation.