PHPackages                             vhbelvadi/webmentions - 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. vhbelvadi/webmentions

ActiveStatamic-addon

vhbelvadi/webmentions
=====================

v2.3.0(yesterday)8512Blade

Since Jan 17Pushed yesterday1 watchersCompare

[ Source](https://github.com/vhbelvadi/webmentions)[ Packagist](https://packagist.org/packages/vhbelvadi/webmentions)[ RSS](/packages/vhbelvadi-webmentions/feed)WikiDiscussions master Synced today

READMEChangelog (7)Dependencies (2)Versions (8)Used By (0)

Webmentions
===========

[](#webmentions)

[![Statamic webmentions overview](https://camo.githubusercontent.com/5316d62a4925a6f1cffcb0383c444cb475997f34130d1330ae3fee4937c4166c/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f354733377a4d4575326c4841797274617a3565634465666a56517a645139394a4c4a45556f5172632e6a7067)](https://camo.githubusercontent.com/5316d62a4925a6f1cffcb0383c444cb475997f34130d1330ae3fee4937c4166c/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f354733377a4d4575326c4841797274617a3565634465666a56517a645139394a4c4a45556f5172632e6a7067)

[According to the W3C](https://www.w3.org/TR/webmention/) Webmentions are an open web standard for conversations and interactions across the web, a powerful building block used for a growing distributed network of peer-to-peer comments, likes, reposts, and other responses across the web.

Popular across the [IndieWeb](https://indieweb.org/Webmention) as a means of enabling cross-site conversations, webmentions allow individuals to inform, and be informed by, other websites about activities and publications on websites and across social media platforms. In practice most people use webmentions in conjunction with services like [webmention.io](https://webmention.io) and [Bridgy](https://brid.gy).

---

**Jump to section** • [Installation](https://github.com/vhbelvadi/webmentions#installation) • [Templating](https://github.com/vhbelvadi/webmentions#templating) • [Widget set-up](https://github.com/vhbelvadi/webmentions#widget-new-in-v2) • [Troubleshooting](https://github.com/vhbelvadi/webmentions#troubleshooting) • [Further](https://github.com/vhbelvadi/webmentions#further) (includes [an example set-up](https://github.com/vhbelvadi/webmentions#example-set-up))

---

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

[](#installation)

This add-on is for websites built with [Statamic](https://statamic.com).

**Installation** is as normally [recommended by Statamic](https://statamic.dev/extending/addons#installing-an-addon):

```
composer require vhbelvadi/webmentions

```

**Add a link tag** to your website, making sure to update the `` bit:

```

```

Assuming you have signed up with [webmention.io](https://webmention.io) and added your domain, this tag will work. It is the same tag available directly [from your webmention.io account](https://webmention.io/settings/sites).

Templating
----------

[](#templating)

On your statamic site, use the `{{ webmentions }}` tag passing the appropriate URL. A more detailed explanation follows but as a quick example the following tag works on a reused blog post template:

```
{{ webmentions url={{ current_url}} }}

```

This add-on also provides a `length` modifier that outputs the number of webmentions for the given url. For this and other template tags, see [the example set-up](#example-set-up).

[![Statamic webmentions add-on screenshot](https://camo.githubusercontent.com/3efac13ff0f7be582599547c4b8839f50e69f81a4a7602e5947cfa8d9329ac0e/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f5543656f4b565741757236493249423539707076624754453839725a534f6b5558527256474b776f2e706e67)](https://camo.githubusercontent.com/3efac13ff0f7be582599547c4b8839f50e69f81a4a7602e5947cfa8d9329ac0e/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f5543656f4b565741757236493249423539707076624754453839725a534f6b5558527256474b776f2e706e67)

Widget (New in v2!)
-------------------

[](#widget-new-in-v2)

This add-on provides a control panel widget. There are two steps to enable it, both standard Statamic procedures:

### Save your API key

[](#save-your-api-key)

Head to your [webmention.io settings](https://webmention.io/settings) and copy your API key.

Next, add a value your `.env` file like so:

```
WEBMENTION_TOKEN=

```

### Set up your widget

[](#set-up-your-widget)

In the config file located at `config/statamic/cp.php` add your widget:

```
'widgets' => [
        [
            'type' => 'webmentions',
            'width' => 50,
            'limit' => 7, // optional
        ],
    ],

```

If you already have a few widgets set up, you can of course skip the `'widgets => [ ],` block and just add the `webmentions` block for this add-on. The `'limit'` value is optional and defaults to 7 if not provided i.e. the widget will display the seven latest webmentions.

[![Webmentions widget](https://camo.githubusercontent.com/446cddbf4b617ec6640f74d2eb480aceb87f3ca1c8ed702b546ee88782615e04/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f45476b47386a425a61424871796455763777655a524f4b6b6c684a6766305444414159376a4e6b502e706e67)](https://camo.githubusercontent.com/446cddbf4b617ec6640f74d2eb480aceb87f3ca1c8ed702b546ee88782615e04/68747470733a2f2f73746174616d69632e636f6d2f73746f726167652f70726f64756374732f45476b47386a425a61424871796455763777655a524f4b6b6c684a6766305444414159376a4e6b502e706e67)

Rather than display a feed as is, widget offers a few links: a link to the webmention itself, a link to your post with which the webmention interacts, and a link to edit that post for convenience if you should need it.

The recommended `'width'` value is `50` although the widget works at any other width. The widget will display a helpful blue **NEW** marker if you have any webmentions within the last 3 days.

Troubleshooting
---------------

[](#troubleshooting)

### Blank page following widget set-up

[](#blank-page-following-widget-set-up)

**If you set up your widget locally** and pushed to your production server please run `composer update`.

**If you set up your widget on production**—you daredevil—or if you did so locally but forgot to add your API key, check that your `.env` file has the proper API set-up.

*Got any suggestions for common problems? Please [let me know](mailto:hello@vhbelvadi.com) or edit this section and submit a pull request.*

Further
-------

[](#further)

The following payload is sent via webhooks:

```
{
  "secret": "1234abcd",
  "source": "http://rhiaro.co.uk/2015/11/1446953889",
  "target": "http://aaronparecki.com/notes/2015/11/07/4/indiewebcamp",
  "post": {
    "type": "entry",
    "author": {
      "name": "Amy Guy",
      "photo": "http://webmention.io/avatar/rhiaro.co.uk/829d3f6e7083d7ee8bd7b20363da84d88ce5b4ce094f78fd1b27d8d3dc42560e.png",
      "url": "http://rhiaro.co.uk/about#me"
    },
    "url": "http://rhiaro.co.uk/2015/11/1446953889",
    "published": "2015-11-08T03:38:09+00:00",
    "name": "repost of http://aaronparecki.com/notes/2015/11/07/4/indiewebcamp",
    "repost-of": "http://aaronparecki.com/notes/2015/11/07/4/indiewebcamp",
    "wm-property": "repost-of"
  }
}

```

This means you can use, for example with Statamic Antlers, the following tags directly:

```
{{ mentions }} {{ wm-property }} {{ published }} {{ name }} {{ url }}

```

And you can use the following author-specific tags within an `{{ author }} ... {{ /author }}` block:

```
{{ photo }} {{ name }} {{ url }}

```

**Note** that although the `{{ name }}` and `{{ url }}` tags appear in both places, as shown in the sample payload above, they contain different pieces of information.

### Example set-up

[](#example-set-up)

As a live example, check out the webmentions [on this webpage](https://vhbelvadi.com/indieweb-carnival-friction) where the implementation looks something like this:

```
{{ nocache }}
  {{ webmentions url="{{ current_url }}" }}
    {{ if !no_results }}
      {{ mentions | length }} webmentions

        {{ mentions }}

            {{ author }}

            {{ /author }}

              {{ switch(
                  ( wm-property == "in-reply-to" ) => 'replied',
                  ( wm-property == "like-of" ) => 'liked',
                  ( wm-property == "repost-of" ) => 'shared',
                  ( wm-property == "bookmark-of" ) => 'bookmarked',
                  ( wm-property == "mention-of" ) => 'discussed',
                  ( wm-property == "rsvp" ) => 'rsvp'
              )}}

        {{ /mentions }}

    {{ /if }}
  {{ /webmentions }}
{{ /nocache }}

```

The `{{ nocache }} ... {{ /nocache }}` block is not necessary if you are not using Statamic caching.

---

This add-on was originally created by [Matt Rothenberg](https://github.com/mattrothenberg).

###  Health Score

45

—

FairBetter than 93% of packages

Maintenance100

Actively maintained with recent releases

Popularity17

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 62.1% 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 ~71 days

Recently: every ~98 days

Total

7

Last Release

1d ago

Major Versions

v1.0 → 2.02025-01-19

### Community

Maintainers

![](https://www.gravatar.com/avatar/948a59c53b023dc0086ff19718dee7a55a2e6ec340091b40ac2036c5a1b0c68d?d=identicon)[vhbelvadi](/maintainers/vhbelvadi)

---

Top Contributors

[![vhbelvadi](https://avatars.githubusercontent.com/u/13168700?v=4)](https://github.com/vhbelvadi "vhbelvadi (18 commits)")[![mattrothenberg](https://avatars.githubusercontent.com/u/5148596?v=4)](https://github.com/mattrothenberg "mattrothenberg (9 commits)")[![owenconti](https://avatars.githubusercontent.com/u/791222?v=4)](https://github.com/owenconti "owenconti (1 commits)")[![szepeviktor](https://avatars.githubusercontent.com/u/952007?v=4)](https://github.com/szepeviktor "szepeviktor (1 commits)")

---

Tags

indiewebstatamic-addonwebmentionwidgettagstatamicwebmention

### Embed Badge

![Health badge](/badges/vhbelvadi-webmentions/health.svg)

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

###  Alternatives

[statamic/cms

The Statamic CMS Core Package

4.7k3.1M559](/packages/statamic-cms)[statamic/cli

Statamic CLI Tool

7586.1k](/packages/statamic-cli)[sjaakp/yii2-taggable

Manage tags of ActiveRecord in Yii2.

3029.9k](/packages/sjaakp-yii2-taggable)[statamic-rad-pack/meilisearch

meilisearch search driver for Statamic

1656.9k](/packages/statamic-rad-pack-meilisearch)[astrotomic/laravel-webmentions

215.6k](/packages/astrotomic-laravel-webmentions)[daun/statamic-placeholders

Generate low-quality image placeholders for lazyloading Statamic assets

105.9k](/packages/daun-statamic-placeholders)

PHPackages © 2026

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